Lines Matching refs:cg
93 CGContextRef cg = (CGContextRef)fCanvas->accessTopRasterHandle(); in drawRect() local
100 CGContextSetFillColorWithColor(cg, color); in drawRect()
101 CGContextFillRect(cg, CGRectMake(r.x(), r.y(), r.width(), r.height())); in drawRect()
105 static CGAffineTransform matrix_to_transform(CGContextRef cg, const SkMatrix& ctm) { in matrix_to_transform() argument
108 matrix.postTranslate(0, SkIntToScalar(CGBitmapContextGetHeight(cg))); in matrix_to_transform()
125 CGContextRef cg = SkCreateCGContext(SkPixmap(info, nullptr, 0)); in allocHandle() local
126 if (!cg) { in allocHandle()
130 rec->fReleaseCtx = cg; in allocHandle()
131 rec->fPixels = CGBitmapContextGetData(cg); in allocHandle()
132 rec->fRowBytes = CGBitmapContextGetBytesPerRow(cg); in allocHandle()
133 rec->fHandle = cg; in allocHandle()
134 CGContextSaveGState(cg); // balanced each time updateContext is called in allocHandle()
139 CGContextRef cg = (CGContextRef)hndl; in updateHandle() local
141 CGContextRestoreGState(cg); in updateHandle()
142 CGContextSaveGState(cg); in updateHandle()
143 CGContextClipToRect(cg, CGRectMake(clip.x(), clip.y(), clip.width(), clip.height())); in updateHandle()
144 CGContextConcatCTM(cg, matrix_to_transform(cg, ctm)); in updateHandle()