d3d9: Add DF16 support

Frank Richter frank.richter at gmail.com
Sun Jun 7 16:05:41 CDT 2009


On 07.06.2009 22:22, Henri Verbeet wrote:
> Even if the format isn't lockable, you can still use the data with a
> shader. 

If it's a typical depth format the shader will see normalized values.

Information on DF16 seems to be sparse, one thing I found was:
http://discussms.hosting.lsoft.com/SCRIPTS/WA-MSD.EXE?A2=ind0611A&L=DIRECTXDEV&P=R2492&I=-3&d=No+Match%3BMatch%3BMatches
It says that DF16 returns "real" depth values - which would indeed be
normalized.

> Typically float formats aren't normalized, so you can have
> values outside the traditional [0.0,1.0] range. 
> If there's no specific
> extension for this format you could use GL_DEPTH_COMPONENT32F as
> internal format and GL_HALF_FLOAT_ARB as type, although that would
> waste some memory, of course.

On what graphics cards is that extension supported?
DF16 is supported since the R300. It appears that float depth formats
are much younger, so it seems unlikely DF16 is actually a float format
internally.
Does D3D(9) allow a depth range outside [0.0,1.0] anyway?

> Is there any specific application that
> needs this format?

Some ATI graphics demos (e.g. Toy Shop).
Probably at least some games that use shadow mapping.

-f.r.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 261 bytes
Desc: OpenPGP digital signature
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20090607/108cd794/attachment.pgp>


More information about the wine-devel mailing list