Horde3D

Next-Generation Graphics Engine
It is currently 02.05.2025, 15:06

All times are UTC + 1 hour




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: 12.07.2008, 19:59 
Offline

Joined: 05.07.2008, 21:12
Posts: 26
Hello! I've got a great idea to make several objects on my game with little effort to the artists...

Create 9 models, 9 colour textures and 9 bump textures, and combine them randomly when creating a new object, the resoult would be 729 combinations...

But I do not want to write 729 material files!

So, after much search on the forum, on the documentation, and asking the guys at IRC (again! PLEASE PEOPLE! JOIN IRC! NOW THERE ARE PEOPLE THERE!!!), I do not found a awnser to this question:

How I change the texture of a node?

Remembering that I would need to to that when I need to load a movie (I will need that too...)


Top
 Profile  
Reply with quote  
PostPosted: 12.07.2008, 23:31 
Offline
Tool Developer

Joined: 13.11.2007, 11:07
Posts: 1150
Location: Germany
Currently it's only possible to replace the whole material I think. Maybe we should add something like MaterialResParams that would allow querying/changing the texture resource using get/setResourceParami. This would also allow changing the shaders without adding a new material.


Top
 Profile  
Reply with quote  
PostPosted: 13.07.2008, 00:41 
Offline

Joined: 05.07.2008, 21:12
Posts: 26
So, what is the point of "CreateTexture2D" ?

And how I play videos?


Top
 Profile  
Reply with quote  
PostPosted: 13.07.2008, 07:54 
Offline
Tool Developer

Joined: 13.11.2007, 11:07
Posts: 1150
Location: Germany
Using createTexture2D you can add a Texture Resource with the specified dimension, e.g. to create a render buffer. You can also update this resource later using updateResourceData. If all your textures are of the same format using this method should be fine. If you have different textures you have to add them separately.

Regarding the video playing: Did you already read this thread?


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 77 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group