Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FBO+GLSL write to texture with less than 4 components



Am Donnerstag, 29. November 2007 16:38:43 schrieb Mark:
> > Am Donnerstag, 29. November 2007 13:41:09 schrieb Mark:
> >> On 29.11.2007, at 13:35, Stefan Dösinger wrote:
> >>>> The reason I really want to have the information on a 1 (or 2)
> >>>> component texture is I will be reading it back to the CPU, so
> >>>> avoiding
> >>>> the 3 (or 2) extra components will make the readback a lot faster.
> >>>
> >>> You can just read back single channels, e.g. GL_RED or GL_ALPHA
> >>
> >> Oh, so simple it didn't come to my mind. Can this be done together
> >> with PBO's?
> >
> > I see no reason why it would fail, but the question is how the
> > driver handles
> > this. It might be a non 1:1 copy, so the driver might fall back to
> > downloading everything to the CPU anyway. I guess this needs some
> > benchmarking
>
> Thanks for the help Stefan,
> I think I'll work around it using an ARGB texture and PBO one forth
> the size of the original texture and effectively "pack" my one
> component information into the destination 4 components, swizzling as
> needed so all looks right when back to main memory... guess that's the
> easiest way.
How about a GL_ALPHA only texture? I think that one is renderable. You could 
also try to play with GL_DEPTH_COMPONENT

Attachment: signature.asc
Description: This is a digitally signed message part.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Mac-opengl mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/mac-opengl/email@hidden

This email sent to email@hidden

References: 
 >FBO+GLSL write to texture with less than 4 components (From: Mark <email@hidden>)
 >Re: FBO+GLSL write to texture with less than 4 components (From: Stefan Dösinger <email@hidden>)
 >Re: FBO+GLSL write to texture with less than 4 components (From: Mark <email@hidden>)



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

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.