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

Method DrawNodeSpLinesTest

tests/cpp-tests/Source/DrawNodeTest/DrawNodeTest.cpp:3702–3730  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3700}
3701
3702DrawNodeSpLinesTest::DrawNodeSpLinesTest()
3703{
3704 drawNode = DrawNode::create();
3705 drawNode->properties.setTransform(true);
3706 addChild(drawNode, 30);
3707
3708 screen = Director::getInstance()->getVisibleSize();
3709 origin = Director::getInstance()->getVisibleOrigin();
3710 center = Vec2(screen.width / 2, screen.height / 2);
3711 sixth = Vec2(screen.width / 6, screen.height / 6);
3712 sixth.y;
3713
3714 defY = (int)(center.y + sixth.y);
3715 defY2 = (int)(center.y - sixth.y);
3716 dev = sixth.y;
3717
3718 pts = PointArray::create(n);
3719 pts2 = PointArray::create(n);
3720 pts->retain();
3721 pts2->retain();
3722 for (int i = 0; i < n; ++i)
3723 {
3724 pts->insertControlPoint(Vec2(0, 0), i);
3725 pts2->insertControlPoint(Vec2(0, 0), i);
3726 }
3727
3728 DrawNodeBaseTest::generateDataPoints();
3729 scheduleUpdate();
3730}
3731
3732std::string DrawNodeSpLinesTest::title() const
3733{

Callers

nothing calls this directly

Calls 9

createFunction · 0.85
getInstanceFunction · 0.85
scheduleUpdateFunction · 0.85
setTransformMethod · 0.80
insertControlPointMethod · 0.80
Vec2Function · 0.50
getVisibleSizeMethod · 0.45
getVisibleOriginMethod · 0.45
retainMethod · 0.45

Tested by

no test coverage detected