I applied a mask to SKCropNode And I see what i need now but the cropped node has the size of the full image i just want to access the cropped part not the full image can i get that into SKSpriteNode??
Here is my code
SKSpriteNode *pic = [SKSpriteNode spriteNodeWithImageNamed:@"test.png"];
pic.name = @"PictureNode";
SKSpriteNode *mask = [SKSpriteNode spriteNodeWithImageNamed:@"2.png"];
mask.size=CGSizeMake(50, 50);
mask.position=CGPointMake(0, 50);
SKCropNode *cropNode = [SKCropNode node];
cropNode.position=CGPointMake(160, 70);
[cropNode addChild:pic];
[cropNode setMaskNode:mask];
[self addChild:cropNode];
and here are the images and result :
Thanks in advance