point vop ramp doesn't output colors

   5661   6   0
User Avatar
Member
1012 posts
Joined: April 2017
Offline
Hi!

I've got a line that I connected to a point vop. In the point vop, I'm connecting the “ptnum” to a fit range so I get a gradient from black to white. I wanted the colors from green to red instead by using a “ramp parameter” but when I connect it to Cd, it's all black.

Any help?

Thanks.

-Olivier

Attachments:
ramp_problem.JPG (82.5 KB)

User Avatar
Member
1747 posts
Joined: May 2006
Offline
I thought you might have to cast ptnum to a float, but works fine here.

Attached a hip if you want to compare against your setup.

For the record, that method won't work so well if you have multiple curves. A more reliable method is to generate uvs, either with a uvtextures op in ‘rows and columns’ mode, or a resample sop with everything turned off, apart from ‘curve u attribute’.

They're in the hip too.

-matt

Attachments:
ptnum_fit_ramp.JPG (45.8 KB)
ptnum_fit_ramp_vop.hip (121.3 KB)

http://www.tokeru.com/cgwiki [www.tokeru.com]
https://www.patreon.com/mattestela [www.patreon.com]
User Avatar
Member
1012 posts
Joined: April 2017
Offline
Hi mestela!

Thanks for the detailed example! As a noob, I really appreciate it!

I'm a little confused. On the example where you tried my approach, your ramp contains a gradient from black to white and the viewport result is green to red….?! I also copied your ramp into my scene to replace mine and it's still black…

The multiple curve thing is good to keep in mind!

Thanks!
User Avatar
Member
1012 posts
Joined: April 2017
Offline
Hi! Me again…

I've create the most basic setup to test the ramp parameter in a point vop and it's not working. Any chance somebody would take the time to open it and tell me what I'm doing wrong?

Thanks!

-Olivier

Attachments:
PointVop_rampPara_problem.JPG (121.8 KB)
vop_rampPara_problem.hipnc (77.3 KB)

User Avatar
Member
433 posts
Joined: Feb. 2012
Offline
look outside of your vop, the ramp parameter is promoted automatically make the color changes there.
User Avatar
Member
1012 posts
Joined: April 2017
Offline
Thanks sepu, I just found out.

…Now I'm still confused. Why is there a ramp you can play with in the “ramp parameter” inside the vop if it does nothing?!

-Olivier
User Avatar
Member
8613 posts
Joined: July 2007
Offline
that one sets the default ramp value, exactly like other parameters have default value on the VOP directly
if you look closely even the name says Ramp Default
Edited by tamte - Feb. 13, 2018 21:13:46
Tomas Slancik
FX Supervisor
Method Studios, NY
  • Quick Links