Jump to content
  • Advertisement
Sign in to follow this  
xnunes

Does anyone know how to create/delete a vertex in the hull shader??

This topic is 2952 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

This is really a weird thing to me, I have browsed the whole msdn documentation and couldn't find any info on this.

So, how do I emit vertex or delete a vertex in the hull shader?

I know I can output the number of control points specified "outputcontrolpoints()" but HOW do I create a new control point?? Couldn't find any info on this at the documentation...

Share this post


Link to post
Share on other sites
Advertisement
I'm not sure what you're attempting to do, but it is possible to increase or decrease the number of control points in the hull shader. The hull shader is invoked per patch with a frequency equal to the value you used for the attribute 'outputcontrolpoints()'. This value is fixed per compile of the hull shader function. There is no other control to discard or create a control point. Those abilities are available to the geometry shader, which can programmatically decided on the number of vertices/control points to output.


If you're trying to change the number of vertices produced by the tessellator then you'll have to tweak the edge factors in the patch constant function, or change the attributes on the hull shader function and recompile.

[Edited by - DieterVW on July 19, 2010 2:04:32 PM]

Share this post


Link to post
Share on other sites
Hum... So the only way to increase or decrease the number of control points is by this fixed parameter on outputcontrolpoints()??

If I only send one vertex to the pipeline and put outputcontrolpoints(4). I'm creating 3 new control points right???

So the output will be a quad with an input of only one vertex to the pipeline right??

Am I able to do this???

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!