Files
firestorm/Gameleap/code/mw4/Libraries/mlr/MLRClippingState.cpp
T
Cyd 2b8ca921cb Initial full mirror of c:\VWE (source + assets + toolchain + outputs) via Git LFS
Complete disaster-recovery snapshot: engine/game source, game data assets,
VC6 toolchain + DX SDKs, build outputs, deployed game, and _UNUSED archive.
Large binaries in Git LFS; text preserved byte-for-byte (core.autocrlf=false,
no eol attributes). See RECOVERY.md for the one-clone rebuild procedure.
2026-06-24 21:28:16 -05:00

50 lines
1.3 KiB
C++

#include "MLRHeaders.hpp"
//#############################################################################
//######################### MLRClippingState ############################
//#############################################################################
int MLRClippingState::numberBitsLookUpTable[MLRClippingState::ClipMask+1] = {
0, 1, 1, 2, 1, 2, 2, 3,
1, 2, 2, 3, 2, 3, 3, 4,
1, 2, 2, 3, 2, 3, 3, 4,
2, 3, 3, 4, 3, 4, 4, 5,
1, 2, 2, 3, 2, 3, 3, 4,
2, 3, 3, 4, 3, 4, 4, 5,
2, 3, 3, 4, 3, 4, 4, 5,
3, 4, 4, 5, 4, 5, 5, 6
};
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
void
MLRClippingState::Save(MemoryStream *stream)
{
Check_Object(this);
Check_Object(stream);
//
//-------------------------------------
// Save the clippingState to the stream
//-------------------------------------
//
*stream << clippingState;
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//
void
MLRClippingState::Load(MemoryStream *stream)
{
Check_Object(this);
Check_Object(stream);
//
//---------------------------------------
// Load the clippingState from the stream
//---------------------------------------
//
*stream >> clippingState;
}