MCPcopy Create free account
hub / github.com/OGRECave/ogre / updateGpuProgramParameters

Method updateGpuProgramParameters

OgreMain/src/OgreSceneManager.cpp:3650–3678  ·  view source on GitHub ↗

---------------------------------------------------------------------

Source from the content-addressed store, hash-verified

3648}
3649//---------------------------------------------------------------------
3650void SceneManager::updateGpuProgramParameters(const Pass* pass)
3651{
3652 if (!mGpuParamsDirty)
3653 return;
3654
3655 if (pass->isProgrammable())
3656 {
3657 pass->_updateAutoParams(mAutoParamDataSource.get(), mGpuParamsDirty);
3658
3659 for (int i = 0; i < GPT_COMPUTE_PROGRAM; i++) // compute program is bound via RSComputeOperation
3660 {
3661 GpuProgramType t = (GpuProgramType)i;
3662 if (pass->hasGpuProgram(t))
3663 {
3664 mDestRenderSystem->bindGpuProgramParameters(t, pass->getGpuProgramParameters(t),
3665 mGpuParamsDirty);
3666 }
3667 }
3668 }
3669
3670 // GLSL and HLSL2 allow FFP state access
3671 if(mFixedFunctionParams)
3672 {
3673 mFixedFunctionParams->_updateAutoParams(mAutoParamDataSource.get(), mGpuParamsDirty);
3674 mDestRenderSystem->applyFixedFunctionParams(mFixedFunctionParams, mGpuParamsDirty);
3675 }
3676
3677 mGpuParamsDirty = 0;
3678}
3679//---------------------------------------------------------------------
3680void SceneManager::_issueRenderOp(Renderable* rend, const Pass* pass)
3681{

Callers

nothing calls this directly

Calls 5

hasGpuProgramMethod · 0.80
_updateAutoParamsMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected