mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-12-23 08:50:57 +01:00
glasm: Implement gl_Layer stores
This commit is contained in:
parent
89e341d56a
commit
e565eb361a
1 changed files with 7 additions and 0 deletions
|
@ -134,6 +134,13 @@ void EmitSetAttribute(EmitContext& ctx, IR::Attribute attr, ScalarF32 value,
|
||||||
ctx.Add("MOV.F result.clip[{}].x,{};", index, value);
|
ctx.Add("MOV.F result.clip[{}].x,{};", index, value);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case IR::Attribute::Layer:
|
||||||
|
if (ctx.stage == Stage::Geometry || ctx.profile.support_viewport_index_layer_non_geometry) {
|
||||||
|
ctx.Add("MOV.F result.layer.x,{};", value);
|
||||||
|
} else {
|
||||||
|
// LOG_WARNING
|
||||||
|
}
|
||||||
|
break;
|
||||||
case IR::Attribute::ViewportIndex:
|
case IR::Attribute::ViewportIndex:
|
||||||
if (ctx.stage == Stage::Geometry || ctx.profile.support_viewport_index_layer_non_geometry) {
|
if (ctx.stage == Stage::Geometry || ctx.profile.support_viewport_index_layer_non_geometry) {
|
||||||
ctx.Add("MOV.F result.viewport.x,{};", value);
|
ctx.Add("MOV.F result.viewport.x,{};", value);
|
||||||
|
|
Loading…
Reference in a new issue