GUIBitmap from Bitmap not File (Solved)
by Robert Schmidt · in Torque X 2D · 05/10/2008 (10:02 pm) · 2 replies
I am working on a data driven game where much of the content is in compressed files not managed by the content pipeline. As a result, I can't load bitmaps from file like GuiContols and Sprites seem to require. I need to extract them from a file at which point I have a Bitmap variable. Does anyone know of a way to create a texture or material from a bitmap variable in code?
Thanks
Thanks
#2
A word of caution though: Use a source control system (TortoiseSVN for example, which is a great Windows front-end to Subversion and is free). That way, when GarageGames releases an update to TorqueX you can do a merge to integrate your changes. I always leave the source in the install directory alone.
05/12/2008 (5:34 pm)
Feature tip: I highly suggest anyone trying to do serious work with TorqueX to pickup the Pro license so you have access to the source code. It makes things far easier to debug, and also allows you to add various modifications.A word of caution though: Use a source control system (TortoiseSVN for example, which is a great Windows front-end to Subversion and is free). That way, when GarageGames releases an update to TorqueX you can do a merge to integrate your changes. I always leave the source in the install directory alone.
Torque Owner Robert Schmidt
Create a texture from a stream
Hack the GuiBitmap control to accept a texture rather than just a filename
TO GG. It would be nice if you could expose a SetTexture method on the GUIBitmap object like you do for its underlying SimpleMaterial. Either that or add SetTexture to the GUIBitmapStyle object and get the texture from there. I don't know why you don't now.