Things arrived in the mail today! With luck, I'll have the server for the bot set up this weekend :D

a hitch in my plan: opening a complicated model on a windows 11 vm running on half a CPU core on a potato takes a hot minute to compile a few hundred shaders 🙃

another hitch in my plan is my RSI is flaring up tonight :|

this is the problem model in the first image. each color is a different shader that had to be generated by tangerine to render the voxel, and the average complexity of the generated shaders is also high.

the second image is the generated part for one of the these shaders. its basically the object structure w/ all the params pulled out.

it's basically half way to being an interpreter, i'd just need to also pull the call structure out into a parameter buffer, and replace the function with an interpreter loop. it would be slower than rendering with all of the compiled shaders, but it only needs to produce one frame for the bot

incidentally this happens to also be my plan for how to deal with shader compiler hitches in general, i've just been procrastinating on it because opengl doesn't believe in async shader compiling

@aeva You could try compiling to SPIR-V in a separate thread, that way the driver only has to go from bytecode to machine code.

@lh0xfb how much of an undertaking is it to convert from gl/glsl to spirv/glsl?

@lh0xfb also does SPIRV let you turn off optimizations?



I use shaderc:

It has several options, like optimization level, source language, and target environment (I'm using HLSL + vulkan).
It's shipped as part of the vulkan SDK, so I just LoadLibrary and load its functions to use from C.

There's also glslang:

Also dxc can compile hlsl to dxil or spir-v:

· · Web · 1 · 0 · 1
Sign in to participate in the conversation

the mastodon instance at is retiring

see the end-of-life plan for details: