Quantcast
Channel: Cocos Forums - Latest topics
Viewing all articles
Browse latest Browse all 17083

Uniform not found [Android 6][Cocos2d-X 3.10]

$
0
0

@vinch wrote:

Hello,

My shaders were working fine on Android 5, but when I tried to launch the game on Galaxy S7 (Android 6), I got following errors:

cocos2d: warning: Uniform not found: light6
cocos2d: warning: Uniform not found: shadowsShift
cocos2d: warning: Uniform not found: midtonesShift
cocos2d: warning: Uniform not found: highlightsShift
....

And shader is not working (sprites are either black or white)

My code:

renderSprite = cocos2d::Sprite::create();
renderSprite->setGLProgramState(cocos2d::GLProgramState::getOrCreateWithGLProgramName(DISPLACEMENT_SHADER_NAME));

renderSprite->getGLProgramState()->setUniformVec3("shadowsShift", color.shadowShift);
renderSprite->getGLProgramState()->setUniformVec3("midtonesShift", color.midtoneShift);
renderSprite->getGLProgramState()->setUniformVec3("highlightsShift", color.highlightShift);

Is that possible to fix this issue? Can I expect that updating to the latest version of Cocos2d-X would fix it?

Thanks,
Andriy

Posts: 2

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 17083

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>