Drawing 2d image in Window?
-
- Posts: 86
- Joined: Wed Aug 29, 2007 10:45 pm
So, I tried to use IGUIImage, and it seems better than draw2DImage, except for something: is there a way to take only a portion of the image file and draw only that portion? I mean, IGUIImage takes a texture to draw, and the texture is taken directly from a image file. I only want to use a portion (a rectangle) of the image file in the IGUIImage. How can I do that?
Proud member of the Online Campaign for Real English. If you believe in capital letters, correct spelling and good sentence structure then copy this into your signature.
The answer lies in my original post in this thread (emphasis added)...Magus_Stragus wrote:So, I tried to use IGUIImage, and it seems better than draw2DImage, except for something: is there a way to take only a portion of the image file and draw only that portion? I mean, IGUIImage takes a texture to draw, and the texture is taken directly from a image file. I only want to use a portion (a rectangle) of the image file in the IGUIImage. How can I do that?
vitek wrote:You need to use a gui element. Either write your own that calls draw2DImage() or use IGUIImage.
-
- Posts: 86
- Joined: Wed Aug 29, 2007 10:45 pm
So, I tried to do that. I took the CGUIImage files included in the source folder and modified them so I could extract just a portion of the wanted texture. However, now I can't seem to make it work. It's my first time creating (well, modifying) a GUI element, so I could use a little help with that.
I would appreciate any help.
I would appreciate any help.
Proud member of the Online Campaign for Real English. If you believe in capital letters, correct spelling and good sentence structure then copy this into your signature.