Jump to content

multiple ogl images in one material shader


yongbin

Recommended Posts

Houdini help has an example file on it. It doesn't have it with the new shaders, but the old system works fine for most things. I need to get around and playing with it in the new shaders, myself one day.

from help

.../examples/nodes/sop/layer/MultiTexture.otl

This example demonstrates the use of the layer SOP to layer multiple textures onto a single object.

here are some Past Threads

And some more docs in progress

Edited by LaidlawFX
Link to comment
Share on other sites

Hi LaidlawFX, Thank you for your reply,

I tested it, but it wasn't what I think.

That question above cannot express what I need, sorry.

What I really want is...

if i have these images.

test1.jpg

test2.jpg

test3.jpg

.

.

.

test100.jpg

and

have 100 separated primitives.

Is there an "easy way" to link this images to prims? any expression or node?

Not in rendered image, in viewport.

Thank you.

Link to comment
Share on other sites

The other method you need to assign uv spaces to each primitive assign it a uv level which you can do in a foreach loop, and then on the shader customize it so it's dynamically linked to say x_x amount of texture layers, so when you want 100 it will load then in dynamically. As strong naming convention and dynamic path could handle that.

Outside of that I haven't touched ptex, but from what I understand textureing is based per primitive, so you can try something new with that.

I don't know of a one step process to do this since it combines components of sop uving per primitive, and shop ogl components that are not as robustly implemented in Houdini. It's got to be a multi step process unless some one else knows better. I can try this weekend after I look for apts

Link to comment
Share on other sites

Thank you, LaidlawFX!

Sorry about my late reply. I leave with my computer for several days.

That hip is very helpful. But I think number of the UVs are too much.

So, I've changed some part of it. Please check it and feed back.

You can do it that way, no problem. The multiple uv sets just allows you to use one shader, and let is show in ogl. If you are just doing sprites you can group points and assign shaders to them, too, if you want to use multiple shaders. Using sprites over copy stamped grids at a basic level will be cheaper to render and in your scene.

The only difference is do you want the control of individual shaders, and whether the overhead of more shaders vs the extra attributes is going to cause delays at render time. If you archive your geo, and shaders, the shaders become the only over head. The extra attributes get wiped.

Also you could use the local override of a material sop of the color map and then copy stamp random a set of different materials.

Edited by LaidlawFX
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...