terrain generation from pvr Texture directly

This topic contains 2 replies, has 2 voices, and was last updated by  dgu 4 years, 5 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #31257

    dgu
    Member

    Dear Team

    i know how to generate terrain from a bitmap , but i was wondering how to do it directly from a png converted to pvr , how can i access to the pixel ( x,y ) r,g,b values ?

    thanks in advance

    david

    #37215

    Hi Dgu,

    PVR files are stored in a simple, linear texel array, there’s no file compression going on in a basic PVR. You can literally just access each pixel directly. If you have it stored as, say, RGBA8888, every 32 bits will be a new pixel, and each 8bit value within that will be a different channel.

    It should be largely the same as accessing a bitmap array, just with different formats supported. You can also just bind them as a texture and perform vertex texture reads on supported platforms (sadly, this does not include iOS though).

    Thanks,
    Tobias

    #37216

    dgu
    Member

    thanks Tobias ,that is really interesting , it s my todo list now

Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic.