Images VS Textures

About Monkey 2 Forums Monkey 2 Programming Help Images VS Textures

This topic contains 3 replies, has 2 voices, and was last updated by  Simon Armstrong 2 years, 10 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #2528

    eymandoo
    Participant

    So, the Image is actually an SDL surface? Am I right to assume this or no?

     

    The texture data is a pixmap loaded from a file, I read the files and it appears loading an image just renders it into pixmap data inside a texture data type?

     

    So, what should I be working with if I am using gles20? Textures? Or both?

    What are their key differences. Which is better for memory or performance or easier to animate?

    #2531

    Simon Armstrong
    Participant

    An image is a rectangular area of a texture, and a pixmap is a utility class to abstract complexity of working with various pixel formats.

    SDL2 is used as a device manager and it’s drawing API is not used as IMHO mojo2 is superior in design and elegance.

    If you want easy I think you should stick with the standard core Monkey2 command set for your initial projects.

    #2535

    eymandoo
    Participant

    hmm, ok, I had one more question, how does viewport get handled? Does it automatically not draw things outside of the set initial _canvas frame:rects?

    #2536

    Simon Armstrong
    Participant

    Mojo does clipping GPU side with Canvas Scissor but it doesn’t do any kind of box culling before that.

    I typically DebugStop and step in when I want to understand how mojo is working.

    Attachments:
Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.