diff options
Diffstat (limited to 'examples/particle_system/main.cpp')
-rw-r--r-- | examples/particle_system/main.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/examples/particle_system/main.cpp b/examples/particle_system/main.cpp index 9251cc4..6ab3448 100644 --- a/examples/particle_system/main.cpp +++ b/examples/particle_system/main.cpp @@ -21,24 +21,24 @@ Shader* shader; Sprite* spr; const char* shader_code = R"( #VERTEX_SHADER -Vertex vert(Vertex v) -{ - return v; -} + Vertex vert(Vertex v) + { + return v; + } #END_VERTEX_SHADER #FRAGMENT_SHADER -Color frag(Color col, Texture tex, Vertex v) -{ - Color c = texel(tex, v.uv); - return c * col; -} + Color frag(Color col, Texture tex, Vertex v) + { + Color c = texel(tex, v.uv); + return c * col; + } #END_FRAGMENT_SHADER )"; const float Pi = 3.14f; void onLoad() { tex = Texture::createTexture("texture.png"); - spr = new Sprite(tex, Sprite::Origin::BottomCenter); + spr = new Sprite(tex, Origin::BottomCenter); shader = Shader::createShader(shader_code); ParticleSystemDef def; def.maxParticleCount = 30; |