summaryrefslogtreecommitdiff
path: root/indra/llrender/llgltexture.h
diff options
context:
space:
mode:
authorMnikolenko Productengine <mnikolenko@productengine.com>2022-03-02 19:46:48 +0200
committerMnikolenko Productengine <mnikolenko@productengine.com>2022-03-02 19:46:48 +0200
commitf90d17905899d01db76b82b6d647bbecf1c47f23 (patch)
treedba8f9a514a02a9d86fe25c5d0ffccf30a6b754f /indra/llrender/llgltexture.h
parent064f28b290026be0e77cd38de78b06477a9c0876 (diff)
parent97a103255e433629f13e2156aa307ca329cdcfc6 (diff)
Merge branch 'DRTVWR-546' into DRTVWR-539
# Conflicts: # indra/llcommon/tests/llprocess_test.cpp # indra/llui/llcombobox.cpp # indra/llui/llcombobox.h # indra/newview/VIEWER_VERSION.txt # indra/newview/llviewertexturelist.cpp # indra/newview/llvovolume.cpp
Diffstat (limited to 'indra/llrender/llgltexture.h')
-rw-r--r--indra/llrender/llgltexture.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/indra/llrender/llgltexture.h b/indra/llrender/llgltexture.h
index 028457c510..8cfe7b62de 100644
--- a/indra/llrender/llgltexture.h
+++ b/indra/llrender/llgltexture.h
@@ -124,13 +124,22 @@ public:
BOOL hasGLTexture() const ;
LLGLuint getTexName() const ;
BOOL createGLTexture() ;
- BOOL createGLTexture(S32 discard_level, const LLImageRaw* imageraw, S32 usename = 0, BOOL to_create = TRUE, S32 category = LLGLTexture::OTHER);
+
+ // Create a GL Texture from an image raw
+ // discard_level - mip level, 0 for highest resultion mip
+ // imageraw - the image to copy from
+ // usename - explicit GL name override
+ // to_create - set to FALSE to force gl texture to not be created
+ // category - LLGLTexture category for this LLGLTexture
+ // defer_copy - set to true to allocate GL texture but NOT initialize with imageraw data
+ // tex_name - if not null, will be set to the GL name of the texture created
+ BOOL createGLTexture(S32 discard_level, const LLImageRaw* imageraw, S32 usename = 0, BOOL to_create = TRUE, S32 category = LLGLTexture::OTHER, bool defer_copy = false, LLGLuint* tex_name = nullptr);
void setFilteringOption(LLTexUnit::eTextureFilterOptions option);
void setExplicitFormat(LLGLint internal_format, LLGLenum primary_format, LLGLenum type_format = 0, BOOL swap_bytes = FALSE);
void setAddressMode(LLTexUnit::eTextureAddressMode mode);
- BOOL setSubImage(const LLImageRaw* imageraw, S32 x_pos, S32 y_pos, S32 width, S32 height);
- BOOL setSubImage(const U8* datap, S32 data_width, S32 data_height, S32 x_pos, S32 y_pos, S32 width, S32 height);
+ BOOL setSubImage(const LLImageRaw* imageraw, S32 x_pos, S32 y_pos, S32 width, S32 height, LLGLuint use_name = 0);
+ BOOL setSubImage(const U8* datap, S32 data_width, S32 data_height, S32 x_pos, S32 y_pos, S32 width, S32 height, LLGLuint use_name = 0);
void setGLTextureCreated (bool initialized);
void setCategory(S32 category) ;
void setTexName(LLGLuint); // for forcing w/ externally created textures only