Mercurial > games > semicongine
diff examples/E01_hello_triangle.nim @ 203:84fd522fdf3f
did: update examples to use new API for scene + scene globals
author | Sam <sam@basx.dev> |
---|---|
date | Mon, 08 May 2023 21:21:49 +0700 |
parents | 25d97fa0ad5c |
children | f3912838cd69 |
line wrap: on
line diff
--- a/examples/E01_hello_triangle.nim Mon May 08 00:48:11 2023 +0700 +++ b/examples/E01_hello_triangle.nim Mon May 08 21:21:49 2023 +0700 @@ -25,13 +25,13 @@ ) var - triangle = newEntity( + triangle = newScene("scene", newEntity( "triangle", newMesh( [newVec3f(-0.5, 0.5), newVec3f(0, -0.5), newVec3f(0.5, 0.5)], [X, Y, Z], ) - ) + )) myengine = initEngine("Hello triangle") renderPass = myengine.gpuDevice.simpleForwardRenderPass(vertexCode, fragmentCode)