![]() |
RenderMan
26.0
|
Multiple methods of RixDisplayServices
require similar parameters:
More...
#include <RixIntegrator.h>
Public Member Functions | |
virtual bool | Splat (RixChannelId id, int iCtxIndex, float const value)=0 |
Accumulates a value into a given display channel for a given path sample. More... | |
virtual bool | Splat (RixChannelId id, int iCtxIndex, RtColorRGB const value)=0 |
The color version of RixDisplayServices::Splat(RixChannelId, int, float) . More... | |
virtual bool | SplatMulti (int nChans, RixChannelId const *ids, int iCtxIndex, float const value)=0 |
The multi-channel version of Splat() , taking a list of channels to accumulate to. More... | |
virtual bool | SplatMulti (int nChans, RixChannelId const *id, int iCtxIndex, RtColorRGB const value)=0 |
The color version of RixDisplayServices::SplatMulti(int, RixChannelId*, int, float) . More... | |
virtual bool | Write (RixChannelId id, int iCtxIndex, float const value)=0 |
Write() is similar to Splat() , except that it overwrites the existing value instead of accumulating. More... | |
virtual bool | Write (RixChannelId id, int iCtxIndex, RtColorRGB const value)=0 |
The color version of RixDisplayServices::Write(int, RixChannelId, float) . More... | |
virtual bool | Write (RixChannelId id, int iCtxIndex, int const value)=0 |
The integer version of RixDisplayServices::Write(int, RixChannelId, float) . More... | |
virtual void | WriteDistance (int const iCtxIndex, float const distance, bool const isVolume=true, RixShadingContext const *sCtx=nullptr)=0 |
Overwrites the existing hit distance and information. More... | |
virtual void | WriteOpacity (RixChannelId id, int iCtxIndex, float const value)=0 |
Overwrites the current opacity value into the sample, which will be pixel-filtered and blended to create the pixel alpha. More... | |
virtual void | WriteOpacity (RixChannelId id, int iCtxIndex, RtColorRGB &value)=0 |
virtual void | SplatOpacity (RixChannelId id, int iCtxIndex, float const opacity)=0 |
Accumulates a given opacity value into the sample, which will be pixel-filtered and blended to create the pixel alpha. More... | |
virtual void | SplatOpacity (RixChannelId id, int iCtxIndex, RtColorRGB &opacity)=0 |
virtual int | AddSample (int iCtxIndex)=0 |
Creates and adds a new sample. More... | |
virtual void | GetDisplayChannels (int *numDisplays, RixDisplayChannel const **displays)=0 |
Gets a list of available display channels. More... | |
virtual void | DiscardIteration (bool redo=false)=0 |
Cancels the results of any calls made to Splat() , SplatMulti() , and Write() during this invocation of the integrator's Integrate() or IntegrateRays() method. More... | |
virtual bool | Read (RixChannelId id, int iCtxIndex, float &value)=0 |
Read() retrieves the current value of an AOV. More... | |
virtual bool | Read (RixChannelId id, int iCtxIndex, RtColorRGB &value)=0 |
The color version of RixDisplayServices::Read(RixChannelId, int, float) . More... | |
virtual bool | Read (RixChannelId id, int iCtxIndex, int &value)=0 |
The integer version of RixDisplayServices::Read(RixChannelId, int, float) . More... | |
Protected Member Functions | |
virtual | ~RixDisplayServices () |
Multiple methods of RixDisplayServices
require similar parameters:
RixDisplayChannel
objects that can be retrieved from the RixIntegratorEnvironment
interface. This list can also be retrived by calling the method GetDisplayChannels()
.RixShadingContext
, this should be sCtx.integratorCtxIndex[i]
Most methods have two versions, differing only by the type of the provided value: float or color.
|
inlineprotectedvirtual |
|
pure virtual |
Creates and adds a new sample.
This new sample will be located at the same screen position as the given sample. However, it may be assigned different values and hit distances. Use this to produce better deep images from transparency and volumes. The returned value can be used as the iCtxIndex
for the new sample in other calls or to add further samples.
Note: if there is anything in front of this new sample, the integrator is still responsible for attenuating any color and opacity splatted into it.
[in] | iCtxIndex | Integrator context index of the original sample. |
|
pure virtual |
Cancels the results of any calls made to Splat()
, SplatMulti()
, and Write()
during this invocation of the integrator's Integrate()
or IntegrateRays()
method.
This may be useful if an integrator produces poor estimates during a warmup period.
[in] | redo | If true, the renderer will retry the current integration with the same inputs. Optional. |
|
pure virtual |
Gets a list of available display channels.
These are normally provided to the integrator via the integration environment for it to inspect during startup. However, we provide access here during runtime for more dynamic applications such as patterns and bxdfs which would like to do "writeaov()"-like things.
[out] | numDisplays | Number of displays returned. |
[out] | displays | List of displays. Array of size numDisplays . |
|
pure virtual |
Read()
retrieves the current value of an AOV.
There is no guarantee of access order within a shader network. It is up to the user to manage their shader networks to avoid plugins conflicting via multiple writes or having read/write order dependencies. There is no guarantee on the ordering of reads/writes withing a pattern graph. The order between different rendering stages such as pattern evaluation, bxdf evaluation and lighting will be integrator implementation dependent.
[in] | id | Id of the channel to read from.. |
[in] | iCtxIndex | Integrator context index. |
[in] | value | Reference to the location to place the read value.. |
|
pure virtual |
The color version of RixDisplayServices::Read(RixChannelId, int, float)
.
|
pure virtual |
The integer version of RixDisplayServices::Read(RixChannelId, int, float)
.
|
pure virtual |
Accumulates a value into a given display channel for a given path sample.
This is accumulative; it may be called at each vertex along a light path to sum radiance thruput, for example.
Note: RixPattern
plug-ins should only write to display services during scatter queries. Users can check the shading context shading mode for k_RixSCScatterQuery
.
[in] | id | Id of the channel to write to. |
[in] | iCtxIndex | Integrator context index. |
[in] | value | The value to be splat. |
|
pure virtual |
The color version of RixDisplayServices::Splat(RixChannelId, int, float)
.
|
pure virtual |
The multi-channel version of Splat()
, taking a list of channels to accumulate to.
The same value will be accumulated into each channel.
nChans | Number of channels ids. | |
ids | Ids of the channels to write to. | |
[in] | iCtxIndex | Integrator context index. |
[in] | value | The value to be splat. |
|
pure virtual |
The color version of RixDisplayServices::SplatMulti(int, RixChannelId*, int, float)
.
|
pure virtual |
Accumulates a given opacity value into the sample, which will be pixel-filtered and blended to create the pixel alpha.
[in] | id | Id of the channel to write to. |
[in] | iCtxIndex | Integrator context index. |
[in] | opacity | The value to be written. |
|
pure virtual |
|
pure virtual |
Write()
is similar to Splat()
, except that it overwrites the existing value instead of accumulating.
This can be useful for AOVs that do not sum linearly.
The last write into the given channel will be the one that gets filtered into the pixel for this particular sample. It is up to the user to manage their shader networks to avoid plugins fighting over the value.
[in] | id | Id of the channel to write to. |
[in] | iCtxIndex | Integrator context index. |
[in] | value | The value to be written. |
|
pure virtual |
The color version of RixDisplayServices::Write(int, RixChannelId, float)
.
|
pure virtual |
The integer version of RixDisplayServices::Write(int, RixChannelId, float)
.
|
pure virtual |
Overwrites the existing hit distance and information.
When using deep outputs, this must be called during volume integration for them to be correct.
Only one update can be saved per sample, so only the last call to WriteDistance()
for a given sample has an effect. Use AddSample()
with this if you'd like to have distinct samples at different distances.
[in] | iCtxIndex | Integrator context index. |
[in] | distance | This is not the distance to the outer envelope, but to a volume scattering or absorption event or to a non-volume object intersecting the volume. |
[in] | isVolume | Indicates if writing distance for a volume scattering event or not. |
[in] | sCtx | The shading context associated with the point for which we are writing the distance. This is necessary for RixSampleFilter::GetAttribute() to work properly. |
Referenced by RixIntegrator::IntegrateRays().
|
pure virtual |
Overwrites the current opacity value into the sample, which will be pixel-filtered and blended to create the pixel alpha.
[in] | id | Id of the channel to write to. |
[in] | iCtxIndex | Integrator context index. |
[in] | value | The value to be written. |
|
pure virtual |