You are forcing the CIContext to process images in GenericRGB colorspace instead of the default LinearRGB colorspace, which is not recommended and is likely to give incorrect results. You should leave kCIContextWorkingColorSpace to its default unless you have a very good reason for it.

CIContexts used by QC always use the LinearRGB as the processing colorspace.

On Dec 4, 2007, at 1:08 PM, Raphael Sebbe @ Google wrote:

Hi,

I have a few different pipelines rendering images, some QC-based, some OpenGL/CI-based, some Quartz/CI-based. All have colorspaces associated.

The QC-based renderings has a slightly different color output. I think this is because my CI-based contexts have this setup, which sems not possible to create through QCRenderer:

CGColorSpaceRef colorSpace = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB);
NSDictionary *options = [NSDictionary dictionaryWithObjectsAndKeys:
                                         
(id)colorSpace,kCIContextOutputColorSpace,
                                         
(id)colorSpace,kCIContextWorkingColorSpace,
                                         nil];
_hiresImageContext = [CIContext contextWithCGContext:_hiresGraphicsContext options:options];


The rendering are the same if options is set to nil in the CI-based contexts. QCRenderer is created with this code:

CGColorSpaceRef colorSpace = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB); id path = [[NSBundle mainBundle] pathForResource:@"HYTheater" ofType:@"qtz" inDirectory:nil];
        id composition = [QCComposition compositionWithFile:path];
_qcTheater = [[QCRenderer alloc] initWithCGLContext:[_openGLContext CGLContextObj] pixelFormat:[_openGLPixelFormat CGLPixelFormatObj] colorSpace:colorSpace composition:composition];

Any advice to setup the QCRenderer to render the same as CIContexts ?

Thanks,

Raphael
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list ([email protected] )
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/pol%40apple.com

This email sent to [EMAIL PROTECTED]

________________________________
Pierre-Olivier Latour - [EMAIL PROTECTED]
Technologist - Apple, Inc.



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to