From 210d5ec72bbc4ba426b21f69e6f65b6d75923d05 Mon Sep 17 00:00:00 2001 From: Ray Date: Sat, 18 May 2019 01:27:54 +0200 Subject: Update examples to raylib 2.5 -WIP- Remove old examples --- examples/src/core/core_vr_simulator.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'examples/src/core') diff --git a/examples/src/core/core_vr_simulator.c b/examples/src/core/core_vr_simulator.c index 65054b7..b79ed90 100644 --- a/examples/src/core/core_vr_simulator.c +++ b/examples/src/core/core_vr_simulator.c @@ -11,6 +11,12 @@ #include "raylib.h" +#if defined(PLATFORM_DESKTOP) + #define GLSL_VERSION 330 +#else // PLATFORM_RPI, PLATFORM_ANDROID, PLATFORM_WEB + #define GLSL_VERSION 100 +#endif + int main() { // Initialization @@ -49,7 +55,7 @@ int main() hmd.chromaAbCorrection[3] = 0.0f; // HMD chromatic aberration correction parameter 3 // Distortion shader (uses device lens distortion and chroma) - Shader distortion = LoadShader(0, "resources/distortion.fs"); + Shader distortion = LoadShader(0, FormatText("resources/distortion%i.fs", GLSL_VERSION)); SetVrConfiguration(hmd, distortion); // Set Vr device parameters for stereo rendering -- cgit v1.2.3