120 shader object

Started by dhavalmistry, April 03, 2007, 04:37:13 PM

Previous topic - Next topic

dhavalmistry

Hi, I have an object with 120 different shaders and a multi shader can only handle 16 shaders at once....

is there any way of bringing all those shaders into TG2 . I mean TG2 can only load 16 out of 120 textures.....how do I load rest of the textures???
"His blood-terragen level is 99.99%...he is definitely drunk on Terragen!"

Oshyan

The only way at present is to split the model up into sections each with 16 textures a piece then import all the pieces and position appropriately in TG2. If you are able to split them with a common origin point they should line up automatically when imported.

We'll certainly be supporting higher texture counts in the future.

- Oshyan

mr-miley

I may well be talking out of my butt here but...... If you have an application that will handle it, could you not UV unwrap it to a single bitmap, and then just apply it as an image map with object UV as the projection type??  ??? I have no idea if this would work, its just a suggestion.

ta

Miles
I love the smell of caffine in the morning

Oshyan

That could definitely work, assuming the app supported that conversion, but you'd probably need a fairly high resolution map to maintain detail.

- Oshyan

dhavalmistry

if its possible then can anybody do it for me please???....
"His blood-terragen level is 99.99%...he is definitely drunk on Terragen!"

Aenea

I also have problems with the "more than 16 shaders objects...ahem", and I think I´ll spend some time on it solving this. Maybe you can add multi shaders into merge shaders (thanks for the tip king_tiger)....that´s the only thing I know at the moment.

oshyan: your suggestion sounds interesting...can you please explain this with an example? How do I split an object or do I only split the textures (shaders)...at the moment I have no idea how to do that...and to get a working result of course  ;)

Aenea

Njen

You would have to do that in a program used for modeling: Blender, Max, Maya, etc.

mr-miley

I have just made an object to drop into a scene. I was made up of about 300 components, many of them having the same materials / shaders. I did the modeling in 3D studio. In 3D Studio I grouped all the individual objects with the same material and applied the material to the group. When you export it as an OBJ file it keeps the groups and I have ended up with a material fils containing only 7 different materials (there were 7 groups in the 3DS file. I have never done any modeling with Wings / blender etc so I don't know if you have the option to do something similar or not. Hope this helps.

Miles
I love the smell of caffine in the morning

Oshyan

Any model adjustments, splitting, material combining, etc. would have to be done in another program dedicated to 3D modeling, as njen said. Specific techniques would depend on the application and are outside the scope of my knowledge I'm afraid.

- Oshyan

peejay

#9
I'm rendering a test of this as we speak. A version of the DAZ Millenium Dragon2 for Poser. I exported three divisons of the same model, one of the head, one of the wings, one of the body. As Oshyan said, the really cool bit is that even when rotating, resizing and translating, the three parts stay together, provided they were lined up in the first place inside Poser.

What you will have to do that wasn't mentioned is edit the .mtl file for each part and take out the references to the bits that aren't being used by the section your using.

Sorry if that sounds confusing. For example if you have your dragon model in Poser, go to file/export/obj then deselect all the body parts you don't want, then export. you will end up with an .obj of the part you want (say the wings), but the accompanying .mtl will have references to all the other material parts (eyes, tongue, teeth etc) that you don't want. The whole point of splitting the model is to reduce the number of material inputs to below 16, so you must go into a text editor and remove all the references in the .mtl file that are not materials on the wings.

Now you can import these seperate parts into TG2 and hey presto they appear in the right places relative to each other. Just make sure you apply the same translations, rotations etc to each part and they will keep together.

enclosed is the first test without any fill light, but you can see that it works. the little fella is about 2000m up, over 3km from origin, rotated through 150 degrees. Oh and he's been resized as well.
adamans rebellis quod iustus nos

Mohawk20

Up to now I haven't been able to export an object with 3DsMax that has the option of more than 1 material when imported in TG2.
I did manage to split the object in parts and apply multiple materials like that, but it would be nice if someone could tell me how to export an object in Max correctly, so that I can atleast apply 3 materials to one single object in TG...
Howgh!

rcallicotte

Thanks for the explanation.  The example helped.

Quote from: peejay on April 04, 2007, 02:46:25 PM
Just make sure you apply the same translations, rotations etc to each part and they will keep together.
So this is Disney World.  Can we live here?

Aenea

@peejay:  I think this explanation sounds worth a try.....I think I now know what to do.....If this works with poseray too, as far as I see there´s also an option to group objects or separate, I try it there first....otherwise I have to wait until I get Poser....think that´ll be next week or so.....

Thanks anyway for your help....alltogether they are all very useful for me!

Aenea

bigben

Quote from: Mohawk20 on April 04, 2007, 05:21:03 PM
Up to now I haven't been able to export an object with 3DsMax that has the option of more than 1 material when imported in TG2.
I did manage to split the object in parts and apply multiple materials like that, but it would be nice if someone could tell me how to export an object in Max correctly, so that I can atleast apply 3 materials to one single object in TG...

I've seen this with some models I've downloaded.  Opening them with PoseRay and converting materials to groups fixed this. Someone with more modelling knowledge might be able to point you to a way of exporting them in a compatible form direct from Max.

Aenea

Hey guys!

I got it working.

Like suggested I imported the whitestar.obj-file into a 3d program. In my case it was Blender.
I deleted three objects of the whitestar (left and right wing and the bridge) and was able to reduce the shaders/textures below 16. Then I exported the remaining parts (selcetd all, exported them as obj with mtl file).
This was my part1.obj file. I imported it into poseray to adjust the textures again and saved it again.

Then I made the second part, where only the left and right wing and the bridge remained and did the same with it.

Then I opened TG2 and imported the two obj-files. Making sure they have the same transformation, rotation etc.....they perfectly fit together and I got this result after rendering....


I´m writing a short tut about it....
So I think every obj. can imported into TG2 by separating it....thanks for your hints and tips!!!!!!!!!!


Aenea