Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Core Image outputs 8 bit floats?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Image outputs 8 bit floats?



Thank you! It took me a few days to figure out how to put this together, but I think I have it working and I think I'm now calculating with 16 and 32 bit color values.

The next step was to figure out that Area Average needs to be calculated in a Render in Image as well. Once I got that figured out, I'm getting the smooth output I'd hoped for-- the problems I'm having now are problems with the core algorithm, I think.

I'm glad I asked, because I never would have figured this out. It would be nice to be able to choose the color depth of the whole composition rather than have to wrap individual pieces in a special macro.

Thanks again--
 Greg



On Oct 16, 2008, at 1:19 PM, Chris Wood wrote:

The output format depends on both hardware and the context the rendering is done in. If you have an intel GPU (i.e. macbook or mac mini), you're stuck with 8bit integer because that's all the hardware supports (this caused much head scratching for me last week), older cards won't support 16/32bit float too but anything recent from ati or nvidia will do it.

The next thing is the context: I think QC runs in an 8bit integer context, so that's what you'll get from CI (it would be very slow if it ran in 128bit (which actually means 32bit float, 4 (for rgba) x32 = 128) all the time when you're only targeting an 8bit render.

You can force 16/32bit float processing with a render in image - send what you're doing to a billboard inside a render in image and set it to 16/32bit and your processing will be done at that precision. 32bit tends to be a lot slower than 16bit, and you lose things like filtering which might be important, so 16bit is better if it's accurate enough.

Chris

On 16 Oct 2008, at 20:53, Greg Best wrote:


I think I'm finally zeroing in on the causes of my headaches-- it looks like the image that CI is spitting back to me is using 8 bit floats. Actually, I think they're 8 bit fixed point values because I'm limited to the range of [0,1]. My Core Image patch won't give me an image back with any value less than 0.00392 (which is about 1/255).


0.002 gets rounded up to 0.00392, and dividing that number in half gives me zero.

The Core Image docs say it treats everything like 128bit floats, so am I facing a hardware limitation or a QC limitation? Is there anyway to get more resolution?

Thanks--
Greg


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list (email@hidden )
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Quartzcomposer-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Core Image outputs 8 bit floats? (From: Greg Best <email@hidden>)
 >Re: Core Image outputs 8 bit floats? (From: Chris Wood <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.