MCPcopy Create free account
hub / github.com/axmolengine/axmol / DrawNodeCircleTest

Method DrawNodeCircleTest

tests/cpp-tests/Source/DrawNodeTest/DrawNodeTest.cpp:3552–3576  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3550}
3551
3552DrawNodeCircleTest::DrawNodeCircleTest()
3553{
3554 drawNode->properties.setPosition(Vec2(100, -10));
3555 for (int i = 3; i <= 24; i++)
3556 {
3557 drawNode->drawCircle(center, 5 * i, AX_DEGREES_TO_RADIANS(90), i, false, 1.0f, 1.0f, Color4F::WHITE);
3558 }
3559 drawNode->drawCircle(center, 130, AX_DEGREES_TO_RADIANS(90), 48, false, 1.0f, 1.0f, Color4F::MAGENTA);
3560
3561 drawNode->properties.setPosition(Vec2(-10, 10));
3562 for (size_t i = 0; i < 3; i++)
3563 {
3564 drawNode->drawCircle(Vec2(120, 150), 85 - 18.8 * i, AX_DEGREES_TO_RADIANS(90), 5, false, 1.0f, 1.0f,
3565 Color4F::BLUE, 3.0f);
3566 }
3567
3568 drawNode->properties.setCenter(Vec2(120, 150));
3569 for (int i = 0; i < 5; i++)
3570 {
3571 drawNode->properties.setRotation(AX_DEGREES_TO_RADIANS(360 / 5 * i));
3572 drawNode->drawSolidCircle(Vec2(120, 197), 10, 0, 36, 1.0f, 1.0f, Color4F::BLUE);
3573 drawNode->drawSolidCircle(Vec2(120, 215), 12, 0, 36, 1.0f, 1.0f, Color4F::BLUE);
3574 drawNode->drawSolidCircle(Vec2(120, 235), 16, 0, 36, 1.0f, 1.0f, Color4F::BLUE);
3575 }
3576}
3577
3578std::string DrawNodeCircleTest::title() const
3579{

Callers

nothing calls this directly

Calls 6

drawCircleMethod · 0.80
drawSolidCircleMethod · 0.80
Vec2Function · 0.50
setPositionMethod · 0.45
setCenterMethod · 0.45
setRotationMethod · 0.45

Tested by

no test coverage detected