2016-03-25 18:44:18 +01:00
|
|
|
// license:BSD-3-Clause
|
|
|
|
// copyright-holders:ImJezze
|
|
|
|
//============================================================
|
|
|
|
//
|
|
|
|
// distortion.json: Output distortion shader for CRT
|
|
|
|
// simulation.
|
|
|
|
//
|
|
|
|
//============================================================
|
2016-03-15 05:17:38 +01:00
|
|
|
{
|
|
|
|
"blend": {
|
2016-04-21 07:52:29 +02:00
|
|
|
"equation": "add",
|
|
|
|
"srcColor": "srcalpha",
|
|
|
|
"dstColor": "1-srcalpha",
|
|
|
|
"srcAlpha": "srcalpha",
|
|
|
|
"dstAlpha": "1-srcalpha"
|
2016-03-15 05:17:38 +01:00
|
|
|
},
|
|
|
|
"depth": {
|
2016-04-21 07:52:29 +02:00
|
|
|
"function": "always"
|
2016-03-15 05:17:38 +01:00
|
|
|
},
|
|
|
|
"cull": { "mode": "none" },
|
|
|
|
"write": {
|
2016-04-21 07:52:29 +02:00
|
|
|
"rgb": true,
|
|
|
|
"alpha": true
|
2016-03-15 05:17:38 +01:00
|
|
|
},
|
2016-04-14 17:22:08 +02:00
|
|
|
"vertex": "chains/hlsl/vs_distortion",
|
|
|
|
"fragment": "chains/hlsl/fs_distortion",
|
2016-03-15 05:17:38 +01:00
|
|
|
"uniforms": [
|
2016-04-21 07:52:29 +02:00
|
|
|
{ "name": "s_tex", "type": "int", "values": [ 0.0 ] },
|
|
|
|
{ "name": "u_swap_xy", "type": "vec4", "values": [ 0.0, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_screen_dims", "type": "vec4", "values": [ 1.0, 1.0, 0.0, 0.0 ] },
|
2016-04-19 21:18:16 +02:00
|
|
|
{ "name": "u_target_dims", "type": "vec4", "values": [ 1.0, 1.0, 0.0, 0.0 ] },
|
2016-04-21 07:52:29 +02:00
|
|
|
{ "name": "u_quad_dims", "type": "vec4", "values": [ 1.0, 1.0, 0.0, 0.0 ] },
|
2016-04-19 21:18:16 +02:00
|
|
|
{ "name": "u_distortion", "type": "vec4", "values": [ 0.20, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_cubic_distortion", "type": "vec4", "values": [ 0.20, 0.0, 0.0, 0.0 ] },
|
2016-04-21 07:52:29 +02:00
|
|
|
{ "name": "u_distort_corner", "type": "vec4", "values": [ 0.20, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_round_corner", "type": "vec4", "values": [ 0.20, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_smooth_border", "type": "vec4", "values": [ 0.05, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_vignetting", "type": "vec4", "values": [ 0.20, 0.0, 0.0, 0.0 ] },
|
|
|
|
{ "name": "u_reflection", "type": "vec4", "values": [ 0.30, 0.0, 0.0, 0.0 ] }
|
2016-03-15 05:17:38 +01:00
|
|
|
]
|
|
|
|
}
|