40#ifndef _TEXTURE_PALETTE_H
41#define _TEXTURE_PALETTE_H
100 char* _returned_filename;
101 bool _supportsNPOTValue;
103 void SupportsAllowNPOT();
188 Image* _defaultTexture;
195 void ( *_paletteUpdateCallback )( bool, int,
DisplayFrame* );
231 unsigned
int size()
const {
return Count(); }
235 DISTI_DEPRECATED(
"Member data has been made private. Use accessor functions like Entry() and Count() instead." )
261 GLS_EXPORT void TextureFilename(
int i, const
char* filename );
272 GLS_EXPORT bool SetTexture(
int i, const
char* filename, const
Image::LoadOptions& options =
Image::LoadOptions(),
bool glTexCompress = false,
bool allowNPOT = true,
bool isLoadingDeferred = true );
Definition: disti_metadata.h:87
Definition: callback_caller_base.h:56
Definition: display_frame.h:87
Definition: disti_metadata.h:750
Definition: disti_metadata.h:220
Definition: gls_metadata_attributes.h:2069
Definition: texture_palette.h:78
std::string Type() const override
DistiAttributeImageCodecEnum(CallbackMethodCallerBase *callback, const AttributeName &name, glsImageCodec *attribPtr)
Definition: dynamic_array.h:79
Definition: file_path_class.h:63
Definition: gls_state_manager_interface.h:69
Definition: texture_palette.h:94
int compressionFactor
Compression factor of the image, used only for JPEG.
Definition: texture_palette.h:116
int desiredLoadWidth
The width that the image should load at. 0 indicates full size. (Editor only)
Definition: texture_palette.h:117
bool reverseAlpha
True if the alpha channel should be reversed on load.
Definition: texture_palette.h:111
long compressedSize
Size of image when compressed with currently set inline CODEC.
Definition: texture_palette.h:114
bool isLoadingDeferred
True if loading should be deferred until first draw.
Definition: texture_palette.h:112
const char * Filename() const
TexturePaletteEntry(const TexturePaletteEntry &source)
int desiredLoadHeight
The height that the image should load at. 0 indicates full size. (Editor only)
Definition: texture_palette.h:118
void Filename(const char *name)
void Validate()
Set the texture state to valid.
static bool _defaultGenerateInline
Unused, kept for backward compatibility.
Definition: texture_palette.h:108
bool useGLTextureCompression
True if the image should be generated to use hardware texture compression. (Editor only)
Definition: texture_palette.h:122
int sourceImageMemSize
The size of the source image im memory. (bytes) (Editor only)
Definition: texture_palette.h:121
int sourceImageWidth
The width of the source image. (pixels) (Editor only)
Definition: texture_palette.h:119
void Initialize()
Set up the default member values.
int sourceImageHeight
The height of the source image. (pixels) (Editor only)
Definition: texture_palette.h:120
void Invalidate()
Sets the texture state to invalid.
Image * texture
Pointer to the texture object itself.
Definition: texture_palette.h:113
bool allowNPOT
Allow Non-power of two texture (do not scale up).
Definition: texture_palette.h:124
void Ignore()
Sets texture to NULL and status to IGNORED.
glsImageCodec codec
CODEC that will be used to compress an inline image.
Definition: texture_palette.h:115
std::istream & ReadValue(std::istream &instr)
std::ostream & WriteValue(std::ostream &outstr)
bool generateInline
True if the image is to be generated as inline code.
Definition: texture_palette.h:110
TextureState_e TextureStatus()
Definition: texture_palette.h:143
TexturePaletteEntry & operator=(const TexturePaletteEntry &source)
Definition: texture_palette.h:506
DistiAttributeTexturePalette_V21(TexturePalette **palette)
std::string Type() const override
virtual std::istream & ReadValue(std::istream &instr) override
virtual bool OkToWrite() const override
Definition: texture_palette.h:515
virtual std::ostream & WriteValue(std::ostream &outstr) override
Definition: texture_palette.h:516
Definition: texture_palette.h:526
DistiAttributeTexturePalette(TexturePalette **palette)
std::string Type() const override
virtual std::istream & ReadValue(std::istream &instr) override
virtual std::ostream & WriteValue(std::ostream &outstr) override
Definition: texture_palette.h:186
void PaletteSize(int newSize)
void SetTexturePaletteCallback(void(*callback)(bool, int, DisplayFrame *), DisplayFrame *owningFrame)
void UseGLTextureCompression(int i, bool val)
void DesiredLoadSize(int i, int width, int height)
void Codec(int i, glsImageCodec val, bool reload=true)
static bool DownsizeImage(Image *image, int desiredWidth, int desiredHeight)
TexturePaletteEntry * Entry(int i)
void operator=(TexturePalette &source)
void SetMipMap(int i, bool val)
void CompressionFactor(int i, int val, bool reload=true)
bool GenerateInline(int i)
TexturePalette(int size=0)
void DeleteTexture(int i)
void PreviewGenerated(int i)
void AllowNPOT(int i, bool val)
glsImageCodec Codec(int i)
long CompressedSize(int i)
void CompressedSize(int i, long val)
int CompressionFactor(int i)
bool UseGLTextureCompression(int i)
void GenerateInline(int i, bool val)
The disti::DynamicArray class. A templated array of objects capable of dynamically growing.
#define DISTI_DEPRECATED(msg)
Defines whether this compiler supports the C++14 deprecated attribute.
Definition: gls_cpp_lang_support.h:457
#define DISTI_METHOD_OVERRIDE
Macro to wrap the override keyword, removed on compilers that don't support it.
Definition: gls_cpp_lang_support.h:214
A file for all GL Studio files to include.
#define GLS_EXPORT
Macro denoting which functions should be visible from the runtime library.
Definition: gls_include.h:52
The Image class. All textures are converted internally into Images.
Force inclusion of the DirectShow library.
Definition: bmpimage.h:47
const int MULTIPLE_TEXTURES_SELECTED
Definition: texture_palette.h:60
glsImageCodec
Definition: image.h:64
TextureState_e
Definition: texture_palette.h:64
@ TEXTURE_INVALID
Definition: texture_palette.h:68
@ TEXTURE_VALID
Definition: texture_palette.h:70
@ TEXTURE_UNUSED
Definition: texture_palette.h:65
@ TEXTURE_IGNORED
Definition: texture_palette.h:66
const int NO_TEXTURE
Definition: texture_palette.h:56