https://github.com/shader-slang/slang
Raw File
Tip revision: 768e62f6c7541439e2edc18dad5fb3846d2e05f9 authored by Yong He on 10 October 2022, 22:59:45 UTC
Support multi-level break + single-return conversion + general inline. (#2436)
Tip revision: 768e62f
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