How to get coordinates from a image for CGRectMake
Is there a program, that you can drag a box around a specific area of an image, and it will give you the coordinates开发者_开发问答 you need to input into CGRectMake
?
//The numbers in here
CCSprite *sprite = [CCSprite spriteWithSpriteSheet:spriteSheet rect:CGRectMake(608,6,44,45)];
The way i do it know, is by guessing, and recompiling every time till i get it right... there has to be a better way.
You have the Pixie app pre-installed on Mac.
I am not a designer and don't have tools like Photoshop, so Pixie does quite a good job for my needs.
One thing that you are better to change in the Preferences is to check the "Mouse Hot Spot" checkbox so that you will see the current pixel in the center...
Your image processing software is a good candidate. I.e. if you select a region in Photoshop, the info panel will give you this information.
精彩评论