Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
XDG Integration
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
JennaHuntsman
XDG Integration
Commits
06be53fe
Unverified
Commit
06be53fe
authored
1 year ago
by
cosmic-linden
Committed by
GitHub
1 year ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #206 from secondlife/SL-19644
SL-19644: De-virtualize pushBatch
parents
6d0d9b8e
307d3111
No related branches found
No related tags found
2 merge requests
!3
Update to main branch
,
!2
Rebase onto current main branch
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
indra/newview/lldrawpool.h
+8
-5
8 additions, 5 deletions
indra/newview/lldrawpool.h
indra/newview/lldrawpoolbump.cpp
+13
-12
13 additions, 12 deletions
indra/newview/lldrawpoolbump.cpp
indra/newview/lldrawpoolbump.h
+0
-1
0 additions, 1 deletion
indra/newview/lldrawpoolbump.h
with
21 additions
and
18 deletions
indra/newview/lldrawpool.h
+
8
−
5
View file @
06be53fe
...
...
@@ -349,15 +349,18 @@ class LLRenderPass : public LLDrawPool
void
resetDrawOrders
()
{
}
static
void
applyModelMatrix
(
const
LLDrawInfo
&
params
);
virtual
void
pushBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
virtual
void
pushRiggedBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
// Use before a non-GLTF batch if it is interleaved with GLTF batches that share the same shader
static
void
resetGLTFTextureTransform
();
void
pushBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
void
pushRiggedBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
void
pushGLTFBatches
(
U32
type
);
void
pushGLTFBatch
(
LLDrawInfo
&
params
);
void
pushRiggedGLTFBatches
(
U32
type
);
void
pushRiggedGLTFBatch
(
LLDrawInfo
&
params
,
LLVOAvatar
*&
lastAvatar
,
U64
&
lastMeshId
);
virtual
void
pushMaskBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
virtual
void
pushRiggedMaskBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
virtual
void
pushBatch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
=
false
);
void
pushMaskBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
void
pushRiggedMaskBatches
(
U32
type
,
bool
texture
=
true
,
bool
batch_textures
=
false
);
void
pushBatch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
=
false
);
void
pushBumpBatch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
=
false
);
static
bool
uploadMatrixPalette
(
LLDrawInfo
&
params
);
static
bool
uploadMatrixPalette
(
LLVOAvatar
*
avatar
,
LLMeshSkinInfo
*
skinInfo
);
virtual
void
renderGroup
(
LLSpatialGroup
*
group
,
U32
type
,
bool
texture
=
true
);
...
...
This diff is collapsed.
Click to expand it.
indra/newview/lldrawpoolbump.cpp
+
13
−
12
View file @
06be53fe
...
...
@@ -77,6 +77,7 @@ static LLGLSLShader* shader = NULL;
static
S32
cube_channel
=
-
1
;
static
S32
diffuse_channel
=
-
1
;
static
S32
bump_channel
=
-
1
;
static
BOOL
shiny
=
FALSE
;
// Enabled after changing LLViewerTexture::mNeedsCreateTexture to an
// LLAtomicBool; this should work just fine, now. HB
...
...
@@ -197,7 +198,7 @@ void LLStandardBumpmap::destroyGL()
LLDrawPoolBump
::
LLDrawPoolBump
()
:
LLRenderPass
(
LLDrawPool
::
POOL_BUMP
)
{
mS
hiny
=
FALSE
;
s
hiny
=
FALSE
;
}
...
...
@@ -346,7 +347,7 @@ void LLDrawPoolBump::beginFullbrightShiny()
diffuse_channel
=
0
;
}
mS
hiny
=
TRUE
;
s
hiny
=
TRUE
;
}
void
LLDrawPoolBump
::
renderFullbrightShiny
()
...
...
@@ -398,7 +399,7 @@ void LLDrawPoolBump::endFullbrightShiny()
diffuse_channel
=
-
1
;
cube_channel
=
0
;
mS
hiny
=
FALSE
;
s
hiny
=
FALSE
;
}
void
LLDrawPoolBump
::
renderGroup
(
LLSpatialGroup
*
group
,
U32
type
,
bool
texture
=
true
)
...
...
@@ -541,7 +542,7 @@ void LLDrawPoolBump::renderDeferred(S32 pass)
{
LL_PROFILE_ZONE_SCOPED_CATEGORY_DRAWPOOL
;
//LL_RECORD_BLOCK_TIME(FTM_RENDER_BUMP);
mS
hiny
=
TRUE
;
s
hiny
=
TRUE
;
for
(
int
i
=
0
;
i
<
2
;
++
i
)
{
bool
rigged
=
i
==
1
;
...
...
@@ -575,11 +576,11 @@ void LLDrawPoolBump::renderDeferred(S32 pass)
avatar
=
params
.
mAvatar
;
skin
=
params
.
mSkinInfo
->
mHash
;
}
pushBatch
(
params
,
true
,
false
);
pushB
umpB
atch
(
params
,
true
,
false
);
}
else
{
pushBatch
(
params
,
true
,
false
);
pushB
umpB
atch
(
params
,
true
,
false
);
}
}
...
...
@@ -589,7 +590,7 @@ void LLDrawPoolBump::renderDeferred(S32 pass)
gGL
.
getTexUnit
(
0
)
->
activate
();
}
mS
hiny
=
FALSE
;
s
hiny
=
FALSE
;
}
...
...
@@ -1213,12 +1214,12 @@ void LLDrawPoolBump::pushBumpBatches(U32 type)
}
}
}
pushBatch
(
params
,
false
);
pushB
umpB
atch
(
params
,
false
);
}
}
}
void
LL
DrawPoolBump
::
pushBatch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
)
void
LL
RenderPass
::
pushB
umpB
atch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
)
{
LL_PROFILE_ZONE_SCOPED_CATEGORY_DRAWPOOL
;
applyModelMatrix
(
params
);
...
...
@@ -1239,7 +1240,7 @@ void LLDrawPoolBump::pushBatch(LLDrawInfo& params, bool texture, bool batch_text
{
//not batching textures or batch has only 1 texture -- might need a texture matrix
if
(
params
.
mTextureMatrix
)
{
if
(
mS
hiny
)
if
(
s
hiny
)
{
gGL
.
getTexUnit
(
0
)
->
activate
();
gGL
.
matrixMode
(
LLRender
::
MM_TEXTURE
);
...
...
@@ -1258,7 +1259,7 @@ void LLDrawPoolBump::pushBatch(LLDrawInfo& params, bool texture, bool batch_text
tex_setup
=
true
;
}
if
(
mS
hiny
&&
mShaderLevel
>
1
&&
texture
)
if
(
s
hiny
&&
mShaderLevel
>
1
&&
texture
)
{
if
(
params
.
mTexture
.
notNull
())
{
...
...
@@ -1276,7 +1277,7 @@ void LLDrawPoolBump::pushBatch(LLDrawInfo& params, bool texture, bool batch_text
if
(
tex_setup
)
{
if
(
mS
hiny
)
if
(
s
hiny
)
{
gGL
.
getTexUnit
(
0
)
->
activate
();
}
...
...
This diff is collapsed.
Click to expand it.
indra/newview/lldrawpoolbump.h
+
0
−
1
View file @
06be53fe
...
...
@@ -53,7 +53,6 @@ protected :
LLDrawPoolBump
();
/*virtual*/
void
prerender
()
override
;
void
pushBatch
(
LLDrawInfo
&
params
,
bool
texture
,
bool
batch_textures
=
false
)
override
;
void
pushBumpBatches
(
U32
type
);
void
renderGroup
(
LLSpatialGroup
*
group
,
U32
type
,
bool
texture
)
override
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment