Ramp

 

These shaders provide a gradient ramp for RGB output and a spline ramp for float output. As points are added, edited or deleted on the curve or gradient, corresponding inputs are created dynamically for the position, color (or value) and interpolation. These inputs are then available to link upstream shaders so that noises and textures can be plugged in. Effects can be created by using a ramp_float shader to drive the displacement and a ramp_rgb shader to drive the color. Internally, the shaders use lazy caching of the parameters of the curves and give intermediate results. Therefore both ramp shaders are faster when not textured or when only some of the parameters are textured. 

An example of a ramp shader used to create a fake fresnel effect can be downloaded here.

 

Type

Allows you to select from built-in ramp modes (like u, v, circular, etc.) or a custom mode where the mapping is controlled by the input parameter.

Time computes the input based on the current time and the camera's start and end shutter interval. In the images below, the motion-blurred planes have a flat shader that changes colors through the shutter time.

Input

Allows the value/color of an incoming shader to be remapped.

UV Set

UV set to use for input coordinates. A string with the name of the UV set to use to sample the image. By default, when the uvset parameter is empty, the primary UV set in the polymesh will be used. Example: If you have created a UV set in a polymesh node called "UVset2", then you can use it by setting the uvset parameter to "UVset2".

Use Implicit UVs

Use the implicit (barycentric) per-primitive coordinates instead of the UVs. This is mostly useful with curves where it gives coordinates varying along each hair strand.

Wrap UVs

Wraps the input UV coordinates between [0,1] so that it applies to different UV ranges or UDIMs.

Ramp

Gradient (ramp_rgb) and spline (ramp_float) controls to define control points. Colors can be added by clicking on the desired position on the ramp.

You can add new control points to the spline by pressing CTRL + click on the desired position. The ramp can be expanded by clicking on the small down arrow.

Interpolation

Integer array of interpolation types for each curve point. The available types are:

This is how C4D interpolation is translated:

Gradient Control

C4D interpolationArnold interpolation
Smooth KnotCatmull-rom
Cubic KnotMonotone cubic
Cubic BiasMonotone cubic
Linear KnotLinear
LinearLinear
NoneConstant
Exponent UpMonotone cubic
Exponent DownMonotone cubic

Spline Control

C4D interpolationArnold interpolation
SplineCatmull-rom
CubicMonotone cubic
LinearLinear

Sampling

C4D's gradient and spline controls offer more interpolation methods and different options than supported in the ramp shaders. If enabled, color and curve values will be sampled, and Catmull-rom interpolation will be used in the shaders resulting in a closer look defined by the controls.

Sample Rate

The number of samples taken when sampling is enabled. 

Load Textures From Folder

The ramp RGB shader can load images from a folder to each color (similar to the MoGraph Multi Shader's 'Add from Folder' feature). Images are loaded in alphanumerical order. If there are more textures in the folder than the color inputs defined on the ramp shader, then the plugin asks to create an input for all textures or load textures only for the available colors.

Linking

The ramp shader node allows you to link shaders to different components of the gradient or spline giving maximum flexibility, e.g. connect a noise shader to the first color index, etc. Components are listed in the input port menu of the ramp shader. A number of available components defined by the gradient or spline control.

 

 

  • No labels