API Question Dynamically changing a UV map

Hlynkacg

Aspiring rocket scientist
Addon Developer
Tutorial Publisher
Donator
Joined
Dec 27, 2010
Messages
1,870
Reaction score
3
Points
0
Location
San Diego
Like the title says, I've read treferences to changing a mesh's UV coordinates as an alternative to blitting but haven't been able to find or examples of how this is actually done.

Does it work?

Is it easier (from a system resource stand point) than blitting?

How do I do it?
 

Bibi Uncle

50% Orbinaut, 50% Developer
Addon Developer
Joined
Aug 12, 2010
Messages
192
Reaction score
0
Points
0
Location
Québec, QC
Using oapiMeshGroup() and then modifying the returned MESHGROUP pointer should do the trick. I recommend using the DEVMESHHANDLE instead of the MESHHANDLE, in order to maintain compatibility with external client.

I am pretty sure that it is more efficient than blitting, but this is just speculation based on my previous work with Direct3D.

In order to improve the performances further more, you can use the DYNAMIC flag in your mesh, as explained by Martin in this thread: http://www.orbiter-forum.com/showthread.php?t=19531&highlight=dynamic+flag
 
Top