Sign in to follow this  

one vertex, two textures: how do I?

This topic is 4357 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'm learning direct3d9, and i'm trying to make a "3ds view" application, that loads .3ds files and displays it. It's working fine now, I learned a lot, but today I got a very confusing doubt: Imagine you have: two faces, let's say face A (with texture 1 - large texture, high tiling) and face B (with texture 2 - no tiling); one vertex that belongs to the faces A and B; the flexible vertex format used is: struct Vertex { D3DXVECTOR3 position, normal; float u, v; //texture coordinates }; The question: how can the same vertex share the texture coordinates for the two faces to witch it belongs?

Share this post


Link to post
Share on other sites
I just realized there's another solution: take the vertex, set texture 1 active, draw, lock the vertex buffer, change the texture coordinates, unlock the buffer, set texture 2 active and draw again. What is better: this solution or duplicating the vertex???

Share this post


Link to post
Share on other sites

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