Re: Color shifted 240 degrees in Hue
Re: Color shifted 240 degrees in Hue
- Subject: Re: Color shifted 240 degrees in Hue
- From: Darrin Cardani <email@hidden>
- Date: Thu, 31 Jul 2008 09:06:55 -0700
On Jul 31, 2008, at 7:42 AM, Brad Wright wrote:
I'm trying to track down an issue where I see the color shift 240
degrees in Hue from inside the Core Image Filter chain. As a test
to track down the problem, I'm using a Core Image Filter that I
created that will display a solid color to the screen. The Core
Image filter works in stand alone application and displays the
correct color to the Open GL context. I'm using the passed in
FxTexture from RenderOutput and wrapping that to a CIImage. The
image is drawn to the Open GL context and the color in the original
video frame is displayed correctly in color. There's no shift in
the original FxTexture. However, when the core image filter is
applied to this image, the solid color being displayed by the core
image filter is shifted around 240 degrees in Hue. I've tried a
bunch of standard core image filters for manipulating the color in
the image and they all have the same problem. In the CIColor used
for this custom core image filter, specifying a solid blue color
results in a red color being displayed to the screen. Creating a
solid green CIColor displays as solid blue. Creating a solid red
CIColor displays as solid green.
So while the FxTexture is displayed on the screen correctly, any
manipulation of the image with Core Image filters or anything of
that sort is shifted around 240 degrees in Hue. Again, all the core
image filters that I've applied all exhibit this color shift. Any
ideas what could cause this?
It sounds like a channel order problem. Are you declaring all of your
buffers with their actually channel order? I believe that FxTextures
will be in RGBA format. If your CoreImage filters expect BGRA, or
ARGB, you might see problems similar to what you're describing.
(Though from you description, it sounds like one buffer would be in
GRBA or BRGA order, which is not valid in any system I know of.) Is it
possible that somewhere along the line you've specified an incorrect
swizzle order?
Darrin
--
Darrin Cardani
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden