ios - How to store CGLayers in Drawing -


I am working with CgLayers for drawing in iOS, now I want to store these layers and after that I want to retrieve, so I want to know what the available options are. I tried to use NSMutableDictionary, the code below, is

  - (zero) touchesEnded: ( UIEvent *) Event {CGLayerRef testLayer = CGLayerCreateWithContext (UIGraphicsGetCurrentContext (), Self: (with NSSet *) touching withEvent .bounds.size, NULL); CGContextRef Reference = CGLayerGetContext (Test Layer); CGContextDrawLayerAtPoint (reference, CGPointZero, myLayerRef); // Here my basic layer is my lairf NSValue * layerCopy = [NSValue valueWithPointer: testLayer]; NSDictionary * lineInfo = [Object EndCase with NSDictionary dictionary: LayerCopy, @ "Image", zero]; [M_PathrayAdd object: LineInfo]; } - Recover (zero) {NSDictionary * lineInfo = [m_pathArray lastObject]; NSValue * val = [lineInfo valueForKey: @ "IMAGE"]; CGLayerRef Parft = (CGLERF) [Val Pointeval]; CGContextRef Reference1 = CGLayerGetContext (layerRef); CGContextDrawLayerAtPoint (context1, CGPointMake (00, 00), layerRef); [Self setNeedsDisplayInRect: self.bounds]; }  

Submitted Ranjit


Comments

Popular posts from this blog

java - NullPointerException for a 2d Array -

python - Assemble mpeg file unable to play in mediaplayer -

c# - NameSpace Manager or XsltContent to parse aspx page -