Sign in to follow this  

FVF or shaders?

This topic is 4584 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I've heard the FVF to be a bit faster than the shader codes, so its better to take advantage of the Direct3D built-in render pipeline whenever possible. Am I right? or the new hardware provide acceptable speed? Also how can I get some demos and tutorials about pixel shaders? it seems that pixel shaders are less discussed, why?

Share this post


Link to post
Share on other sites
No, FVF codes are typically compiled into shader code so there won't be any difference. You should only really support FVF if you need to run on hardware that doesn't have shaders. But at the end of the day, it's up to you.

Share this post


Link to post
Share on other sites
Quote:
Original post by vcGamer
I've heard the FVF to be a bit faster than the shader codes


Only on hardware older than a GFFX (or thereabouts). Shaders are usually faster on newer hardware because you can strip away all unnecessary operations.

Share this post


Link to post
Share on other sites
Quote:
Original post by superpig
Quote:
Original post by vcGamer
I've heard the FVF to be a bit faster than the shader codes


Only on hardware older than a GFFX (or thereabouts). Shaders are usually faster on newer hardware because you can strip away all unnecessary operations.

Yes. IIRC:
Everything from ATi since the Radeon8500 implements the fixed-function pipe in shaders. nVidia's pre-GeForce FX have dedicated fixed-function lighting hardware, so they run the fixed-function pipeline faster.

Share this post


Link to post
Share on other sites
Quote:
Original post by Trip99
I have heard rumours that FVF may be removed from DX10, or at least moved into the D3DX library.
How can you put the fixed function pipeline in a utility library? You set render + texture stage states, set the vertex+index streams and basically set the shader to point to the FVF declaration for the vertex.
It would be a major pain having to write shaders to everything, line 2D HUD graphics, menu screens etc.

Share this post


Link to post
Share on other sites
Quote:
Original post by d000hgHow can you put the fixed function pipeline in a utility library?


Why not? Required state in, Shader code out. Simple. But then if you are on DX9+ you aren't likely to be using the fixed function path anyway.

Share this post


Link to post
Share on other sites
Quote:
Original post by Coder
Quote:
Original post by superpig
Quote:
Original post by vcGamer
I've heard the FVF to be a bit faster than the shader codes


Only on hardware older than a GFFX (or thereabouts). Shaders are usually faster on newer hardware because you can strip away all unnecessary operations.

Yes. IIRC:
Everything from ATi since the Radeon8500 implements the fixed-function pipe in shaders. nVidia's pre-GeForce FX have dedicated fixed-function lighting hardware, so they run the fixed-function pipeline faster.


Point of clarity: they run it faster for the same functionality. If your vertex shader is just 'mov oPos, v0' then you'll see it running faster than fixed function vertex processing on a GF3 [smile]

Share this post


Link to post
Share on other sites

This topic is 4584 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this