summaryrefslogtreecommitdiff
path: root/indra/llimage/llimage.h
diff options
context:
space:
mode:
authorAlexander Gavriliuk <alexandrgproductengine@lindenlab.com>2023-11-30 17:47:58 +0100
committerAlexander Gavriliuk <alexandrgproductengine@lindenlab.com>2023-12-05 03:37:06 +0100
commitc9cd5631e4b149f83c5a49c8fbf869cf2fb5b6a7 (patch)
treed09566a4132530ea65574a886540e0f258103017 /indra/llimage/llimage.h
parent54db4206e9302e7510bc4f103ff59714c1be942d (diff)
parent683bf84bb38adc88d4a4b7fedaed89b41fcac45e (diff)
Merge branch 'main' into DRTVWR-489
Diffstat (limited to 'indra/llimage/llimage.h')
-rw-r--r--indra/llimage/llimage.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/indra/llimage/llimage.h b/indra/llimage/llimage.h
index 7a588cfb03..8f9e1b3c54 100644
--- a/indra/llimage/llimage.h
+++ b/indra/llimage/llimage.h
@@ -184,6 +184,7 @@ protected:
public:
LLImageRaw();
LLImageRaw(U16 width, U16 height, S8 components);
+ LLImageRaw(const U8* data, U16 width, U16 height, S8 components);
LLImageRaw(U8 *data, U16 width, U16 height, S8 components, bool no_copy = false);
// Construct using createFromFile (used by tools)
//LLImageRaw(const std::string& filename, bool j2c_lowest_mip_only = false);
@@ -207,6 +208,10 @@ public:
void clear(U8 r=0, U8 g=0, U8 b=0, U8 a=255);
void verticalFlip();
+
+ // if the alpha channel is all 100% opaque, delete it
+ // returns true if alpha channel was deleted
+ bool optimizeAwayAlpha();
static S32 biasedDimToPowerOfTwo(S32 curr_dim, S32 max_dim = MAX_IMAGE_SIZE);
static S32 expandDimToPowerOfTwo(S32 curr_dim, S32 max_dim = MAX_IMAGE_SIZE);
@@ -275,7 +280,6 @@ protected:
void setDataAndSize(U8 *data, S32 width, S32 height, S8 components) ;
public:
- static S32 sGlobalRawMemory;
static S32 sRawImageCount;
private: