문제

After following several different tutorials on OpenGL shaders, I noticed they all use different naming for the outs and ins.

For instance, I've seen ex_color vFragColor, ModelViewMatrix, mvMatrix, etc.

It would be nice if my shaders would be compatible with some other shaders out there without having to rename everything. Is there some kind of naming scheme, or standard I could follow that is more or less common?

도움이 되었습니까?

해결책

There is no naming convention for interface variable names. You should use whatever works and makes sense for your needs.

Also, there's no need to be "compatible" with other people shaders if you don't copy and paste their code into your own.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top