I'm having a bit of trouble figuring out how to add a texture to this half sphere generation code. As the title says, I'm trying to create a simple skydome, but I'm attempting to use a horizontal texture @ 512x128, so it has to wrap around. I've searched the net for days, but have never found a single ounce of code that does what I need to do here. This is what I have so far:
#define PI 3.1415926535897932384626433832795
#define K1 PI/20.f
#define K2 PI/20.f
#define R 100
static int t1,t2;
So, how would generate the texture coordinates from this? Any ideas? Thanks.
Follow Shogun3D on the official website: http://shogun3d.net
"Yo mama so fat, she can't be frustum culled." - yoshi_lol
"One objection to a “critique of C#” would be that you can’t talk about C# without talking about the whole “.Net experience”. However, one can approach the topic of Hitler without a complete discussion of Nationalist Socialism, so I feel justified." - Steve White.