- Made all the basic texture classes local to their implementation.
They are not needed anywhere else. - Changed the HackHack hack for corrupt 256 pixel high textures that FMultiPatchTexture only calls a virtual function instead of doing any type checks of the patch itself. - Cleaned up the constant definitions in doomdata.h. - Moved the TEXTUREx structures from doomdata.h to multipatchtexture.cpp because they are used only in this one file. - Removed some more typedefs from r_defs.h and doomdata.h - Moved local polyobject data definitions from p_local.h to po_man.cpp. SVN r1012 (trunk)
This commit is contained in:
parent
71b0d4d074
commit
47aacc45c8
34 changed files with 1723 additions and 1091 deletions
|
|
@ -43,6 +43,34 @@
|
|||
|
||||
static TArray<BYTE *> BuildTileFiles;
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
// A texture defined in a Build TILESxxx.ART file
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
class FBuildTexture : public FTexture
|
||||
{
|
||||
public:
|
||||
FBuildTexture (int tilenum, const BYTE *pixels, int width, int height, int left, int top);
|
||||
~FBuildTexture ();
|
||||
|
||||
const BYTE *GetColumn (unsigned int column, const Span **spans_out);
|
||||
const BYTE *GetPixels ();
|
||||
void Unload ();
|
||||
|
||||
protected:
|
||||
const BYTE *Pixels;
|
||||
Span **Spans;
|
||||
};
|
||||
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
FBuildTexture::FBuildTexture (int tilenum, const BYTE *pixels, int width, int height, int left, int top)
|
||||
: Pixels (pixels), Spans (NULL)
|
||||
{
|
||||
|
|
@ -55,6 +83,12 @@ FBuildTexture::FBuildTexture (int tilenum, const BYTE *pixels, int width, int he
|
|||
UseType = TEX_Build;
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
FBuildTexture::~FBuildTexture ()
|
||||
{
|
||||
if (Spans != NULL)
|
||||
|
|
@ -64,16 +98,34 @@ FBuildTexture::~FBuildTexture ()
|
|||
}
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
void FBuildTexture::Unload ()
|
||||
{
|
||||
// Nothing to do, since the pixels are accessed from memory-mapped files directly
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
const BYTE *FBuildTexture::GetPixels ()
|
||||
{
|
||||
return Pixels;
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
//
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
const BYTE *FBuildTexture::GetColumn (unsigned int column, const Span **spans_out)
|
||||
{
|
||||
if (column >= Width)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue