Function addMiss

Synopsis

#include <Source/Falcor/Raytracing/RtProgram/RtProgram.h>

Desc & addMiss(uint32_t missIndex, const std::string &miss)

Description

No description yet.

Source

Lines 63-81 in Source/Falcor/Raytracing/RtProgram/RtProgram.cpp. Line 74 in Source/Falcor/Raytracing/RtProgram/RtProgram.h.

RtProgram::Desc& RtProgram::Desc::addMiss(uint32_t missIndex, const std::string& miss)
{
    if(missIndex >= mMissEntryPoints.size())
    {
        mMissEntryPoints.resize(missIndex+1);
    }
    else if(mMissEntryPoints[missIndex].groupIndex >= 0)
    {
        logError("already have a miss shader at that index");
    }
    auto entryPointIndex = int32_t(mBaseDesc.mEntryPoints.size());
    mBaseDesc.beginEntryPointGroup();
    mBaseDesc.entryPoint(ShaderType::Miss, miss);
    DescExtra::GroupInfo info = { mBaseDesc.mActiveGroup };
    mMissEntryPoints[missIndex] = info;
    return *this;
}





Add Discussion as Guest

Log in