Created
June 26, 2015 04:14
-
-
Save Subv/dd81aeaffc7abc6ed9a5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| static auto call = [&program_code](VertexShaderState& state, u32 offset, u32 num_instructions, | |
| u32 return_offset, u8 repeat_count, u8 loop_increment) { | |
| state.program_counter = &program_code[offset] - 1; // -1 to make sure when incrementing the PC we end up at the correct offset | |
| state.call_stack.push({ offset + num_instructions, return_offset, repeat_count, loop_increment, offset }); | |
| }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment