Ramp texture
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Ramp texture
Changed Interpolation and Type from number inputs to word selection inputs.
Added a clickable key indicator - click near to select a key
Added a remove key button - it only works on the last key added
Reset/Clear the texture connection when removing a texture
InterpolationS only valid values are "Linear" and "None"
TypeS only valid values are "V Ramp" and "U Ramp"
Limited to 16 color keys
First 8 keys can be textures
- Attachments
-
- Ramp.RsObj
- (117.71 KiB) Downloaded 188 times
Re: Ramp texture
Nice! Now I need to figure out how to use it.
Made a U Ramp and V Ramp D3D Materials
Removed due to update
Made a U Ramp and V Ramp D3D Materials
Removed due to update
Re: Ramp texture
U Ramp
With the RampBitmap/Clickable Bitmap Control, I am getting errors!
If I change to code as follows, I do not get errors.
With the RampBitmap/Clickable Bitmap Control, I am getting errors!
If I change to code as follows, I do not get errors.
Code: Select all
Node.Value("%THIS_NAME%" + "/add new key" , "Position") = "%MOUSE_X%/" + Node.Value("%THIS_NAME%","SizeX");
color = System.CreateDO("Common Data Package/Color Data");
color.SetRed('%COLOR_R%')
color.SetGreen('%COLOR_G%')
color.SetBlue('%COLOR_B%')
Node.Value("%THIS_NAME%" + "/add new key" , "ColorIn") = color
Activity.Run("%THIS_NAME%" + "/add new key")
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Ramp texture
That doesn't work. Error must be from something else.trueBlue wrote: ↑11 Feb 2020, 21:51 U Ramp
With the RampBitmap/Clickable Bitmap Control, I am getting errors!
If I change to code as follows, I do not get errors.Code: Select all
Node.Value("%THIS_NAME%" + "/add new key" , "Position") = "%MOUSE_X%/" + Node.Value("%THIS_NAME%","SizeX"); color = System.CreateDO("Common Data Package/Color Data"); color.SetRed('%COLOR_R%') color.SetGreen('%COLOR_G%') color.SetBlue('%COLOR_B%') Node.Value("%THIS_NAME%" + "/add new key" , "ColorIn") = color Activity.Run("%THIS_NAME%" + "/add new key")
Re: Ramp texture
For me it is mostly Line 335 Type mismatch when scrubbing the CurrentPosition slider.
How about a color picker?
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Ramp texture
I can slide all day long and not get an error. Are you sure there are no other steps to reproduce the error?
Re: Ramp texture
Maybe if you create a ramp below the highest ramp?
If I just create a few ramps, then I can scrub all day long too!
If I take your button script into a JScript and run a syntax check, you'll see why I suggested a change from the previous post.
If I just create a few ramps, then I can scrub all day long too!
If I take your button script into a JScript and run a syntax check, you'll see why I suggested a change from the previous post.
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: Ramp texture
%MOUSE%, %COLOR_R% etc. don't work inside scripts. They only work in the script section of the UI tools.
I copied and pasted your earlier code and it didn't work. That's why I said it doesn't work.
What does it mean to create a ramp below the highest ramp? I'm guessing this is giving you errors?
Re: Ramp texture
Here is the Ramp object with error
- Attachments
-
- Ramp.RsObj
- (616.07 KiB) Downloaded 182 times
- clintonman
- Captain
- Posts: 5430
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact: