About sprite sizes

Hi, I have some quastions about sprites:

  1. How cocos2dx works with sizing? I have texture 512x64 and I want to make a sprite from a part of it so I do next:

CCSprite *sprBtns = CCSprite::create(“gump/m_btns.png”);
sprBtns~~>setTextureRect);
But, I get rect smaller than it must be. How to transform pixel sizes to what cocos2dx whants?

  1. Why all sprites are large than they are? Is it nessesary to get there real size always set do

sprBtns~~>setScale(0.5);

  1. If I create many sprites from different parts of same textures, will engine load it to memmory for each sprite or only once?

Ok, as i understand the problem was in setContentScaleFactor, it’s very strange - because in this case texture size dependes on device resolution… Maybe there is some macro to transform them?

Have you tried sprite->setTextureRect(CC_RECT_PIXELS_TO_POINTS(CCRect(0, 0, width, height))); ?