diff --git a/src/Layers/xrRender/Blender_Recorder_StandartBinding.cpp b/src/Layers/xrRender/Blender_Recorder_StandartBinding.cpp index 0842ac37..79a6e9c8 100644 --- a/src/Layers/xrRender/Blender_Recorder_StandartBinding.cpp +++ b/src/Layers/xrRender/Blender_Recorder_StandartBinding.cpp @@ -385,6 +385,44 @@ static class markswitch_color : public R_constant_setup } } markswitch_color; +// Shader 3D Scopes +extern Fvector4 ps_s3ds_param_1; +extern Fvector4 ps_s3ds_param_2; +extern Fvector4 ps_s3ds_param_3; +extern Fvector4 ps_s3ds_param_4; + +static class s3ds_param_1 : public R_constant_setup +{ + virtual void setup(R_constant* C) + { + RCache.set_c(C, ps_s3ds_param_1.x, ps_s3ds_param_1.y, ps_s3ds_param_1.z, ps_s3ds_param_1.w); + } +} s3ds_param_1; + +static class s3ds_param_2 : public R_constant_setup +{ + virtual void setup(R_constant* C) + { + RCache.set_c(C, ps_s3ds_param_2.x, ps_s3ds_param_2.y, ps_s3ds_param_2.z, ps_s3ds_param_2.w); + } +} s3ds_param_2; + +static class s3ds_param_3 : public R_constant_setup +{ + virtual void setup(R_constant* C) + { + RCache.set_c(C, ps_s3ds_param_3.x, ps_s3ds_param_3.y, ps_s3ds_param_3.z, ps_s3ds_param_3.w); + } +} s3ds_param_3; + +static class s3ds_param_4 : public R_constant_setup +{ + virtual void setup(R_constant* C) + { + RCache.set_c(C, ps_s3ds_param_4.x, ps_s3ds_param_4.y, ps_s3ds_param_4.z, ps_s3ds_param_4.w); + } +} s3ds_param_4; + //--DSR-- SilencerOverheat_start static class cl_silencer_glowing : public R_constant_setup { @@ -1205,6 +1243,12 @@ void CBlender_Compile::SetMapping() r_Constant("markswitch_count", &markswitch_count); r_Constant("markswitch_color", &markswitch_color); + // Shader 3D Scopes + r_Constant("s3ds_param_1", &s3ds_param_1); + r_Constant("s3ds_param_2", &s3ds_param_2); + r_Constant("s3ds_param_3", &s3ds_param_3); + r_Constant("s3ds_param_4", &s3ds_param_4); + // crookr r_Constant("fakescope_params1", &binder_fakescope_params); r_Constant("fakescope_params2", &binder_fakescope_ca); diff --git a/src/Layers/xrRender/xrRender_console.cpp b/src/Layers/xrRender/xrRender_console.cpp index 1b035a9c..2b6c07d7 100644 --- a/src/Layers/xrRender/xrRender_console.cpp +++ b/src/Layers/xrRender/xrRender_console.cpp @@ -332,6 +332,12 @@ int ps_markswitch_current = 0; int ps_markswitch_count = 0; Fvector4 ps_markswitch_color = { 0, 0, 0, 0 }; +// Shader 3D Scopes +Fvector4 ps_s3ds_param_1 = { 0, 0, 0, 0 }; +Fvector4 ps_s3ds_param_2 = { 0, 0, 0, 0 }; +Fvector4 ps_s3ds_param_3 = { 0, 0, 0, 0 }; +Fvector4 ps_s3ds_param_4 = { 0, 0, 0, 0 }; + // Screen Space Shaders Stuff float ps_ssfx_hud_hemi = 0.15f; // HUD Hemi Offset @@ -1215,6 +1221,12 @@ void xrRender_initconsole() CMD4(CCC_Integer, "markswitch_current", &ps_markswitch_current, 0, 32); CMD4(CCC_Integer, "markswitch_count", &ps_markswitch_count, 0, 32); CMD4(CCC_Vector4, "markswitch_color", &ps_markswitch_color, Fvector4().set(0.0, 0.0, 0.0, 0.0), Fvector4().set(1.0, 1.0, 1.0, 1.0)); + + // Shader 3D Scopes + CMD4(CCC_Vector4, "s3ds_param_1", &ps_s3ds_param_1, tw2_min, tw2_max); + CMD4(CCC_Vector4, "s3ds_param_2", &ps_s3ds_param_2, tw2_min, tw2_max); + CMD4(CCC_Vector4, "s3ds_param_3", &ps_s3ds_param_3, tw2_min, tw2_max); + CMD4(CCC_Vector4, "s3ds_param_4", &ps_s3ds_param_4, tw2_min, tw2_max); // Screen Space Shaders CMD4(CCC_Float, "ssfx_hud_hemi", &ps_ssfx_hud_hemi, 0.0f, 1.0f);