mirror of
https://github.com/cemu-project/cemu_graphic_packs.git
synced 2024-11-22 17:49:17 +01:00
[XCX] Cleanup - Bloom and brightness tweaks
This commit is contained in:
parent
5f6725df66
commit
2a62d54fee
@ -1,17 +1,10 @@
|
||||
<?php
|
||||
include 'Source/functions.php';
|
||||
$fullWidth = $argv[1];
|
||||
$fullHeight = $argv[2];
|
||||
$scaleFactorX = always_decimal_format($fullWidth / 1280.0);
|
||||
$scaleFactorY = always_decimal_format($fullHeight / 720.0);
|
||||
?>
|
||||
|
||||
#version 420
|
||||
#extension GL_ARB_texture_gather : enable
|
||||
// shader 1bef7019c97eb2b1
|
||||
//Vertlica line glare (anamorphic lens )
|
||||
// To-do - As long as brigntess fix is needed, this will always be dodgy ..
|
||||
const float resScale = <?=$scaleFactorX?>;
|
||||
// To-do - As long as brigntess fix is needed, this is disabled.
|
||||
const float resScale = 4.0;
|
||||
//const float resScale = 3.0;
|
||||
uniform ivec4 uf_remappedPS[2];
|
||||
layout(binding = 0) uniform sampler2D textureUnitPS0;// Tex0 addr 0xf4f51000 res 80x46x1 dim 1 tm: 4 format 0816 compSel: 0 1 2 5 mipView: 0x0 (num 0x1) sliceView: 0x0 (num 0x1) Sampler0 ClampX/Y/Z: 6 6 6 border: 0
|
||||
@ -1307,5 +1300,5 @@ PS1f = R29f.x;
|
||||
// 34
|
||||
R29f.z = min(R2f.x, intBitsToFloat(uf_remappedPS[1].w));
|
||||
// export
|
||||
passPixelColor0 = vec4(R29f.x, R29f.y, R29f.z, R29f.w);
|
||||
//passPixelColor0 = vec4(R29f.x, R29f.y, R29f.z, R29f.w);
|
||||
}
|
||||
|
499
Source/XenobladeX/430ac3a85ece61af_0000000000000079_ps.txt
Normal file
499
Source/XenobladeX/430ac3a85ece61af_0000000000000079_ps.txt
Normal file
@ -0,0 +1,499 @@
|
||||
<?php
|
||||
include 'Source/functions.php';
|
||||
$fullWidth = $argv[1];
|
||||
$fullHeight = $argv[2];
|
||||
$scaleFactorX = always_decimal_format($fullWidth / 1280.0);
|
||||
$scaleFactorY = always_decimal_format($fullHeight / 720.0);
|
||||
?>
|
||||
|
||||
#version 420
|
||||
#extension GL_ARB_texture_gather : enable
|
||||
// shader 430ac3a85ece61af // bloom sampling scale
|
||||
const float resScale = <?=$scaleFactorX?>;
|
||||
//const float resScale = 4.0;
|
||||
uniform ivec4 uf_remappedPS[2];
|
||||
layout(binding = 0) uniform sampler2D textureUnitPS0;// Tex0 addr 0xf4e12000 res 256x144x1 dim 1 tm: 4 format 0816 compSel: 0 1 2 5 mipView: 0x0 (num 0x1) sliceView: 0x0 (num 0x1) Sampler0 ClampX/Y/Z: 6 6 6 border: 0
|
||||
layout(location = 0) in vec4 passParameterSem0;
|
||||
layout(location = 0) out vec4 passPixelColor0;
|
||||
uniform vec2 uf_fragCoordScale;
|
||||
int clampFI32(int v)
|
||||
{
|
||||
if( v == 0x7FFFFFFF )
|
||||
return floatBitsToInt(1.0);
|
||||
else if( v == 0xFFFFFFFF )
|
||||
return floatBitsToInt(0.0);
|
||||
return floatBitsToInt(clamp(intBitsToFloat(v), 0.0, 1.0));
|
||||
}
|
||||
float mul_nonIEEE(float a, float b){ return min(a*b,min(abs(a)*3.40282347E+38F,abs(b)*3.40282347E+38F)); }
|
||||
void main()
|
||||
{
|
||||
vec4 R0f = vec4(0.0);
|
||||
vec4 R1f = vec4(0.0);
|
||||
vec4 R2f = vec4(0.0);
|
||||
vec4 R3f = vec4(0.0);
|
||||
vec4 R4f = vec4(0.0);
|
||||
vec4 R5f = vec4(0.0);
|
||||
vec4 R6f = vec4(0.0);
|
||||
vec4 R7f = vec4(0.0);
|
||||
vec4 R8f = vec4(0.0);
|
||||
vec4 R9f = vec4(0.0);
|
||||
vec4 R10f = vec4(0.0);
|
||||
vec4 R123f = vec4(0.0);
|
||||
vec4 R127f = vec4(0.0);
|
||||
float backupReg0f, backupReg1f, backupReg2f, backupReg3f, backupReg4f;
|
||||
vec4 PV0f = vec4(0.0), PV1f = vec4(0.0);
|
||||
float PS0f = 0.0, PS1f = 0.0;
|
||||
vec4 tempf = vec4(0.0);
|
||||
float tempResultf;
|
||||
int tempResulti;
|
||||
ivec4 ARi = ivec4(0);
|
||||
bool predResult = true;
|
||||
vec3 cubeMapSTM;
|
||||
int cubeMapFaceId;
|
||||
R0f = passParameterSem0;
|
||||
// 0
|
||||
backupReg0f = R0f.y;
|
||||
backupReg1f = R0f.x;
|
||||
R0f.x = intBitsToFloat(uf_remappedPS[0].x);
|
||||
PV0f.y = backupReg0f + -(intBitsToFloat(uf_remappedPS[0].y)/ resScale);
|
||||
PV0f.z = backupReg1f + -(intBitsToFloat(uf_remappedPS[0].x)/ resScale);
|
||||
R0f.w = intBitsToFloat(uf_remappedPS[0].y);
|
||||
R1f.w = intBitsToFloat(uf_remappedPS[1].x) * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS0f = R1f.w;
|
||||
// 1
|
||||
R10f.x = PV0f.z * intBitsToFloat(0x3d000000);
|
||||
PV1f.x = R10f.x;
|
||||
R2f.z = PS0f * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.z = R2f.z;
|
||||
R5f.w = PV0f.y * intBitsToFloat(0x3d000000);
|
||||
PV1f.w = R5f.w;
|
||||
// 2
|
||||
R1f.x = PV1f.x + intBitsToFloat(uf_remappedPS[0].x)/resScale;
|
||||
PV0f.x = R1f.x;
|
||||
R1f.y = PV1f.w + intBitsToFloat(uf_remappedPS[0].y) / resScale;
|
||||
PV0f.y = R1f.y;
|
||||
R2f.w = PV1f.z * intBitsToFloat(uf_remappedPS[1].y) ;
|
||||
PV0f.w = R2f.w;
|
||||
// 3
|
||||
R2f.x = R10f.x + PV0f.x;
|
||||
PV1f.x = R2f.x;
|
||||
R2f.y = R5f.w + PV0f.y;
|
||||
PV1f.y = R2f.y;
|
||||
R3f.w = PV0f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.w = R3f.w;
|
||||
// 4
|
||||
R3f.x = R10f.x + PV1f.x;
|
||||
R3f.y = R5f.w + PV1f.y;
|
||||
R4f.w = PV1f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R0f.xyz = (texture(textureUnitPS0, R0f.xw).xyz);
|
||||
R1f.xyz = (texture(textureUnitPS0, R1f.xy).xyz);
|
||||
R4f.xyz = (texture(textureUnitPS0, R2f.xy).xyz);
|
||||
R5f.xyz = (texture(textureUnitPS0, R3f.xy).xyz);
|
||||
// 0
|
||||
backupReg0f = R0f.y;
|
||||
R123f.x = (R0f.z * intBitsToFloat(uf_remappedPS[1].x) + 0.0);
|
||||
PV0f.x = R123f.x;
|
||||
R0f.y = R5f.w + R3f.y;
|
||||
PV0f.y = R0f.y;
|
||||
R123f.z = (R0f.x * intBitsToFloat(uf_remappedPS[1].x) + 0.0);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (backupReg0f * intBitsToFloat(uf_remappedPS[1].x) + 0.0);
|
||||
PV0f.w = R123f.w;
|
||||
R0f.x = R10f.x + R3f.x;
|
||||
PS0f = R0f.x;
|
||||
// 1
|
||||
backupReg0f = R1f.z;
|
||||
R123f.x = (R1f.w * R1f.y + PV0f.w);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R1f.w * R1f.x + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R1f.z = R10f.x + PS0f;
|
||||
PV1f.z = R1f.z;
|
||||
R123f.w = (R1f.w * backupReg0f + PV0f.x);
|
||||
PV1f.w = R123f.w;
|
||||
R1f.y = R5f.w + PV0f.y;
|
||||
PS1f = R1f.y;
|
||||
// 2
|
||||
backupReg0f = R4f.x;
|
||||
R4f.x = R10f.x + PV1f.z;
|
||||
PV0f.x = R4f.x;
|
||||
R123f.y = (R2f.z * R4f.y + PV1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R2f.z * R4f.z + PV1f.w);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R2f.z * backupReg0f + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R4f.y = R5f.w + PS1f;
|
||||
PS0f = R4f.y;
|
||||
// 3
|
||||
backupReg0f = R5f.x;
|
||||
backupReg1f = R5f.z;
|
||||
backupReg2f = R2f.w;
|
||||
backupReg3f = R5f.y;
|
||||
R5f.x = (R2f.w * backupReg0f + PV0f.w);
|
||||
R5f.y = R4f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.y = R5f.y;
|
||||
R5f.z = (R2f.w * backupReg1f + PV0f.z);
|
||||
R2f.w = (backupReg2f * backupReg3f + PV0f.y);
|
||||
R3f.x = R10f.x + PV0f.x;
|
||||
PS1f = R3f.x;
|
||||
// 4
|
||||
R6f.x = R10f.x + PS1f;
|
||||
R3f.y = R5f.w + R4f.y;
|
||||
R1f.w = PV1f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R0f.xyz = (texture(textureUnitPS0, R0f.xy).xyz);
|
||||
R1f.xyz = (texture(textureUnitPS0, R1f.zy).xyz);
|
||||
R4f.xyz = (texture(textureUnitPS0, R4f.xy).xyz);
|
||||
R2f.xyz = (texture(textureUnitPS0, R3f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R3f.w * R0f.y + R2f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R123f.y = (R3f.w * R0f.x + R5f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R3f.w * R0f.z + R5f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R6f.w = R5f.w + R3f.y;
|
||||
// 1
|
||||
R0f.x = R1f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.x = R0f.x;
|
||||
R123f.y = (R4f.w * R1f.z + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R4f.w * R1f.y + PV0f.x);
|
||||
PV1f.z = R123f.z;
|
||||
R123f.w = (R4f.w * R1f.x + PV0f.y);
|
||||
PV1f.w = R123f.w;
|
||||
R1f.x = R10f.x + R6f.x;
|
||||
PS1f = R1f.x;
|
||||
// 2
|
||||
R123f.x = (R5f.y * R4f.x + PV1f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R1f.y = R5f.w + R6f.w;
|
||||
PV0f.y = R1f.y;
|
||||
R123f.z = (R5f.y * R4f.y + PV1f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R5f.y * R4f.z + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R4f.w = PV1f.x * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS0f = R4f.w;
|
||||
// 3
|
||||
backupReg0f = R2f.x;
|
||||
R2f.x = (R1f.w * R2f.z + PV0f.w);
|
||||
R4f.y = (R1f.w * R2f.y + PV0f.z);
|
||||
R2f.z = (R1f.w * backupReg0f + PV0f.x);
|
||||
R2f.w = R10f.x + R1f.x;
|
||||
PV1f.w = R2f.w;
|
||||
R2f.y = R5f.w + PV0f.y;
|
||||
PS1f = R2f.y;
|
||||
// 4
|
||||
R5f.x = R10f.x + PV1f.w;
|
||||
R5f.y = R5f.w + PS1f;
|
||||
R4f.z = R4f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R6f.xyz = (texture(textureUnitPS0, R6f.xw).xyz);
|
||||
R1f.xyz = (texture(textureUnitPS0, R1f.xy).xyz);
|
||||
R3f.xyz = (texture(textureUnitPS0, R2f.wy).xyz);
|
||||
R7f.xyz = (texture(textureUnitPS0, R5f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R0f.x * R6f.z + R2f.x);
|
||||
PV0f.x = R123f.x;
|
||||
R127f.y = R4f.z * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.y = R127f.y;
|
||||
R123f.z = (R0f.x * R6f.x + R2f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R0f.x * R6f.y + R4f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R2f.y = R5f.w + R5f.y;
|
||||
PS0f = R2f.y;
|
||||
// 1
|
||||
R123f.x = (R4f.w * R1f.y + PV0f.w);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R4f.w * R1f.x + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R2f.z = R10f.x + R5f.x;
|
||||
PV1f.z = R2f.z;
|
||||
R123f.w = (R4f.w * R1f.z + PV0f.x);
|
||||
PV1f.w = R123f.w;
|
||||
R2f.w = PV0f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS1f = R2f.w;
|
||||
// 2
|
||||
backupReg0f = R3f.x;
|
||||
R3f.x = R10f.x + PV1f.z;
|
||||
PV0f.x = R3f.x;
|
||||
R123f.y = (R4f.z * R3f.y + PV1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R4f.z * R3f.z + PV1f.w);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R4f.z * backupReg0f + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R3f.y = R5f.w + R2f.y;
|
||||
PS0f = R3f.y;
|
||||
// 3
|
||||
backupReg0f = R7f.z;
|
||||
R1f.x = (R127f.y * R7f.x + PV0f.w);
|
||||
R1f.y = R2f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.y = R1f.y;
|
||||
R7f.z = (R127f.y * backupReg0f + PV0f.z);
|
||||
R4f.w = (R127f.y * R7f.y + PV0f.y);
|
||||
R7f.x = R10f.x + PV0f.x;
|
||||
PS1f = R7f.x;
|
||||
// 4
|
||||
R5f.x = R10f.x + PS1f;
|
||||
PV0f.x = R5f.x;
|
||||
R7f.y = R5f.w + R3f.y;
|
||||
PV0f.y = R7f.y;
|
||||
R6f.w = PV1f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.w = R6f.w;
|
||||
// 5
|
||||
R8f.x = R10f.x + PV0f.x;
|
||||
R5f.y = R5f.w + PV0f.y;
|
||||
R1f.w = PV0f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R2f.xyz = (texture(textureUnitPS0, R2f.zy).xyz);
|
||||
R3f.xyz = (texture(textureUnitPS0, R3f.xy).xyz);
|
||||
R4f.xyz = (texture(textureUnitPS0, R7f.xy).xyz);
|
||||
R0f.xyz = (texture(textureUnitPS0, R5f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R2f.w * R2f.y + R4f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R123f.y = (R2f.w * R2f.x + R1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R2f.w * R2f.z + R7f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R8f.w = R5f.w + R5f.y;
|
||||
// 1
|
||||
backupReg0f = R3f.x;
|
||||
R3f.x = R1f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.x = R3f.x;
|
||||
R123f.y = (R1f.y * R3f.z + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R1f.y * R3f.y + PV0f.x);
|
||||
PV1f.z = R123f.z;
|
||||
R123f.w = (R1f.y * backupReg0f + PV0f.y);
|
||||
PV1f.w = R123f.w;
|
||||
R1f.x = R10f.x + R8f.x;
|
||||
PS1f = R1f.x;
|
||||
// 2
|
||||
R123f.x = (R6f.w * R4f.x + PV1f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R1f.y = R5f.w + R8f.w;
|
||||
PV0f.y = R1f.y;
|
||||
R123f.z = (R6f.w * R4f.y + PV1f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R6f.w * R4f.z + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R6f.w = PV1f.x * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS0f = R6f.w;
|
||||
// 3
|
||||
backupReg0f = R0f.x;
|
||||
R0f.x = (R1f.w * R0f.z + PV0f.w);
|
||||
R4f.y = (R1f.w * R0f.y + PV0f.z);
|
||||
R0f.z = (R1f.w * backupReg0f + PV0f.x);
|
||||
R0f.w = R10f.x + R1f.x;
|
||||
PV1f.w = R0f.w;
|
||||
R0f.y = R5f.w + PV0f.y;
|
||||
PS1f = R0f.y;
|
||||
// 4
|
||||
R2f.x = R10f.x + PV1f.w;
|
||||
R2f.y = R5f.w + PS1f;
|
||||
R4f.z = R6f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R8f.xyz = (texture(textureUnitPS0, R8f.xw).xyz);
|
||||
R1f.xyz = (texture(textureUnitPS0, R1f.xy).xyz);
|
||||
R5f.xyz = (texture(textureUnitPS0, R0f.wy).xyz);
|
||||
R7f.xyz = (texture(textureUnitPS0, R2f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R3f.x * R8f.z + R0f.x);
|
||||
PV0f.x = R123f.x;
|
||||
R127f.y = R4f.z * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.y = R127f.y;
|
||||
R123f.z = (R3f.x * R8f.x + R0f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R3f.x * R8f.y + R4f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R0f.y = R5f.w + R2f.y;
|
||||
PS0f = R0f.y;
|
||||
// 1
|
||||
R123f.x = (R6f.w * R1f.y + PV0f.w);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R6f.w * R1f.x + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R0f.z = R10f.x + R2f.x;
|
||||
PV1f.z = R0f.z;
|
||||
R123f.w = (R6f.w * R1f.z + PV0f.x);
|
||||
PV1f.w = R123f.w;
|
||||
R0f.w = PV0f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS1f = R0f.w;
|
||||
// 2
|
||||
backupReg0f = R5f.x;
|
||||
R5f.x = R10f.x + PV1f.z;
|
||||
PV0f.x = R5f.x;
|
||||
R123f.y = (R4f.z * R5f.y + PV1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R4f.z * R5f.z + PV1f.w);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R4f.z * backupReg0f + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R5f.y = R5f.w + R0f.y;
|
||||
PS0f = R5f.y;
|
||||
// 3
|
||||
backupReg0f = R7f.z;
|
||||
R1f.x = (R127f.y * R7f.x + PV0f.w);
|
||||
R1f.y = R0f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.y = R1f.y;
|
||||
R7f.z = (R127f.y * backupReg0f + PV0f.z);
|
||||
R6f.w = (R127f.y * R7f.y + PV0f.y);
|
||||
R7f.x = R10f.x + PV0f.x;
|
||||
PS1f = R7f.x;
|
||||
// 4
|
||||
R2f.x = R10f.x + PS1f;
|
||||
PV0f.x = R2f.x;
|
||||
R7f.y = R5f.w + R5f.y;
|
||||
PV0f.y = R7f.y;
|
||||
R8f.w = PV1f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.w = R8f.w;
|
||||
// 5
|
||||
R9f.x = R10f.x + PV0f.x;
|
||||
R2f.y = R5f.w + PV0f.y;
|
||||
R1f.w = PV0f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R0f.xyz = (texture(textureUnitPS0, R0f.zy).xyz);
|
||||
R5f.xyz = (texture(textureUnitPS0, R5f.xy).xyz);
|
||||
R4f.xyz = (texture(textureUnitPS0, R7f.xy).xyz);
|
||||
R3f.xyz = (texture(textureUnitPS0, R2f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R0f.w * R0f.y + R6f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R123f.y = (R0f.w * R0f.x + R1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R0f.w * R0f.z + R7f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R9f.w = R5f.w + R2f.y;
|
||||
// 1
|
||||
backupReg0f = R5f.x;
|
||||
R5f.x = R1f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.x = R5f.x;
|
||||
R123f.y = (R1f.y * R5f.z + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R1f.y * R5f.y + PV0f.x);
|
||||
PV1f.z = R123f.z;
|
||||
R123f.w = (R1f.y * backupReg0f + PV0f.y);
|
||||
PV1f.w = R123f.w;
|
||||
R1f.x = R10f.x + R9f.x;
|
||||
PS1f = R1f.x;
|
||||
// 2
|
||||
R123f.x = (R8f.w * R4f.x + PV1f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R1f.y = R5f.w + R9f.w;
|
||||
PV0f.y = R1f.y;
|
||||
R123f.z = (R8f.w * R4f.y + PV1f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R8f.w * R4f.z + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R8f.w = PV1f.x * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS0f = R8f.w;
|
||||
// 3
|
||||
backupReg0f = R3f.x;
|
||||
R3f.x = (R1f.w * R3f.z + PV0f.w);
|
||||
R4f.y = (R1f.w * R3f.y + PV0f.z);
|
||||
R3f.z = (R1f.w * backupReg0f + PV0f.x);
|
||||
R3f.w = R10f.x + R1f.x;
|
||||
PV1f.w = R3f.w;
|
||||
R3f.y = R5f.w + PV0f.y;
|
||||
PS1f = R3f.y;
|
||||
// 4
|
||||
R0f.x = R10f.x + PV1f.w;
|
||||
R0f.y = R5f.w + PS1f;
|
||||
R4f.z = R8f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R6f.w = 1.0;
|
||||
R9f.xyz = (texture(textureUnitPS0, R9f.xw).xyz);
|
||||
R1f.xyz = (texture(textureUnitPS0, R1f.xy).xyz);
|
||||
R2f.xyz = (texture(textureUnitPS0, R3f.wy).xyz);
|
||||
R7f.xyz = (texture(textureUnitPS0, R0f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R5f.x * R9f.z + R3f.x);
|
||||
PV0f.x = R123f.x;
|
||||
R127f.y = R4f.z * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.y = R127f.y;
|
||||
R123f.z = (R5f.x * R9f.x + R3f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R5f.x * R9f.y + R4f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R3f.y = R5f.w + R0f.y;
|
||||
PS0f = R3f.y;
|
||||
// 1
|
||||
R123f.x = (R8f.w * R1f.y + PV0f.w);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R8f.w * R1f.x + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R3f.z = R10f.x + R0f.x;
|
||||
PV1f.z = R3f.z;
|
||||
R123f.w = (R8f.w * R1f.z + PV0f.x);
|
||||
PV1f.w = R123f.w;
|
||||
R3f.w = PV0f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PS1f = R3f.w;
|
||||
// 2
|
||||
backupReg0f = R2f.x;
|
||||
R2f.x = R10f.x + PV1f.z;
|
||||
PV0f.x = R2f.x;
|
||||
R123f.y = (R4f.z * R2f.y + PV1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R4f.z * R2f.z + PV1f.w);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R4f.z * backupReg0f + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
R2f.y = R5f.w + R3f.y;
|
||||
PS0f = R2f.y;
|
||||
// 3
|
||||
backupReg0f = R7f.z;
|
||||
R0f.x = (R127f.y * R7f.x + PV0f.w);
|
||||
R0f.y = R3f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV1f.y = R0f.y;
|
||||
R7f.z = (R127f.y * backupReg0f + PV0f.z);
|
||||
R8f.w = (R127f.y * R7f.y + PV0f.y);
|
||||
R7f.x = R10f.x + PV0f.x;
|
||||
PS1f = R7f.x;
|
||||
// 4
|
||||
backupReg0f = R10f.x;
|
||||
R10f.x = backupReg0f + PS1f;
|
||||
R7f.y = R5f.w + R2f.y;
|
||||
PV0f.y = R7f.y;
|
||||
R9f.w = PV1f.y * intBitsToFloat(uf_remappedPS[1].y);
|
||||
PV0f.w = R9f.w;
|
||||
// 5
|
||||
R10f.y = R5f.w + PV0f.y;
|
||||
R5f.w = PV0f.w * intBitsToFloat(uf_remappedPS[1].y);
|
||||
R3f.xyz = (texture(textureUnitPS0, R3f.zy).xyz);
|
||||
R2f.xyz = (texture(textureUnitPS0, R2f.xy).xyz);
|
||||
R4f.xyz = (texture(textureUnitPS0, R7f.xy).xyz);
|
||||
R10f.xyz = (texture(textureUnitPS0, R10f.xy).xyz);
|
||||
// 0
|
||||
R123f.x = (R3f.w * R3f.y + R8f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R123f.y = (R3f.w * R3f.x + R0f.x);
|
||||
PV0f.y = R123f.y;
|
||||
R123f.z = (R3f.w * R3f.z + R7f.z);
|
||||
PV0f.z = R123f.z;
|
||||
// 1
|
||||
R123f.y = (R0f.y * R2f.z + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R0f.y * R2f.y + PV0f.x);
|
||||
PV1f.z = R123f.z;
|
||||
R123f.w = (R0f.y * R2f.x + PV0f.y);
|
||||
PV1f.w = R123f.w;
|
||||
// 2
|
||||
R123f.x = (R9f.w * R4f.x + PV1f.w);
|
||||
PV0f.x = R123f.x;
|
||||
R123f.z = (R9f.w * R4f.y + PV1f.z);
|
||||
PV0f.z = R123f.z;
|
||||
R123f.w = (R9f.w * R4f.z + PV1f.y);
|
||||
PV0f.w = R123f.w;
|
||||
// 3
|
||||
R123f.x = (R5f.w * R10f.z + PV0f.w);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R5f.w * R10f.y + PV0f.z);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R5f.w * R10f.x + PV0f.x);
|
||||
PV1f.z = R123f.z;
|
||||
// 4
|
||||
R6f.x = PV1f.z * intBitsToFloat(uf_remappedPS[1].z);
|
||||
R6f.y = PV1f.y * intBitsToFloat(uf_remappedPS[1].z);
|
||||
R6f.z = PV1f.x * intBitsToFloat(uf_remappedPS[1].z);
|
||||
// export
|
||||
passPixelColor0 = vec4(R6f.x, R6f.y, R6f.z, R6f.w);
|
||||
}
|
82
Source/XenobladeX/497a209b49886520_0000000000000000_vs.txt
Normal file
82
Source/XenobladeX/497a209b49886520_0000000000000000_vs.txt
Normal file
@ -0,0 +1,82 @@
|
||||
#version 420
|
||||
#extension GL_ARB_texture_gather : enable
|
||||
#extension GL_ARB_shading_language_packing : enable
|
||||
// shader 497a209b49886520 // magic value hack aligment issue 1-> 1/2
|
||||
uniform ivec4 uf_remappedVS[1];
|
||||
uniform vec2 uf_windowSpaceToClipSpaceTransform;
|
||||
layout(binding = 32) uniform sampler2D textureUnitVS0;// Tex0 addr 0xf545c000 res 1x1x1 dim 1 tm: 2 format 081e compSel: 0 1 4 5 mipView: 0x0 (num 0x1) sliceView: 0x0 (num 0x1) Sampler18 ClampX/Y/Z: 2 2 2 border: 0
|
||||
layout(location = 0) in uvec4 attrDataSem0;
|
||||
layout(location = 1) in uvec4 attrDataSem1;
|
||||
out gl_PerVertex
|
||||
{
|
||||
vec4 gl_Position;
|
||||
float gl_PointSize;
|
||||
};
|
||||
layout(location = 1) out vec4 passParameterSem1;
|
||||
layout(location = 2) out vec4 passParameterSem2;
|
||||
layout(location = 0) out vec4 passParameterSem0;
|
||||
int clampFI32(int v)
|
||||
{
|
||||
if( v == 0x7FFFFFFF )
|
||||
return floatBitsToInt(1.0);
|
||||
else if( v == 0xFFFFFFFF )
|
||||
return floatBitsToInt(0.0);
|
||||
return floatBitsToInt(clamp(intBitsToFloat(v), 0.0, 1.0));
|
||||
}
|
||||
float mul_nonIEEE(float a, float b){ return min(a*b,min(abs(a)*3.40282347E+38F,abs(b)*3.40282347E+38F)); }
|
||||
void main()
|
||||
{
|
||||
vec4 R0f = vec4(0.0);
|
||||
vec4 R1f = vec4(0.0);
|
||||
vec4 R2f = vec4(0.0);
|
||||
vec4 R3f = vec4(0.0);
|
||||
uvec4 attrDecoder;
|
||||
float backupReg0f, backupReg1f, backupReg2f, backupReg3f, backupReg4f;
|
||||
vec4 PV0f = vec4(0.0), PV1f = vec4(0.0);
|
||||
float PS0f = 0.0, PS1f = 0.0;
|
||||
vec4 tempf = vec4(0.0);
|
||||
float tempResultf;
|
||||
int tempResulti;
|
||||
ivec4 ARi = ivec4(0);
|
||||
bool predResult = true;
|
||||
vec3 cubeMapSTM;
|
||||
int cubeMapFaceId;
|
||||
R0f = floatBitsToInt(ivec4(gl_VertexID, 0, 0, gl_InstanceID));
|
||||
attrDecoder.xyz = attrDataSem0.xyz;
|
||||
attrDecoder.xyz = (attrDecoder.xyz>>24)|((attrDecoder.xyz>>8)&0xFF00)|((attrDecoder.xyz<<8)&0xFF0000)|((attrDecoder.xyz<<24));
|
||||
attrDecoder.w = 0;
|
||||
R1f = vec4(intBitsToFloat(int(attrDecoder.x)), intBitsToFloat(int(attrDecoder.y)), intBitsToFloat(int(attrDecoder.z)), intBitsToFloat(floatBitsToInt(1.0)));
|
||||
attrDecoder.xy = attrDataSem1.xy;
|
||||
attrDecoder.xy = (attrDecoder.xy>>24)|((attrDecoder.xy>>8)&0xFF00)|((attrDecoder.xy<<8)&0xFF0000)|((attrDecoder.xy<<24));
|
||||
attrDecoder.z = 0;
|
||||
attrDecoder.w = 0;
|
||||
R2f = vec4(intBitsToFloat(int(attrDecoder.x)), intBitsToFloat(int(attrDecoder.y)), intBitsToFloat(floatBitsToInt(0.0)), intBitsToFloat(floatBitsToInt(1.0)));
|
||||
// 0
|
||||
backupReg0f = R2f.x;
|
||||
backupReg1f = R2f.y;
|
||||
backupReg0f = R2f.x;
|
||||
backupReg1f = R2f.y;
|
||||
R2f.x = backupReg0f;
|
||||
R2f.y = backupReg1f;
|
||||
R0f.z = intBitsToFloat(0x3f000000);
|
||||
R0f.w = (backupReg0f * intBitsToFloat(uf_remappedVS[0].x) + intBitsToFloat(uf_remappedVS[0].z));
|
||||
R0f.y = (backupReg1f * intBitsToFloat(uf_remappedVS[0].y) + intBitsToFloat(uf_remappedVS[0].w));
|
||||
PS0f = R0f.y;
|
||||
R3f.xy = (textureLod(textureUnitVS0, R0f.zz,0.0).xy);
|
||||
// export
|
||||
//gl_Position = vec4(R1f.x, R1f.y - 0.001, R1f.z, R1f.w*1.0040);
|
||||
|
||||
gl_Position = vec4(R1f.x, R1f.y-0.0015, R1f.z, R1f.w*1.0040);
|
||||
// export
|
||||
passParameterSem1 = vec4(R2f.x, R2f.y, R2f.z, R2f.z);
|
||||
// export
|
||||
passParameterSem2 = vec4(R0f.w, R0f.y, R0f.z, R0f.z);
|
||||
// 0
|
||||
backupReg0f = R3f.x;
|
||||
backupReg1f = R3f.y;
|
||||
R3f.x = backupReg0f;
|
||||
R3f.y = backupReg1f;
|
||||
// export
|
||||
passParameterSem0 = vec4(R3f.x, R3f.y, R3f.z, R3f.z);
|
||||
// 0
|
||||
}
|
@ -173,11 +173,11 @@ void main()
|
||||
PV1f.w = R127f.w;
|
||||
// 6
|
||||
PV0f.x = PV1f.z + -(PV1f.w);
|
||||
R5f.y = (PV1f.y * 0.35 + R127f.x);//degree of bloom
|
||||
R5f.x = (PV1f.x * 0.35 + R127f.z);
|
||||
R5f.y = (PV1f.y * 0.30 + R127f.x);//degree of bloom
|
||||
R5f.x = (PV1f.x * 0.30 + R127f.z);
|
||||
PS0f = R5f.x;
|
||||
// 7
|
||||
R5f.z = (PV0f.x * 0.35 + R127f.w);
|
||||
R5f.z = (PV0f.x * 0.30 + R127f.w);
|
||||
// export
|
||||
passPixelColor0 = vec4(R5f.x, R5f.y, R5f.z, R5f.w);
|
||||
}
|
||||
|
68
Source/XenobladeX/9ae7833e513d2c25_0000000000000079_ps.txt
Normal file
68
Source/XenobladeX/9ae7833e513d2c25_0000000000000079_ps.txt
Normal file
@ -0,0 +1,68 @@
|
||||
<?php
|
||||
include 'Source/functions.php';
|
||||
$fullWidth = $argv[1];
|
||||
$fullHeight = $argv[2];
|
||||
$scaleFactorX = always_decimal_format($fullWidth / 1280.0);
|
||||
$scaleFactorY = always_decimal_format($fullHeight / 720.0);
|
||||
?>
|
||||
|
||||
#version 420
|
||||
#extension GL_ARB_texture_gather : enable
|
||||
// shader 9ae7833e513d2c25 // bloom sampling scale
|
||||
const float resScale = <?=$scaleFactorX?>;
|
||||
//const float resScale = 4.0;
|
||||
uniform ivec4 uf_remappedPS[1];
|
||||
layout(binding = 0) uniform sampler2D textureUnitPS0;// Tex0 addr 0xf4f4c800 res 80x46x1 dim 1 tm: 4 format 0816 compSel: 0 1 2 5 mipView: 0x0 (num 0x1) sliceView: 0x0 (num 0x1) Sampler0 ClampX/Y/Z: 2 2 2 border: 0
|
||||
layout(location = 0) in vec4 passParameterSem0;
|
||||
layout(location = 0) out vec4 passPixelColor0;
|
||||
uniform vec2 uf_fragCoordScale;
|
||||
int clampFI32(int v)
|
||||
{
|
||||
if( v == 0x7FFFFFFF )
|
||||
return floatBitsToInt(1.0);
|
||||
else if( v == 0xFFFFFFFF )
|
||||
return floatBitsToInt(0.0);
|
||||
return floatBitsToInt(clamp(intBitsToFloat(v), 0.0, 1.0));
|
||||
}
|
||||
float mul_nonIEEE(float a, float b){ return min(a*b,min(abs(a)*3.40282347E+38F,abs(b)*3.40282347E+38F)); }
|
||||
void main()
|
||||
{
|
||||
vec4 R0f = vec4(0.0);
|
||||
vec4 R1f = vec4(0.0);
|
||||
float backupReg0f, backupReg1f, backupReg2f, backupReg3f, backupReg4f;
|
||||
vec4 PV0f = vec4(0.0), PV1f = vec4(0.0);
|
||||
float PS0f = 0.0, PS1f = 0.0;
|
||||
vec4 tempf = vec4(0.0);
|
||||
float tempResultf;
|
||||
int tempResulti;
|
||||
ivec4 ARi = ivec4(0);
|
||||
bool predResult = true;
|
||||
vec3 cubeMapSTM;
|
||||
int cubeMapFaceId;
|
||||
R0f = passParameterSem0;
|
||||
R0f.xyz = (texture(textureUnitPS0, R0f.xy).xyz);
|
||||
// 0
|
||||
backupReg0f = R0f.y;
|
||||
backupReg1f = R0f.z;
|
||||
PV0f.y = backupReg0f + -(intBitsToFloat(uf_remappedPS[0].x)/ resScale);
|
||||
PV0f.z = R0f.x + -(intBitsToFloat(uf_remappedPS[0].x)/ resScale);
|
||||
PV0f.w = backupReg1f + -(intBitsToFloat(uf_remappedPS[0].x)/ resScale);
|
||||
R1f.w = 1.0;
|
||||
PS0f = R1f.w;
|
||||
// 1
|
||||
PV1f.x = max(PV0f.z, 0.0);
|
||||
PV1f.y = max(PV0f.y, 0.0);
|
||||
PV1f.z = max(PV0f.w, 0.0);
|
||||
// 2
|
||||
tempf.x = dot(vec4(intBitsToFloat(uf_remappedPS[0].y)/resScale,intBitsToFloat(uf_remappedPS[0].y) / resScale,intBitsToFloat(uf_remappedPS[0].y) / resScale,-0.0),vec4(PV1f.x,PV1f.y,PV1f.z,0.0));
|
||||
PV0f.x = tempf.x;
|
||||
PV0f.y = tempf.x;
|
||||
PV0f.z = tempf.x;
|
||||
PV0f.w = tempf.x;
|
||||
// 3
|
||||
R1f.x = R0f.x * PV0f.x;
|
||||
R1f.y = R0f.y * PV0f.x;
|
||||
R1f.z = R0f.z * PV0f.x;
|
||||
// export
|
||||
passPixelColor0 = vec4(R1f.x, R1f.y, R1f.z, R1f.w);
|
||||
}
|
Loading…
Reference in New Issue
Block a user