New empty image

About Monkey 2 Forums Monkey 2 Programming Help New empty image

This topic contains 2 replies, has 3 voices, and was last updated by  nerobot 1 year, 4 months ago.

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

    Hezkore
    Participant

    I’m trying to create an empty image.
    I’m doing New Image(width,height,TextureFlags.Dynamic) but it comes out as fully red.
    Clearing the image with Color.None takes a few MS which feels like a waste.
    Can I somehow create a completely empty image from the start?

    #11924

    PhatPeter
    Participant

    Did you solve this?

    #11925

    nerobot
    Participant

    There is a method inside of Texture class:

    It seems there is a place where default color is used: image.Clear( Color.Magenta )

    Simple solution here can be to add global var like DefaultFillColor into Texture,

    then we can set it before creating any images and avoid re-clearing.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.