https://github.com/shader-slang/slang
Raw File
Tip revision: e59516fa8c3a16eb7b99a928c5b85b97bf44fd72 authored by Yong He on 01 February 2022, 00:26:03 UTC
Revise entrypoint renaming interface. (#2113)
Tip revision: e59516f
slang-ir-entry-point-uniforms.h
// slang-ir-entry-point-uniform.h
#pragma once

#include "slang-compiler.h"

namespace Slang
{
struct IRModule;

struct CollectEntryPointUniformParamsOptions
{
    // TODO(JS): Not sure if it makes sense to initialize to true or false. Go with false as
    // seems to fit usage.
    bool alwaysCreateCollectedParam = false;
};

    /// Collect entry point uniform parameters into a wrapper `struct` and/or buffer
void collectEntryPointUniformParams(
    IRModule*                                       module,
    CollectEntryPointUniformParamsOptions const&    options);

    /// Move any uniform parameters of entry points to the global scope instead.
void moveEntryPointUniformParamsToGlobalScope(
    IRModule*   module);

}
back to top