gloperate icon indicating copy to clipboard operation
gloperate copied to clipboard

Generic function wrapper stage

Open j-o opened this issue 8 years ago • 1 comments

Add a Stage that wraps a given function of the form OutputType(InputType). This would reduce the boilerplate code required to write simple stages with one input and one output (generically named "input" and "output").:

// processing function
GLuint limitMSAA(GLuint numMultisamples);

// Stage declaration
using LimitMSAAStage = FunctionStage<GLuint, GLuint, limitMSAA>;

// Alternative declaration of a creator function with Input/Output type deduction
static const auto limitMSAAStage = stageCreator(limitMSAA);

Could be extended/overloaded for functions with 2, 3, 4 inputs.

(Already have some code for this)

j-o avatar Feb 10 '17 15:02 j-o

A semantically near feature extension would include scripted functions so that the actual functionality can be added, changed, and extended in the pipeline editor.

scheibel avatar Feb 10 '17 16:02 scheibel