OK I'm just getting in OpenGL, and if I'm sincere, then it's very challenging.
For my current challenge, I need a little guidance to be told in the right direction.
I have some code that creates a 3D area, which has a texture (a globe).
I can get touch coordination on the field and handle it on one hand, but my question is how do I add another texture to that area?
I want to be able to touch the world and then "highlight specific areas", then I want to be a "highlights image" and then I want to map that image to the globe on touch.
The touch point will wrap around this image area.
Am I thinking that this is a matter of adding another texture to the already textured area? What will be the right approach for this?
Do I just need to make a 2D texture to map or do I need a 3D texture (is there any such thing?)
All this very confusing and some common indicators will be highly appreciated.
Many thanks in advance!
If you have a highlight image that you want to apply to the point of touch In short, you can apply the highlight image first to the original structure (only rendering one above the other in a different rendering pass), then using the composite image as your texture.
To consider things:
- Texture coordinates are independent of the coordinates of your geometry, so if you do not have it already, then you have to touch the point and texture Point (coordinate pair)
- To get the highlight to wrap on the edge, you have to set the proper texture parameter - in this case,
GL_REPEAT
should work
For your other questions, yes, there are; However, I do not consider them relevant to their work.
Comments
Post a Comment