mirror of
https://git.coom.tech/drummyfish/small3dlib.git
synced 2024-11-21 20:39:57 +01:00
Add backface culing to modelviewer
This commit is contained in:
parent
b932a39e51
commit
9d15954864
1 changed files with 2 additions and 0 deletions
|
@ -484,6 +484,8 @@ int main()
|
||||||
noise = !noise;
|
noise = !noise;
|
||||||
else if (event.key.keysym.scancode == SDL_SCANCODE_W)
|
else if (event.key.keysym.scancode == SDL_SCANCODE_W)
|
||||||
wire = !wire;
|
wire = !wire;
|
||||||
|
else if (event.key.keysym.scancode == SDL_SCANCODE_B)
|
||||||
|
model.config.backfaceCulling = (model.config.backfaceCulling + 1) % 3;
|
||||||
else if (event.key.keysym.scancode == SDL_SCANCODE_SPACE)
|
else if (event.key.keysym.scancode == SDL_SCANCODE_SPACE)
|
||||||
{
|
{
|
||||||
modelIndex = (modelIndex + 1) % modelsTotal;
|
modelIndex = (modelIndex + 1) % modelsTotal;
|
||||||
|
|
Loading…
Reference in a new issue