#include <RenderTextureTest.h>
◆ SpriteRenderTextureBug()
| SpriteRenderTextureBug::SpriteRenderTextureBug |
( |
| ) |
|
在文件 RenderTextureTest.cpp 第 700 行定义.
702 auto listener = EventListenerTouchAllAtOnce::create();
704 _eventDispatcher->addEventListenerWithSceneGraphPriority(listener,
this);
706 auto s = Director::getInstance()->getWinSize();
void onTouchesEnded(const std::vector< cocos2d::Touch * > &touches, cocos2d::Event *event)
SimpleSprite * addNewSpriteWithCoords(const cocos2d::Vec2 &p)
引用了 addNewSpriteWithCoords() , 以及 onTouchesEnded().
◆ addNewSpriteWithCoords()
在文件 RenderTextureTest.cpp 第 710 行定义.
712 int idx = CCRANDOM_0_1() * 1400 / 100;
713 int x = (idx%5) * 85;
714 int y = (idx/5) * 121;
720 sprite->setPosition(p);
722 FiniteTimeAction *action =
nullptr;
723 float rd = CCRANDOM_0_1();
726 action = ScaleBy::create(3, 2);
728 action = RotateBy::create(3, 360);
730 action = Blink::create(1, 3);
732 action = TintBy::create(2, 0, -255, -255);
734 action = FadeOut::create(2);
736 auto action_back = action->reverse();
737 auto seq = Sequence::create(action, action_back,
nullptr);
739 sprite->runAction(RepeatForever::create(seq));
static SimpleSprite * create(const char *filename, const cocos2d::Rect &rect)
引用了 SpriteRenderTextureBug::SimpleSprite::create().
被这些函数引用 onTouchesEnded() , 以及 SpriteRenderTextureBug().
◆ CREATE_FUNC()
◆ onTouchesEnded()
| void SpriteRenderTextureBug::onTouchesEnded |
( |
const std::vector< cocos2d::Touch * > & |
touches, |
|
|
cocos2d::Event * |
event |
|
) |
| |
◆ subtitle()
| std::string SpriteRenderTextureBug::subtitle |
( |
| ) |
const |
|
overridevirtual |
◆ title()
| std::string SpriteRenderTextureBug::title |
( |
| ) |
const |
|
overridevirtual |
该类的文档由以下文件生成:
- /Users/yujizhu/Documents/Git/cocos2d-x-4.0/tests/cpp-tests/Classes/RenderTextureTest/RenderTextureTest.h
- /Users/yujizhu/Documents/Git/cocos2d-x-4.0/tests/cpp-tests/Classes/RenderTextureTest/RenderTextureTest.cpp