summaryrefslogtreecommitdiff
path: root/indra/newview/llmaterialeditor.cpp
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2022-09-02 19:56:35 +0100
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2022-09-02 19:56:35 +0100
commit852d552ca205506bba3dcd5a31a012f1acdf1cc4 (patch)
treebc4e2776dec44c7b7271cc5ad4b460fa29b100db /indra/newview/llmaterialeditor.cpp
parent3c3442cbbc38beff1ab82ffcc7f81390c7979361 (diff)
parentbded34a8615a2adceb2eda2f2d85501a70990efe (diff)
Merge branch 'DRTVWR-559' of https://bitbucket.org/lindenlab/viewer into DRTVWR-559
Diffstat (limited to 'indra/newview/llmaterialeditor.cpp')
-rw-r--r--indra/newview/llmaterialeditor.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/llmaterialeditor.cpp b/indra/newview/llmaterialeditor.cpp
index f05f0344bd..5acf0600b6 100644
--- a/indra/newview/llmaterialeditor.cpp
+++ b/indra/newview/llmaterialeditor.cpp
@@ -1059,24 +1059,39 @@ static void pack_textures(
LLPointer<LLImageJ2C>& mr_j2c,
LLPointer<LLImageJ2C>& emissive_j2c)
{
+ // NOTE : remove log spam and lossless vs lossy comparisons when the logs are no longer useful
+
if (albedo_img)
{
albedo_j2c = LLViewerTextureList::convertToUploadFile(albedo_img);
+ LL_INFOS() << "Albedo: " << albedo_j2c->getDataSize() << LL_ENDL;
}
if (normal_img)
{
normal_j2c = LLViewerTextureList::convertToUploadFile(normal_img);
+
+ LLPointer<LLImageJ2C> test;
+ test = LLViewerTextureList::convertToUploadFile(normal_img, 1024, true);
+
+ S32 lossy_bytes = normal_j2c->getDataSize();
+ S32 lossless_bytes = test->getDataSize();
+
+ LL_INFOS() << llformat("Lossless vs Lossy: (%d/%d) = %.2f", lossless_bytes, lossy_bytes, (F32)lossless_bytes / lossy_bytes) << LL_ENDL;
+
+ normal_j2c = test;
}
if (mr_img)
{
mr_j2c = LLViewerTextureList::convertToUploadFile(mr_img);
+ LL_INFOS() << "Metallic/Roughness: " << mr_j2c->getDataSize() << LL_ENDL;
}
if (emissive_img)
{
emissive_j2c = LLViewerTextureList::convertToUploadFile(emissive_img);
+ LL_INFOS() << "Emissive: " << emissive_j2c->getDataSize() << LL_ENDL;
}
}