saindd Posted October 28, 2015 Share Posted October 28, 2015 So, both Basic Cloud and Advanced Cloud objects have a very simplistic image texture being used for it's layers. I've been using Gimp's simplex noise to create the cloud textures, but i'm sure it would be much more interesting to have a procedurally generated texture. Since generating clouds is very simple and involves just basic algorithms that can be found in libnoise, the though part comes in the actual integration of the noises generated by libnoise and Torque's textures.Is it possible to create a dynamic Texture object in Torque, based on the 2D noise samples generated by libnoise? Maybe a way to construct the object based on a byte array, instead of a file?The BasicClouds class accepts a string filename, and all maps in the Material class as well. Quote Link to comment Share on other sites More sharing options...
Timmy Posted October 30, 2015 Share Posted October 30, 2015 You can pass raw pixels to GBitmap https://github.com/GarageGames/Torque3D/blob/development/Engine/source/gfx/bitmap/gBitmap.h#L125Than pass that to the GFXTextureManager https://github.com/GarageGames/Torque3D/blob/development/Engine/source/gfx/gfxTextureManager.h#L96 Quote Link to comment Share on other sites More sharing options...
saindd Posted October 30, 2015 Author Share Posted October 30, 2015 Exactly what i was looking for! Thank you, sir. Quote Link to comment Share on other sites More sharing options...
Timmy Posted October 30, 2015 Share Posted October 30, 2015 If you are ever getting super excited about dynamic textures there is also this https://github.com/GarageGames/Torque3D/blob/development/Engine/source/gfx/gfxTextureHandle.h#L76-L84 . Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.