mirror of
https://github.com/bkaradzic/bgfx.git
synced 2026-02-19 21:42:59 +01:00
DebugDraw: Added spin, and quad.
This commit is contained in:
@@ -171,13 +171,18 @@ class DebugDrawApp : public entry::AppI
|
||||
ddSetColor(0xffffffff);
|
||||
|
||||
ddPush();
|
||||
ddSetStipple(true, 1.0f, time*0.1f);
|
||||
ddSetColor(0xff0000ff);
|
||||
{
|
||||
float normal[3] = { 0.0f, 0.0f, 1.0f };
|
||||
float center[3] = { -8.0f, 0.0f, 0.0f };
|
||||
{
|
||||
float normal[3] = { 0.0f, 0.0f, 1.0f };
|
||||
float center[3] = { -8.0f, 0.0f, 0.0f };
|
||||
ddPush();
|
||||
ddSetStipple(true, 1.0f, time*0.1f);
|
||||
ddSetColor(0xff0000ff);
|
||||
ddDrawCircle(normal, center, 1.0f, 0.5f + bx::fsin(time*10.0f) );
|
||||
}
|
||||
ddPop();
|
||||
|
||||
ddSetSpin(time);
|
||||
ddDrawQuad(normal, center, 2.0f);
|
||||
}
|
||||
ddPop();
|
||||
|
||||
ddPush();
|
||||
@@ -187,6 +192,7 @@ class DebugDrawApp : public entry::AppI
|
||||
|
||||
ddPush();
|
||||
ddSetLod(UINT8_MAX);
|
||||
ddSetSpin(time*0.3f);
|
||||
{
|
||||
float from[3] = { -11.0f, 4.0f, 0.0f };
|
||||
float to[3] = { -13.0f, 6.0f, 1.0f };
|
||||
@@ -233,6 +239,7 @@ class DebugDrawApp : public entry::AppI
|
||||
ddPop();
|
||||
|
||||
ddDrawOrb(-11.0f, 0.0f, 0.0f, 1.0f);
|
||||
|
||||
ddEnd();
|
||||
|
||||
// Advance to next frame. Rendering thread will be kicked to
|
||||
|
||||
Reference in New Issue
Block a user