Possible to use a copy stamp value inside a COP network?

   4995   13   1
User Avatar
Member
271 posts
Joined: March 2012
Offline
Hi all,
My basic problem is this: I have a single image made up of many squares (it's a UV check image currently) and I have a bunch of objects that have been copied. With all of these copied objects, I want one of these many squares to show on the material.
I'm trying to do this by using a COP network inside the SOP network and to use the copy stamped point number (called pt_num in my file), but it just doesn't work.

Any ideas how I go about doing this?
User Avatar
Member
271 posts
Joined: March 2012
Offline
Looks like I may have forgotten to attach the file.
I'm not sure if this scene is too complicated - if it is, let me know so I can try and make a simple one.

Attachments:
go_totem_v002.hipnc (1.5 MB)

User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
If you just wanna use stamp function to make randomness uv transformation per each piece ,Why don't you do it in the SOP network with “UV Transform SOP” ?

Like uvtransform1 in your project file ! :?
https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
271 posts
Joined: March 2012
Offline
That was what I initially tried, but I just couldn't seem to get the result I wanted.
I've attached another version of the scene showing my problem with this method, but maybe you can find a way around it?

The problem is, I only want one of the tiles to show at the top of each totem, not the whole front face as is currently shown. Is there a way to crop the projection so it only effects one part of a face?

Attachments:
go_totem_v003.zip (155.1 KB)

User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
I don't know what do you want to do exactly :?
Can you upload your texture file ? (UV_2048.png)

Do you want to do something like this image ?

Attachments:
totem.jpg (39.3 KB)

https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
Check this file , Do you want to do this ? :?
Edited by - Nov. 26, 2013 06:38:31
https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
271 posts
Joined: March 2012
Offline
Hi Joker,
I've uploaded the image.
What you have done is similar to what I'm after, but I wanted the image on the front face of each box (totem), pointing outwards. But I only want to show a single square from the image, placed at the top. Unfortunately, the image will cover the entire front face, which is not what I'm after. Reload the v003 file with the image attached for the material and you should see what I mean.

Also, I just want to say thank you for your help. If it weren't for people like you I'd be totally stuck.

Attachments:
UV_2048.zip (269.5 KB)

User Avatar
Member
271 posts
Joined: March 2012
Offline
What I'm currently thinking is that I should layer two materials, so that the rest of the image that I don't want to show is obscured.
However, I cannot find a way to layer materials. All the examples refer to a layered material that doesn't seem to be available any more, or is deprecated. If so, how do I layer materials in H12?
User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
OK ,This is simple example that I used Mask Map to define which place we should use ColorMap (Something like Layer Material)

Maybe It's useful for you :-)
Edited by - Nov. 26, 2013 06:38:58
https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
271 posts
Joined: March 2012
Offline
Thanks for the reply Joker.
I'm used to using other packages where layering images is a task that is done so often, that there are tools to do this natively. I see that in Houdini, you can do almost anything, but it seems to take a lot more work than I'm used to

Anyway, following on from your example, I tried to use a COP network to procedurally create the mask (as it depends on some variables).
However, the renderer just refuses to load the result of the COP network, just saying
mantra: Unable to load texture ‘op
I've tried many variations of the op syntax, but nothing works.

Attachments:
go_totem_v004.zip (209.3 KB)

User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
You should use “Promote Parameter” for mask map and write op:`opfullpath(“../totem_mask/_OUT”)` expression out of the VEX network 8)
https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
271 posts
Joined: March 2012
Offline
I'm sorry, I still can't get it to work
Could you send a hip file? If I promote a parameter, it just generates an input that is still in the VEX network.

Also, why doesn't this work inside a VEX network? Even if I open the UV_2048.png image using the file chooser, I get the same error. It wont load any images at all.
mantra: Unable to load texture ‘$HIP/images/UV_2048.png’
It's the same if I manually type in the absolute path.

Edit: I managed to promote the cmap, but again I just get this
mantra: Unable to load texture ‘op

Another edit: I think I got the image to apply…but it's not doing what I expect. Watch this space…
User Avatar
Member
1391 posts
Joined: Dec. 2010
Offline
Ok ,I think it's better that I make your project ,my friend

In your project you need 2 different UV set. First for ColorMap and second for Mask !

You can do it with Layers (Check Attached File's sticky notes).

In the VEX network you can just use simple image path (like : $HIP/texture/map1.pic) and you can't use expression path like op:…. or sequence textures like $HIP/texture/map$F.pic , for these you shoud Promote your Parameters in the outside of the VEX builder !

I fix your problem about Mask and Color Map.
Also you can fix another problems like boarder color with your self 8)

I hope this file will help you my friend

Attachments:
JK_Totem with UVSET.hipnc.zip (215.4 KB)

https://www.youtube.com/c/sadjadrabiee [www.youtube.com]
Rabiee.Sadjad@Gmail.Com
User Avatar
Member
271 posts
Joined: March 2012
Offline
Hi Joker,
I finally got the darn thing to work, so thank you Sorry if I'm being annoying - but this is the first thing I've done in Houdini.
I'm now going to start a new thread to discuss my new problem that I've run into
  • Quick Links