Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
NiranV
Black Dragon Viewer
Commits
cbe46d5e
Commit
cbe46d5e
authored
Feb 03, 2021
by
NiranV
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Changed: Count specular maps and normal maps into complexity.
parent
87d22c63
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
13 deletions
+12
-13
indra/newview/llvovolume.cpp
indra/newview/llvovolume.cpp
+12
-13
No files found.
indra/newview/llvovolume.cpp
View file @
cbe46d5e
...
...
@@ -712,11 +712,6 @@ void LLVOVolume::updateTextureVirtualSize(bool forced)
LL_RECORD_BLOCK_TIME
(
FTM_VOLUME_TEXTURES
);
// Update the pixel area of all faces
if
(
mDrawable
.
isNull
())
{
return
;
}
if
(
!
forced
)
{
if
(
!
isVisible
())
...
...
@@ -2401,8 +2396,7 @@ bool LLVOVolume::notifyAboutCreatingTexture(LLViewerTexture *texture)
//setup new materials
for
(
map_te_material
::
const_iterator
it
=
new_material
.
begin
(),
end
=
new_material
.
end
();
it
!=
end
;
++
it
)
{
// These are placeholder materials, they shouldn't be sent to server
LLMaterialMgr
::
getInstance
()
->
setLocalMaterial
(
getRegion
()
->
getRegionID
(),
it
->
second
);
LLMaterialMgr
::
getInstance
()
->
put
(
getID
(),
it
->
first
,
*
it
->
second
);
LLViewerObject
::
setTEMaterialParams
(
it
->
first
,
it
->
second
);
}
...
...
@@ -4412,16 +4406,21 @@ U32 LLVOVolume::getRenderCost(texture_cost_t &textures) const
const
LLFace
*
face
=
drawablep
->
getFace
(
i
);
if
(
!
face
)
continue
;
const
LLTextureEntry
*
te
=
face
->
getTextureEntry
();
const
LLViewerTexture
*
img
=
face
->
getTexture
();
if
(
img
)
S32
j
=
0
;
while
(
j
<
LLRender
::
NUM_TEXTURE_CHANNELS
)
{
if
(
textures
.
find
(
img
->
getID
())
==
textures
.
end
())
const
LLViewerTexture
*
img
=
face
->
getTexture
(
j
);
if
(
img
)
{
S32
texture_cost
=
256
+
(
S32
)((
ARC_TEXTURE_COST
*
(
img
->
getFullHeight
()
*
img
->
getFullWidth
()))
/
1024
);
textures
.
insert
(
texture_cost_t
::
value_type
(
img
->
getID
(),
texture_cost
));
vovolume
->
mRenderComplexityTextures
+=
texture_cost
;
if
(
textures
.
find
(
img
->
getID
())
==
textures
.
end
())
{
S32
texture_cost
=
256
+
(
S32
)((
ARC_TEXTURE_COST
*
(
img
->
getFullHeight
()
*
img
->
getFullWidth
()))
/
1024
);
textures
.
insert
(
texture_cost_t
::
value_type
(
img
->
getID
(),
texture_cost
));
vovolume
->
mRenderComplexityTextures
+=
texture_cost
;
}
}
++
j
;
}
if
(
face
->
getPoolType
()
==
LLDrawPool
::
POOL_ALPHA
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment