-
Is there any trick on how to compile shaders outside of the BGFX project directory (got problems on a m1 Mac mini)? I was trying to run the following command on a shader: ../bgfx/.build/osx-arm64/bin/shadercRelease -f shader/v_simple.sc -o v_simple.bin --platform osx --type vertex --profile metal --varyingdef shader/varying.def.sc --verbose -i ../bgfx/src and it failed with the message: ERROR: 0:11: 'u_modelViewProj' : unknown variable If I copy my shaders into the examples/01-cubes folder (or any examples folder) and run the same command, it works like a charm. What am I missing? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Can you add your shader code? |
Beta Was this translation helpful? Give feedback.
Can you add your shader code?
u_modelViewProj
is defined in#include <bgfx_shader.sh>
, so you should have that close to the top of your shader src.