Files
Pixelplanet 7987fffed4 feat(vault): hidden vault, file actions submenu, dual controller models, and display sharpness
- Add Hidden Vault system:
  - Secure directory storage under ~/.pixelvr_vault with 0700 permissions.
  - Cheat-code combo unlocking triggered on full grip squeeze (A-B-B-A-X-Y default, customizable).
  - Headset removal / face detection gating and inactivity auto-lock.
  - Automatic download history clearing upon vault lock.
- Add File Actions Submenu (Button Y):
  - In-browser file/folder submenu with Move to Vault, Delete, Move, and Rename.
  - Recursive folder move to vault with collision handling.
  - Folder deletion with confirmation dialog.
- Enhance VR controllers and interactions:
  - Dynamic left and right Steam Frame controller render models.
  - Single laser pointer priority with hand swapping via full grip squeeze.
- Fix video format detection:
  - Correct auto-detection and default projection for high-resolution VR180 SBS media (e.g. 7200x3600).
- Visual sharpness & rendering stability:
  - Render swapchain at native 2160x2160 per eye.
  - SDF font rendering with RMS pixel footprint and stem darkening.
  - Razor-sharp procedural UI anti-aliasing and crisp border highlights without distortion.
- Add unit test suite (tests/test_vault.cpp) and documentation specs.
2026-10-17 18:06:19 +02:00

36 lines
1.1 KiB
GLSL

#version 450
layout(binding = 0) uniform sampler2D thumbTex;
layout(push_constant) uniform Push {
mat4 mvp;
vec4 color;
vec4 rect; // x, y (bottom-left), w, h in panel-local units
vec4 uv; // u0, v0, u1, v1
} pc;
layout(location = 0) in vec2 vUV;
layout(location = 0) out vec4 outColor;
void main() {
vec4 col = texture(thumbTex, vUV);
// Exact metric rounded rectangle SDF matching panel styling with screen-space AA
vec2 p = abs(vUV - 0.5) * pc.rect.zw;
vec2 b = 0.5 * pc.rect.zw - vec2(0.018);
vec2 q = max(p - b, 0.0);
float dist = length(q) - 0.018;
vec2 dpx = dFdx(p);
vec2 dpy = dFdy(p);
float pixSize = 0.70710678 * sqrt(dot(dpx, dpx) + dot(dpy, dpy));
float aa = max(pixSize * 1.4, 0.001);
float alpha = 1.0 - smoothstep(-aa, aa, dist);
if (alpha <= 0.002) {
discard;
}
// Thumbnail pixels are sRGB; convert to linear for the VK_FORMAT_*_SRGB framebuffer
vec3 linRgb = pow(max(col.rgb, vec3(0.0)), vec3(2.2));
outColor = vec4(linRgb * pc.color.rgb, col.a * pc.color.a * alpha);
}