class TIoMapResolver

Defined at line 806 of file ../../third_party/glslang/src/glslang/Public/ShaderLang.h

Allows to customize the binding layout after linking.

All used uniform variables will invoke at least validateBinding.

If validateBinding returned true then the other resolveBinding,

resolveSet, and resolveLocation are invoked to resolve the binding

and descriptor set index respectively.

Invocations happen in a particular order:

1) all shader inputs

2) all shader outputs

3) all uniforms with binding and set already defined

4) all uniforms with binding but no set defined

5) all uniforms with set but no binding defined

6) all uniforms with no binding and no set defined

mapIO will use this resolver in two phases. The first

phase is a notification phase, calling the corresponging

notifiy callbacks, this phase ends with a call to endNotifications.

Phase two starts directly after the call to endNotifications

and calls all other callbacks to validate and to get the

bindings, sets, locations, component and color indices.

NOTE: that still limit checks are applied to bindings and sets

and may result in an error.

Public Methods

bool validateBinding (EShLanguage stage, TVarEntryInfo & ent)

Should return true if the resulting/current binding would be okay.

Basic idea is to do aliasing binding checks with this.

int resolveBinding (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current binding should be overridden.

Return -1 if the current binding (including no binding) should be kept.

int resolveSet (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current set should be overridden.

Return -1 if the current set (including no set) should be kept.

int resolveUniformLocation (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current location should be overridden.

Return -1 if the current location (including no location) should be kept.

bool validateInOut (EShLanguage stage, TVarEntryInfo & ent)

Should return true if the resulting/current setup would be okay.

Basic idea is to do aliasing checks and reject invalid semantic names.

int resolveInOutLocation (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current location should be overridden.

Return -1 if the current location (including no location) should be kept.

int resolveInOutComponent (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current component index should be overridden.

Return -1 if the current component index (including no index) should be kept.

int resolveInOutIndex (EShLanguage stage, TVarEntryInfo & ent)

Should return a value >= 0 if the current color index should be overridden.

Return -1 if the current color index (including no index) should be kept.

void notifyBinding (EShLanguage stage, TVarEntryInfo & ent)

Notification of a uniform variable

void notifyInOut (EShLanguage stage, TVarEntryInfo & ent)

Notification of a in or out variable

void beginNotifications (EShLanguage stage)

Called by mapIO when it starts its notify pass for the given stage

void endNotifications (EShLanguage stage)

Called by mapIO when it has finished the notify pass

void beginResolve (EShLanguage stage)

Called by mipIO when it starts its resolve pass for the given stage

void endResolve (EShLanguage stage)

Called by mapIO when it has finished the resolve pass

void beginCollect (EShLanguage stage)

Called by mapIO when it starts its symbol collect for teh given stage

void endCollect (EShLanguage stage)

Called by mapIO when it has finished the symbol collect

void reserverStorageSlot (TVarEntryInfo & ent, TInfoSink & infoSink)

Called by TSlotCollector to resolve storage locations or bindings

void reserverResourceSlot (TVarEntryInfo & ent, TInfoSink & infoSink)

Called by TSlotCollector to resolve resource locations or bindings

void addStage (EShLanguage stage, TIntermediate & stageIntermediate)

Called by mapIO.addStage to set shader stage mask to mark a stage be added to this pipeline

void ~TIoMapResolver ()

Defined at line 809 of file ../../third_party/glslang/src/glslang/Public/ShaderLang.h