diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 286469cc1..1a712856d 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -28,7 +28,7 @@ jobs: - name: Tests run: | - cd dev + cd tests/unit_tests ./test.sh build-windows: @@ -37,7 +37,7 @@ jobs: - uses: actions/checkout@v2 - name: Tests run: | - cd dev + cd tests/unit_tests ./test.sh build-macos: @@ -66,7 +66,7 @@ jobs: if: matrix.platform == 'macOS' run: | echo Testing for ${{matrix.platform}} - cd dev + cd tests/unit_tests ./test.sh - name: Tess Tests diff --git a/.rive_head b/.rive_head index b606b8e36..a28453d0b 100644 --- a/.rive_head +++ b/.rive_head @@ -1 +1 @@ -39b803c5886b7df76471e58e8584744b86296c17 +f25ee97a05aaa30a58b13451c8020c4e1c095bed diff --git a/README.md b/README.md index 2ef3d1a39..0744b594c 100644 --- a/README.md +++ b/README.md @@ -40,13 +40,13 @@ To build viewer (plus you'll needed CMake installed) Uses the [Catch2](https://github.com/catchorg/Catch2) testing framework. ``` -cd dev +cd tests/unit_tests ./test.sh ``` -In the ```dev``` directory, run ```test.sh``` to compile and execute the tests. +In the ```tests/unit_tests``` directory, run ```test.sh``` to compile and execute the tests. -(if you've installed `premake5` in `rive-cpp/build`, you can run it with `PATH=../../build:$PATH ./test.sh`) +(if you've installed `premake5` in `rive-runtime/build`, you can run it with `PATH=../../build:$PATH ./test.sh`) The tests live in ```rive/test```. To add new tests, create a new ```xxx_test.cpp``` file here. The test harness will automatically pick up the new file. diff --git a/dependencies/windows/get_premake5.bat b/dependencies/windows/get_premake5.bat index 77687b719..4fc9a2593 100644 --- a/dependencies/windows/get_premake5.bat +++ b/dependencies/windows/get_premake5.bat @@ -2,7 +2,7 @@ pushd %DEPENDENCIES% if not exist ".\bin" mkdir bin echo Downloading Premake5 -curl https://github.com/premake/premake-core/releases/download/v5.0.0-beta1/premake-5.0.0-beta1-windows.zip -L -o .\bin\premake_windows.zip +curl https://github.com/premake/premake-core/releases/download/v5.0.0-beta2/premake-5.0.0-beta2-windows.zip -L -o .\bin\premake_windows.zip pushd bin :: Export premake5 into bin tar -xf premake_windows.zip diff --git a/include/rive/animation/animation_reset_factory.hpp b/include/rive/animation/animation_reset_factory.hpp index 8a4db56e3..b77b8ced9 100644 --- a/include/rive/animation/animation_reset_factory.hpp +++ b/include/rive/animation/animation_reset_factory.hpp @@ -32,9 +32,9 @@ class AnimationResetFactory static void release(std::unique_ptr value); #ifdef TESTING // Used in testing to check pooled resources; - static int resourcesCount() { return m_resources.size(); }; + static int resourcesCount() { return static_cast(m_resources.size()); }; static void releaseResources() { m_resources.clear(); }; #endif }; } // namespace rive -#endif \ No newline at end of file +#endif diff --git a/tess/build/premake5_tess.lua b/tess/build/premake5_tess.lua index a089766ca..23d61b983 100644 --- a/tess/build/premake5_tess.lua +++ b/tess/build/premake5_tess.lua @@ -74,8 +74,7 @@ do targetdir('%{cfg.system}/bin/%{cfg.buildcfg}') objdir('%{cfg.system}/obj/%{cfg.buildcfg}') includedirs({ - rive .. 'dev/test/include', -- for catch.hpp - rive .. 'test', -- for things like rive_file_reader.hpp + rive .. 'tests/include', -- for catch.hpp and for things rive_file_reader.hpp '../include', rive .. '/include', dependencies .. '/sokol', diff --git a/tess/src/sokol/generated/shader.h b/tess/src/sokol/generated/shader.h index e5ba73a1f..5d731e498 100644 --- a/tess/src/sokol/generated/shader.h +++ b/tess/src/sokol/generated/shader.h @@ -224,7 +224,7 @@ static const char fs_source_glsl330[146] = { vec2 _54 = _22.gradientEnd - _22.gradientStart; float _59 = _54.x; float _64 = _54.y; - gradient_uv.x = dot(position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + gradient_uv.x = dot(position - _22.gradientStart, _54) / (_59 * _59 + (_64 * _64)); } else { @@ -236,7 +236,7 @@ static const char fs_source_glsl330[146] = { } */ -static const char vs_path_source_glsl330[709] = { +static const char vs_path_source_glsl330[707] = { 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x33,0x33,0x30,0x0a,0x0a,0x73,0x74, 0x72,0x75,0x63,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x70,0x61,0x72, 0x61,0x6d,0x73,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x74,0x34,0x20,0x6d, @@ -267,21 +267,21 @@ static const char vs_path_source_glsl330[709] = { 0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f, 0x74,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32, 0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20, - 0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f, - 0x35,0x39,0x29,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34, - 0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c, - 0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70, - 0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x67,0x72, - 0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28,0x70,0x6f,0x73, - 0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64, - 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20,0x2f,0x20,0x76,0x65,0x63, - 0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67, - 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32, - 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b, - 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d, - 0x0a,0x7d,0x0a,0x0a,0x00, + 0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f,0x35, + 0x39,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x29, + 0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65, + 0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69, + 0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, + 0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x67,0x72,0x61,0x64, + 0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, + 0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20,0x2f,0x20,0x76,0x65,0x63,0x32,0x28, + 0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e, + 0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x7d, + 0x0a,0x0a,0x00, }; /* #version 330 @@ -479,7 +479,7 @@ static const char fs_source_glsl100[173] = { vec2 _54 = _22.gradientEnd - _22.gradientStart; float _59 = _54.x; float _64 = _54.y; - gradient_uv.x = dot(position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + gradient_uv.x = dot(position - _22.gradientStart, _54) / (_59 * _59 + (_64 * _64)); } else { @@ -491,7 +491,7 @@ static const char fs_source_glsl100[173] = { } */ -static const char vs_path_source_glsl100[699] = { +static const char vs_path_source_glsl100[697] = { 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x31,0x30,0x30,0x0a,0x0a,0x73,0x74, 0x72,0x75,0x63,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x70,0x61,0x72, 0x61,0x6d,0x73,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x74,0x34,0x20,0x6d, @@ -521,21 +521,21 @@ static const char vs_path_source_glsl100[699] = { 0x20,0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e, 0x78,0x20,0x3d,0x20,0x64,0x6f,0x74,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e, 0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53, - 0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x28,0x5f, - 0x35,0x39,0x20,0x2a,0x20,0x5f,0x35,0x39,0x29,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34, - 0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a, - 0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66, - 0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20, - 0x3d,0x20,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32, - 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29, - 0x20,0x2f,0x20,0x76,0x65,0x63,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65, - 0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61, - 0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74, - 0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d, - 0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x00, + 0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x5f,0x35, + 0x39,0x20,0x2a,0x20,0x5f,0x35,0x39,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a, + 0x20,0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20, + 0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c, + 0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20, + 0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e, + 0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20,0x2f, + 0x20,0x76,0x65,0x63,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f, + 0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74, + 0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e, + 0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20, + 0x20,0x20,0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #version 100 @@ -743,7 +743,7 @@ static const char fs_source_glsl300es[213] = { vec2 _54 = _22.gradientEnd - _22.gradientStart; float _59 = _54.x; float _64 = _54.y; - gradient_uv.x = dot(position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + gradient_uv.x = dot(position - _22.gradientStart, _54) / (_59 * _59 + (_64 * _64)); } else { @@ -755,7 +755,7 @@ static const char fs_source_glsl300es[213] = { } */ -static const char vs_path_source_glsl300es[712] = { +static const char vs_path_source_glsl300es[710] = { 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x33,0x30,0x30,0x20,0x65,0x73,0x0a, 0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, 0x70,0x61,0x72,0x61,0x6d,0x73,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x74, @@ -786,21 +786,21 @@ static const char vs_path_source_glsl300es[712] = { 0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d, 0x20,0x64,0x6f,0x74,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20, 0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72, - 0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x28,0x5f,0x35,0x39,0x20, - 0x2a,0x20,0x5f,0x35,0x39,0x29,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a,0x20, - 0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, - 0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c, - 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28, - 0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67, - 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20,0x2f,0x20, - 0x76,0x65,0x63,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32, - 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c, - 0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64, - 0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20, - 0x20,0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x00, + 0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x5f,0x35,0x39,0x20,0x2a, + 0x20,0x5f,0x35,0x39,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36, + 0x34,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65, + 0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79, + 0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x67, + 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28,0x70,0x6f, + 0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20,0x2f,0x20,0x76,0x65, + 0x63,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e, + 0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f, + 0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29, + 0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20, + 0x7d,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #version 300 es @@ -943,12 +943,9 @@ static const char fs_path_source_glsl300es[1034] = { float4 gl_Position : SV_Position; }; - #line 16 "../src/sokol/shader.glsl" void vert_main() { - #line 16 "../src/sokol/shader.glsl" gl_Position = mul(float4(position.x, position.y, 0.0f, 1.0f), _21_mvp); - #line 17 "../src/sokol/shader.glsl" uv = texcoord0; } @@ -963,7 +960,7 @@ static const char fs_path_source_glsl300es[1034] = { return stage_output; } */ -static const char vs_source_hlsl5[890] = { +static const char vs_source_hlsl5[782] = { 0x63,0x62,0x75,0x66,0x66,0x65,0x72,0x20,0x76,0x73,0x5f,0x70,0x61,0x72,0x61,0x6d, 0x73,0x20,0x3a,0x20,0x72,0x65,0x67,0x69,0x73,0x74,0x65,0x72,0x28,0x62,0x30,0x29, 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x72,0x6f,0x77,0x5f,0x6d,0x61,0x6a,0x6f,0x72, @@ -987,39 +984,32 @@ static const char vs_source_hlsl5[890] = { 0x20,0x75,0x76,0x20,0x3a,0x20,0x54,0x45,0x58,0x43,0x4f,0x4f,0x52,0x44,0x30,0x3b, 0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x67,0x6c,0x5f,0x50, 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3a,0x20,0x53,0x56,0x5f,0x50,0x6f,0x73, - 0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65, - 0x20,0x31,0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f, - 0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x76, - 0x6f,0x69,0x64,0x20,0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a, - 0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73, - 0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x6d,0x75,0x6c,0x28,0x66,0x6c,0x6f,0x61, - 0x74,0x34,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x70, - 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e,0x30,0x66,0x2c, - 0x20,0x31,0x2e,0x30,0x66,0x29,0x2c,0x20,0x5f,0x32,0x31,0x5f,0x6d,0x76,0x70,0x29, - 0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x75,0x76,0x20,0x3d,0x20,0x74, - 0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x7d,0x0a,0x0a,0x53,0x50,0x49, - 0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20, - 0x6d,0x61,0x69,0x6e,0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73, - 0x5f,0x49,0x6e,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70, - 0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x70,0x6f,0x73,0x69,0x74,0x69, - 0x6f,0x6e,0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74, - 0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x74, - 0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65, - 0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30, - 0x3b,0x0a,0x20,0x20,0x20,0x20,0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69,0x6e,0x28, - 0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f, - 0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f, - 0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67, - 0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, - 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69, - 0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75, - 0x74,0x70,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x75,0x76,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f, - 0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, + 0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20, + 0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20,0x20, + 0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20, + 0x6d,0x75,0x6c,0x28,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e, + 0x79,0x2c,0x20,0x30,0x2e,0x30,0x66,0x2c,0x20,0x31,0x2e,0x30,0x66,0x29,0x2c,0x20, + 0x5f,0x32,0x31,0x5f,0x6d,0x76,0x70,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x75,0x76, + 0x20,0x3d,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x7d,0x0a, + 0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74, + 0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43, + 0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65, + 0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x70,0x6f, + 0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69, + 0x6e,0x70,0x75,0x74,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20, + 0x20,0x20,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x3d,0x20,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x74,0x65,0x78,0x63,0x6f, + 0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20,0x76,0x65,0x72,0x74,0x5f,0x6d, + 0x61,0x69,0x6e,0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52,0x56, + 0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73,0x74, + 0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20, + 0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x6c,0x5f, + 0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x67,0x6c,0x5f,0x50,0x6f, + 0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67, + 0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x75,0x76, + 0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61, + 0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, }; /* Texture2D tex : register(t0); @@ -1038,10 +1028,8 @@ static const char vs_source_hlsl5[890] = { float4 frag_color : SV_Target0; }; - #line 12 "../src/sokol/shader.glsl" void frag_main() { - #line 12 "../src/sokol/shader.glsl" frag_color = tex.Sample(_tex_sampler, uv); } @@ -1054,7 +1042,7 @@ static const char vs_source_hlsl5[890] = { return stage_output; } */ -static const char fs_source_hlsl5[599] = { +static const char fs_source_hlsl5[527] = { 0x54,0x65,0x78,0x74,0x75,0x72,0x65,0x32,0x44,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x34, 0x3e,0x20,0x74,0x65,0x78,0x20,0x3a,0x20,0x72,0x65,0x67,0x69,0x73,0x74,0x65,0x72, 0x28,0x74,0x30,0x29,0x3b,0x0a,0x53,0x61,0x6d,0x70,0x6c,0x65,0x72,0x53,0x74,0x61, @@ -1070,29 +1058,24 @@ static const char fs_source_hlsl5[599] = { 0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75, 0x74,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x66, 0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3a,0x20,0x53,0x56,0x5f,0x54, - 0x61,0x72,0x67,0x65,0x74,0x30,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x31,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, - 0x76,0x6f,0x69,0x64,0x20,0x66,0x72,0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29, - 0x0a,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x32,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f, - 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x2e,0x53,0x61,0x6d,0x70, - 0x6c,0x65,0x28,0x5f,0x74,0x65,0x78,0x5f,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x2c, - 0x20,0x75,0x76,0x29,0x3b,0x0a,0x7d,0x0a,0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43, - 0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e, - 0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70, - 0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a, - 0x7b,0x0a,0x20,0x20,0x20,0x20,0x75,0x76,0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65, - 0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x75,0x76,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66, - 0x72,0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70, - 0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b, - 0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75, - 0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x66, - 0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72, - 0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70, - 0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, + 0x61,0x72,0x67,0x65,0x74,0x30,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64, + 0x20,0x66,0x72,0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20, + 0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20, + 0x74,0x65,0x78,0x2e,0x53,0x61,0x6d,0x70,0x6c,0x65,0x28,0x5f,0x74,0x65,0x78,0x5f, + 0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x2c,0x20,0x75,0x76,0x29,0x3b,0x0a,0x7d,0x0a, + 0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74, + 0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43, + 0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65, + 0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x75,0x76, + 0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x75, + 0x76,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e, + 0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72, + 0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65, + 0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61, + 0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63, + 0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f, + 0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74, + 0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, }; /* cbuffer vs_path_params : register(b0) @@ -1119,28 +1102,20 @@ static const char fs_source_hlsl5[599] = { float4 gl_Position : SV_Position; }; - #line 17 "../src/sokol/shader.glsl" void vert_main() { - #line 17 "../src/sokol/shader.glsl" gl_Position = mul(float4(position, 0.0f, 1.0f), _22_mvp); - #line 19 "../src/sokol/shader.glsl" if (_22_fillType == 1) { - #line 21 "../src/sokol/shader.glsl" float2 _54 = _22_gradientEnd - _22_gradientStart; - #line 22 "../src/sokol/shader.glsl" float _59 = _54.x; float _64 = _54.y; - #line 23 "../src/sokol/shader.glsl" - gradient_uv.x = dot(position - _22_gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + gradient_uv.x = dot(position - _22_gradientStart, _54) / mad(_59, _59, _64 * _64); } else { - #line 25 "../src/sokol/shader.glsl" if (_22_fillType == 2) { - #line 27 "../src/sokol/shader.glsl" gradient_uv = (position - _22_gradientStart) / distance(_22_gradientStart, _22_gradientEnd).xx; } } @@ -1156,7 +1131,7 @@ static const char fs_source_hlsl5[599] = { return stage_output; } */ -static const char vs_path_source_hlsl5[1537] = { +static const char vs_path_source_hlsl5[1246] = { 0x63,0x62,0x75,0x66,0x66,0x65,0x72,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, 0x70,0x61,0x72,0x61,0x6d,0x73,0x20,0x3a,0x20,0x72,0x65,0x67,0x69,0x73,0x74,0x65, 0x72,0x28,0x62,0x30,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x72,0x6f,0x77,0x5f, @@ -1186,74 +1161,55 @@ static const char vs_path_source_hlsl5[1537] = { 0x74,0x5f,0x75,0x76,0x20,0x3a,0x20,0x54,0x45,0x58,0x43,0x4f,0x4f,0x52,0x44,0x30, 0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x67,0x6c,0x5f, 0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3a,0x20,0x53,0x56,0x5f,0x50,0x6f, - 0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, - 0x76,0x6f,0x69,0x64,0x20,0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29, - 0x0a,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f, - 0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x6d,0x75,0x6c,0x28,0x66,0x6c,0x6f, - 0x61,0x74,0x34,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e, - 0x30,0x66,0x2c,0x20,0x31,0x2e,0x30,0x66,0x29,0x2c,0x20,0x5f,0x32,0x32,0x5f,0x6d, - 0x76,0x70,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x39,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x69,0x66,0x20, - 0x28,0x5f,0x32,0x32,0x5f,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d, - 0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x32,0x31,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20, + 0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64, + 0x20,0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20, + 0x20,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d, + 0x20,0x6d,0x75,0x6c,0x28,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x70,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30,0x66,0x2c,0x20,0x31,0x2e,0x30,0x66, + 0x29,0x2c,0x20,0x5f,0x32,0x32,0x5f,0x6d,0x76,0x70,0x29,0x3b,0x0a,0x20,0x20,0x20, + 0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x5f,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70, + 0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x5f,0x35,0x34, 0x20,0x3d,0x20,0x5f,0x32,0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45, 0x6e,0x64,0x20,0x2d,0x20,0x5f,0x32,0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e, - 0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x32, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39,0x20,0x3d,0x20, - 0x5f,0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66, - 0x6c,0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x79, - 0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x67,0x72, - 0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f, - 0x74,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32, - 0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20, - 0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x28,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f, - 0x35,0x39,0x29,0x20,0x2b,0x20,0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34, - 0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c, - 0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32, - 0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x5f,0x66,0x69,0x6c, - 0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x37,0x20,0x22, - 0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61, - 0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e, + 0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74, + 0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x79,0x3b,0x0a,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75, - 0x76,0x20,0x3d,0x20,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20, - 0x5f,0x32,0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72, - 0x74,0x29,0x20,0x2f,0x20,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32, - 0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c, - 0x20,0x5f,0x32,0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64, - 0x29,0x2e,0x78,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43, - 0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e, - 0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70, - 0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a, - 0x7b,0x0a,0x20,0x20,0x20,0x20,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d, - 0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x70,0x6f,0x73, - 0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x76,0x65,0x72,0x74,0x5f, - 0x6d,0x61,0x69,0x6e,0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52, - 0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73, - 0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20, - 0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x6c, - 0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x67,0x6c,0x5f,0x50, - 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61, - 0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, - 0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74, - 0x5f,0x75,0x76,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20, - 0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a, - 0x00, + 0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74,0x28,0x70,0x6f,0x73,0x69,0x74,0x69, + 0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e, + 0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x6d, + 0x61,0x64,0x28,0x5f,0x35,0x39,0x2c,0x20,0x5f,0x35,0x39,0x2c,0x20,0x5f,0x36,0x34, + 0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20, + 0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x5f,0x66,0x69, + 0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d, + 0x20,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32, + 0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29,0x20, + 0x2f,0x20,0x64,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x5f,0x67, + 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32, + 0x32,0x5f,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x2e,0x78, + 0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, + 0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73, + 0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x28,0x53,0x50, + 0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70,0x75,0x74,0x20, + 0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20, + 0x20,0x20,0x20,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x73,0x74, + 0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69, + 0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x76,0x65,0x72,0x74,0x5f,0x6d,0x61,0x69, + 0x6e,0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52,0x56,0x5f,0x43, + 0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67, + 0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74, + 0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f, + 0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67,0x65,0x5f, + 0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f, + 0x75,0x76,0x20,0x3d,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76, + 0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61, + 0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, }; /* cbuffer fs_path_uniforms : register(b0) @@ -1278,18 +1234,14 @@ static const char vs_path_source_hlsl5[1537] = { float4 frag_color : SV_Target0; }; - #line 18 "../src/sokol/shader.glsl" void frag_main() { - #line 18 "../src/sokol/shader.glsl" if (_18_fillType == 0) { - #line 20 "../src/sokol/shader.glsl" frag_color = _18_colors[0]; } else { - #line 23 "../src/sokol/shader.glsl" float _39; if (_18_fillType == 1) { @@ -1299,26 +1251,16 @@ static const char vs_path_source_hlsl5[1537] = { { _39 = length(gradient_uv); } - #line 24 "../src/sokol/shader.glsl" - #line 25 "../src/sokol/shader.glsl" float4 color = lerp(_18_colors[0], _18_colors[1], smoothstep(_18_stops[0].x, _18_stops[0].y, _39).xxxx); - #line 26 "../src/sokol/shader.glsl" for (int i = 1; i < 15; i++) { - #line 28 "../src/sokol/shader.glsl" if (i >= (_18_stopCount - 1)) { - #line 30 "../src/sokol/shader.glsl" break; } - #line 33 "../src/sokol/shader.glsl" - #line 35 "../src/sokol/shader.glsl" - #line 34 "../src/sokol/shader.glsl" int _91 = i + 1; - #line 35 "../src/sokol/shader.glsl" color = lerp(color, _18_colors[_91], smoothstep(_18_stops[i / 4][i % 4], _18_stops[_91 / 4][_91 % 4], _39).xxxx); } - #line 37 "../src/sokol/shader.glsl" frag_color = color; } } @@ -1332,7 +1274,7 @@ static const char vs_path_source_hlsl5[1537] = { return stage_output; } */ -static const char fs_path_source_hlsl5[1870] = { +static const char fs_path_source_hlsl5[1366] = { 0x63,0x62,0x75,0x66,0x66,0x65,0x72,0x20,0x66,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, 0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73,0x20,0x3a,0x20,0x72,0x65,0x67,0x69,0x73, 0x74,0x65,0x72,0x28,0x62,0x30,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x69,0x6e, @@ -1358,22 +1300,13 @@ static const char fs_path_source_hlsl5[1870] = { 0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66, 0x6c,0x6f,0x61,0x74,0x34,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72, 0x20,0x3a,0x20,0x53,0x56,0x5f,0x54,0x61,0x72,0x67,0x65,0x74,0x30,0x3b,0x0a,0x7d, - 0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x76,0x6f,0x69,0x64,0x20,0x66,0x72,0x61,0x67, - 0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20, - 0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x5f,0x66,0x69,0x6c,0x6c,0x54,0x79, - 0x70,0x65,0x20,0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x32,0x30,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f, - 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x5f,0x31,0x38,0x5f,0x63,0x6f,0x6c,0x6f, - 0x72,0x73,0x5b,0x30,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, - 0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x32,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, + 0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20,0x66,0x72,0x61,0x67,0x5f,0x6d,0x61,0x69, + 0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31, + 0x38,0x5f,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x30,0x29, + 0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66, + 0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x5f,0x31,0x38,0x5f, + 0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d, + 0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x33, 0x39,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f, 0x31,0x38,0x5f,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31, @@ -1384,72 +1317,50 @@ static const char fs_path_source_hlsl5[1870] = { 0x6c,0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x5f,0x33,0x39,0x20,0x3d,0x20, 0x6c,0x65,0x6e,0x67,0x74,0x68,0x28,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f, - 0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x32,0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66, - 0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6c,0x65, - 0x72,0x70,0x28,0x5f,0x31,0x38,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d, - 0x2c,0x20,0x5f,0x31,0x38,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x31,0x5d,0x2c, - 0x20,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x5f, - 0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c,0x20,0x5f,0x31,0x38,0x5f, - 0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c,0x20,0x5f,0x33,0x39,0x29, - 0x2e,0x78,0x78,0x78,0x78,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x36, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e,0x74,0x20,0x69,0x20,0x3d, - 0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b,0x20,0x69,0x2b,0x2b,0x29, - 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65, - 0x20,0x32,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f, - 0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20, + 0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,0x6f, + 0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6c,0x65,0x72,0x70,0x28,0x5f,0x31,0x38,0x5f,0x63, + 0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x5f,0x63,0x6f, + 0x6c,0x6f,0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73, + 0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d, + 0x2e,0x78,0x2c,0x20,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d, + 0x2e,0x79,0x2c,0x20,0x5f,0x33,0x39,0x29,0x2e,0x78,0x78,0x78,0x78,0x29,0x3b,0x0a, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e,0x74, + 0x20,0x69,0x20,0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b,0x20, + 0x69,0x2b,0x2b,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x69, 0x20,0x3e,0x3d,0x20,0x28,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f,0x70,0x43,0x6f,0x75, 0x6e,0x74,0x20,0x2d,0x20,0x31,0x29,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x30,0x20, - 0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68, - 0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61,0x6b, - 0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x35,0x20,0x22,0x2e,0x2e, - 0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65, - 0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x34, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61,0x6b,0x3b,0x0a,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x6e,0x74,0x20,0x5f,0x39,0x31,0x20, - 0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33, - 0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d, - 0x20,0x6c,0x65,0x72,0x70,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38, - 0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x73,0x6d, - 0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f, - 0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x69,0x20,0x25,0x20,0x34,0x5d, - 0x2c,0x20,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f,0x70,0x73,0x5b,0x5f,0x39,0x31,0x20, - 0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f, - 0x33,0x39,0x29,0x2e,0x78,0x78,0x78,0x78,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x37,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f, - 0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x53,0x50, - 0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74, - 0x20,0x6d,0x61,0x69,0x6e,0x28,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73, - 0x73,0x5f,0x49,0x6e,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e, - 0x70,0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69, - 0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69, - 0x6e,0x70,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76, - 0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e,0x28, - 0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f, - 0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f, - 0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67, - 0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f, - 0x6c,0x6f,0x72,0x20,0x3d,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72, - 0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61, - 0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x00, + 0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6c,0x65,0x72, + 0x70,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38,0x5f,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x73,0x6d,0x6f,0x6f,0x74,0x68, + 0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x5f,0x73,0x74,0x6f,0x70,0x73,0x5b,0x69, + 0x20,0x2f,0x20,0x34,0x5d,0x5b,0x69,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31, + 0x38,0x5f,0x73,0x74,0x6f,0x70,0x73,0x5b,0x5f,0x39,0x31,0x20,0x2f,0x20,0x34,0x5d, + 0x5b,0x5f,0x39,0x31,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x33,0x39,0x29,0x2e, + 0x78,0x78,0x78,0x78,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f, + 0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20, + 0x20,0x7d,0x0a,0x7d,0x0a,0x0a,0x53,0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73, + 0x73,0x5f,0x4f,0x75,0x74,0x70,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x28,0x53,0x50, + 0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x49,0x6e,0x70,0x75,0x74,0x20, + 0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x29,0x0a,0x7b,0x0a,0x20, + 0x20,0x20,0x20,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d, + 0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x70,0x75,0x74,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x72, + 0x61,0x67,0x5f,0x6d,0x61,0x69,0x6e,0x28,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x53, + 0x50,0x49,0x52,0x56,0x5f,0x43,0x72,0x6f,0x73,0x73,0x5f,0x4f,0x75,0x74,0x70,0x75, + 0x74,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74,0x3b,0x0a, + 0x20,0x20,0x20,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75,0x74, + 0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x66,0x72, + 0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65, + 0x74,0x75,0x72,0x6e,0x20,0x73,0x74,0x61,0x67,0x65,0x5f,0x6f,0x75,0x74,0x70,0x75, + 0x74,0x3b,0x0a,0x7d,0x0a,0x00, }; /* #include @@ -1474,19 +1385,16 @@ static const char fs_path_source_hlsl5[1870] = { float2 texcoord0 [[attribute(1)]]; }; - #line 16 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_params& _21 [[buffer(0)]]) { main0_out out = {}; - #line 16 "../src/sokol/shader.glsl" out.gl_Position = _21.mvp * float4(in.position.x, in.position.y, 0.0, 1.0); - #line 17 "../src/sokol/shader.glsl" out.uv = in.texcoord0; return out; } */ -static const char vs_source_metal_macos[652] = { +static const char vs_source_metal_macos[544] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -1505,29 +1413,23 @@ static const char vs_source_metal_macos[652] = { 0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28,0x30,0x29, 0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x74, 0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69, - 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x76,0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e, - 0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69, - 0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e, - 0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31, - 0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e,0x2e,0x74,0x65,0x78, - 0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75, - 0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76, + 0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20, + 0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69, + 0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20, + 0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69, + 0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e, + 0x2e,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20, + 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + }; /* #include @@ -1545,17 +1447,15 @@ static const char vs_source_metal_macos[652] = { float2 uv [[user(locn0)]]; }; - #line 12 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], texture2d tex [[texture(0)]], sampler texSmplr [[sampler(0)]]) { main0_out out = {}; - #line 12 "../src/sokol/shader.glsl" out.frag_color = tex.sample(texSmplr, in.uv); return out; } */ -static const char fs_source_metal_macos[473] = { +static const char fs_source_metal_macos[401] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -1567,25 +1467,21 @@ static const char fs_source_metal_macos[473] = { 0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, 0x69,0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29, - 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x32, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67, - 0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74, - 0x65,0x78,0x74,0x75,0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20, - 0x74,0x65,0x78,0x20,0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29, - 0x5d,0x5d,0x2c,0x20,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53, - 0x6d,0x70,0x6c,0x72,0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f, - 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70, - 0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e, - 0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20, - 0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74,0x65,0x78,0x74,0x75, + 0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20,0x74,0x65,0x78,0x20, + 0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29,0x5d,0x5d,0x2c,0x20, + 0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72, + 0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f, + 0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20, + 0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70,0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d, + 0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e,0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20, + 0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a, + 0x00, }; /* #include @@ -1612,29 +1508,21 @@ static const char fs_source_metal_macos[473] = { float2 position [[attribute(0)]]; }; - #line 17 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_path_params& _22 [[buffer(0)]]) { main0_out out = {}; - #line 17 "../src/sokol/shader.glsl" out.gl_Position = _22.mvp * float4(in.position, 0.0, 1.0); - #line 19 "../src/sokol/shader.glsl" if (_22.fillType == 1) { - #line 21 "../src/sokol/shader.glsl" float2 _54 = _22.gradientEnd - _22.gradientStart; - #line 22 "../src/sokol/shader.glsl" float _59 = _54.x; float _64 = _54.y; - #line 23 "../src/sokol/shader.glsl" - out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / fma(_59, _59, _64 * _64); } else { - #line 25 "../src/sokol/shader.glsl" if (_22.fillType == 2) { - #line 27 "../src/sokol/shader.glsl" out.gradient_uv = (in.position - _22.gradientStart) / float2(distance(_22.gradientStart, _22.gradientEnd)); } } @@ -1642,7 +1530,7 @@ static const char fs_source_metal_macos[473] = { } */ -static const char vs_path_source_metal_macos[1280] = { +static const char vs_path_source_metal_macos[989] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -1664,66 +1552,47 @@ static const char vs_path_source_metal_macos[1280] = { 0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x0a,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x70,0x6f,0x73,0x69,0x74, 0x69,0x6f,0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28, - 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x76,0x65, - 0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63, - 0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x37,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30, - 0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x39, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, - 0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69, - 0x6e,0x65,0x20,0x32,0x31,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f, - 0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22, + 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x65,0x72,0x74,0x65,0x78, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74, + 0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a, + 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c, + 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b, 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x5f,0x35,0x34,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, 0x6e,0x74,0x45,0x6e,0x64,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64, - 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65, - 0x20,0x32,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f, - 0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39, - 0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35, - 0x34,0x2e,0x79,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76, - 0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69, - 0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69, - 0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f, - 0x20,0x28,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f,0x35,0x39,0x29,0x20,0x2b,0x20, - 0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20, - 0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69, - 0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, - 0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20, - 0x3d,0x20,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d, - 0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61, - 0x72,0x74,0x29,0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73, - 0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, - 0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61, - 0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20, - 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, - + 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39,0x20,0x3d,0x20,0x5f, + 0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, + 0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x79,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74, + 0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f, + 0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74, + 0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x66,0x6d,0x61,0x28,0x5f,0x35,0x39, + 0x2c,0x20,0x5f,0x35,0x39,0x2c,0x20,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34, + 0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73, + 0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, + 0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, + 0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28, + 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32, + 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29, + 0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e, + 0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53, + 0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, + 0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74, + 0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #include @@ -1749,19 +1618,15 @@ static const char vs_path_source_metal_macos[1280] = { float2 gradient_uv [[user(locn0)]]; }; - #line 18 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], constant fs_path_uniforms& _18 [[buffer(0)]]) { main0_out out = {}; - #line 18 "../src/sokol/shader.glsl" if (_18.fillType == 0) { - #line 20 "../src/sokol/shader.glsl" out.frag_color = _18.colors[0]; } else { - #line 23 "../src/sokol/shader.glsl" float _39; if (_18.fillType == 1) { @@ -1771,33 +1636,23 @@ static const char vs_path_source_metal_macos[1280] = { { _39 = length(in.gradient_uv); } - #line 24 "../src/sokol/shader.glsl" - #line 25 "../src/sokol/shader.glsl" float4 color = mix(_18.colors[0], _18.colors[1], float4(smoothstep(_18.stops[0].x, _18.stops[0].y, _39))); - #line 26 "../src/sokol/shader.glsl" for (int i = 1; i < 15; i++) { - #line 28 "../src/sokol/shader.glsl" if (i >= (_18.stopCount - 1)) { - #line 30 "../src/sokol/shader.glsl" break; } - #line 33 "../src/sokol/shader.glsl" - #line 35 "../src/sokol/shader.glsl" - #line 34 "../src/sokol/shader.glsl" int _91 = i + 1; - #line 35 "../src/sokol/shader.glsl" color = mix(color, _18.colors[_91], float4(smoothstep(_18.stops[i / 4][i % 4], _18.stops[_91 / 4][_91 % 4], _39))); } - #line 37 "../src/sokol/shader.glsl" out.frag_color = color; } return out; } */ -static const char fs_path_source_metal_macos[1686] = { +static const char fs_path_source_metal_macos[1182] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -1817,29 +1672,20 @@ static const char fs_path_source_metal_macos[1686] = { 0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x67, 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65, 0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65, - 0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20, - 0x66,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73, - 0x26,0x20,0x5f,0x31,0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66, - 0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20, - 0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x30,0x20,0x22,0x2e,0x2e, - 0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65, - 0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d, - 0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x3b,0x0a, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20, - 0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f, + 0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69, + 0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d, + 0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x66,0x73,0x5f,0x70, + 0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73,0x26,0x20,0x5f,0x31, + 0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x69, + 0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, + 0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b, + 0x30,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c, + 0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x33,0x39,0x3b,0x0a,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c, 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x20, @@ -1850,60 +1696,37 @@ static const char fs_path_source_metal_macos[1686] = { 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x5f,0x33,0x39,0x20,0x3d,0x20,0x6c,0x65,0x6e,0x67, 0x74,0x68,0x28,0x69,0x6e,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75, - 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c, - 0x69,0x6e,0x65,0x20,0x32,0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73, - 0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c, - 0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78, - 0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20, - 0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66, - 0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70, - 0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c, - 0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c, - 0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32, - 0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e,0x74,0x20,0x69,0x20, - 0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b,0x20,0x69,0x2b,0x2b, - 0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x32,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, + 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78,0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f, + 0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d, + 0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e, + 0x74,0x20,0x69,0x20,0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b, + 0x20,0x69,0x2b,0x2b,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28, 0x69,0x20,0x3e,0x3d,0x20,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x43,0x6f, 0x75,0x6e,0x74,0x20,0x2d,0x20,0x31,0x29,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x30, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61, - 0x6b,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d, - 0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72, - 0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67, - 0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x35,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33, - 0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61,0x6b,0x3b,0x0a,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x6e,0x74,0x20,0x5f,0x39,0x31, - 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x33,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20, - 0x3d,0x20,0x6d,0x69,0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38, - 0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28, - 0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d, - 0x5b,0x69,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, - 0x70,0x73,0x5b,0x5f,0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20, - 0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x37, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, - 0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74, - 0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69, + 0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34, + 0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e, + 0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x69,0x20,0x25, + 0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x5f, + 0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20,0x25,0x20,0x34,0x5d, + 0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e, + 0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65, + 0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #include @@ -1928,19 +1751,16 @@ static const char fs_path_source_metal_macos[1686] = { float2 texcoord0 [[attribute(1)]]; }; - #line 16 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_params& _21 [[buffer(0)]]) { main0_out out = {}; - #line 16 "../src/sokol/shader.glsl" out.gl_Position = _21.mvp * float4(in.position.x, in.position.y, 0.0, 1.0); - #line 17 "../src/sokol/shader.glsl" out.uv = in.texcoord0; return out; } */ -static const char vs_source_metal_ios[652] = { +static const char vs_source_metal_ios[544] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -1959,29 +1779,23 @@ static const char vs_source_metal_ios[652] = { 0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28,0x30,0x29, 0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x74, 0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69, - 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x76,0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e, - 0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69, - 0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e, - 0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31, - 0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e,0x2e,0x74,0x65,0x78, - 0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75, - 0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76, + 0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20, + 0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69, + 0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20, + 0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69, + 0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e, + 0x2e,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20, + 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + }; /* #include @@ -1999,17 +1813,15 @@ static const char vs_source_metal_ios[652] = { float2 uv [[user(locn0)]]; }; - #line 12 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], texture2d tex [[texture(0)]], sampler texSmplr [[sampler(0)]]) { main0_out out = {}; - #line 12 "../src/sokol/shader.glsl" out.frag_color = tex.sample(texSmplr, in.uv); return out; } */ -static const char fs_source_metal_ios[473] = { +static const char fs_source_metal_ios[401] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2021,25 +1833,21 @@ static const char fs_source_metal_ios[473] = { 0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, 0x69,0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29, - 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x32, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67, - 0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74, - 0x65,0x78,0x74,0x75,0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20, - 0x74,0x65,0x78,0x20,0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29, - 0x5d,0x5d,0x2c,0x20,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53, - 0x6d,0x70,0x6c,0x72,0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f, - 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70, - 0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e, - 0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20, - 0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74,0x65,0x78,0x74,0x75, + 0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20,0x74,0x65,0x78,0x20, + 0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29,0x5d,0x5d,0x2c,0x20, + 0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72, + 0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f, + 0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20, + 0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70,0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d, + 0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e,0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20, + 0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a, + 0x00, }; /* #include @@ -2066,29 +1874,21 @@ static const char fs_source_metal_ios[473] = { float2 position [[attribute(0)]]; }; - #line 17 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_path_params& _22 [[buffer(0)]]) { main0_out out = {}; - #line 17 "../src/sokol/shader.glsl" out.gl_Position = _22.mvp * float4(in.position, 0.0, 1.0); - #line 19 "../src/sokol/shader.glsl" if (_22.fillType == 1) { - #line 21 "../src/sokol/shader.glsl" float2 _54 = _22.gradientEnd - _22.gradientStart; - #line 22 "../src/sokol/shader.glsl" float _59 = _54.x; float _64 = _54.y; - #line 23 "../src/sokol/shader.glsl" - out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / fma(_59, _59, _64 * _64); } else { - #line 25 "../src/sokol/shader.glsl" if (_22.fillType == 2) { - #line 27 "../src/sokol/shader.glsl" out.gradient_uv = (in.position - _22.gradientStart) / float2(distance(_22.gradientStart, _22.gradientEnd)); } } @@ -2096,7 +1896,7 @@ static const char fs_source_metal_ios[473] = { } */ -static const char vs_path_source_metal_ios[1280] = { +static const char vs_path_source_metal_ios[989] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2118,66 +1918,47 @@ static const char vs_path_source_metal_ios[1280] = { 0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x0a,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x70,0x6f,0x73,0x69,0x74, 0x69,0x6f,0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28, - 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x76,0x65, - 0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63, - 0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x37,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30, - 0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x39, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, - 0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69, - 0x6e,0x65,0x20,0x32,0x31,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f, - 0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22, + 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x65,0x72,0x74,0x65,0x78, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74, + 0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a, + 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c, + 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b, 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x5f,0x35,0x34,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, 0x6e,0x74,0x45,0x6e,0x64,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64, - 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65, - 0x20,0x32,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f, - 0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39, - 0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35, - 0x34,0x2e,0x79,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76, - 0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69, - 0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69, - 0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f, - 0x20,0x28,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f,0x35,0x39,0x29,0x20,0x2b,0x20, - 0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20, - 0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69, - 0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, - 0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20, - 0x3d,0x20,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d, - 0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61, - 0x72,0x74,0x29,0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73, - 0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, - 0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61, - 0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20, - 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, - + 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39,0x20,0x3d,0x20,0x5f, + 0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, + 0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x79,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74, + 0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f, + 0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74, + 0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x66,0x6d,0x61,0x28,0x5f,0x35,0x39, + 0x2c,0x20,0x5f,0x35,0x39,0x2c,0x20,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34, + 0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73, + 0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, + 0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, + 0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28, + 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32, + 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29, + 0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e, + 0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53, + 0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, + 0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74, + 0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #include @@ -2203,19 +1984,15 @@ static const char vs_path_source_metal_ios[1280] = { float2 gradient_uv [[user(locn0)]]; }; - #line 18 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], constant fs_path_uniforms& _18 [[buffer(0)]]) { main0_out out = {}; - #line 18 "../src/sokol/shader.glsl" if (_18.fillType == 0) { - #line 20 "../src/sokol/shader.glsl" out.frag_color = _18.colors[0]; } else { - #line 23 "../src/sokol/shader.glsl" float _39; if (_18.fillType == 1) { @@ -2225,33 +2002,23 @@ static const char vs_path_source_metal_ios[1280] = { { _39 = length(in.gradient_uv); } - #line 24 "../src/sokol/shader.glsl" - #line 25 "../src/sokol/shader.glsl" float4 color = mix(_18.colors[0], _18.colors[1], float4(smoothstep(_18.stops[0].x, _18.stops[0].y, _39))); - #line 26 "../src/sokol/shader.glsl" for (int i = 1; i < 15; i++) { - #line 28 "../src/sokol/shader.glsl" if (i >= (_18.stopCount - 1)) { - #line 30 "../src/sokol/shader.glsl" break; } - #line 33 "../src/sokol/shader.glsl" - #line 35 "../src/sokol/shader.glsl" - #line 34 "../src/sokol/shader.glsl" int _91 = i + 1; - #line 35 "../src/sokol/shader.glsl" color = mix(color, _18.colors[_91], float4(smoothstep(_18.stops[i / 4][i % 4], _18.stops[_91 / 4][_91 % 4], _39))); } - #line 37 "../src/sokol/shader.glsl" out.frag_color = color; } return out; } */ -static const char fs_path_source_metal_ios[1686] = { +static const char fs_path_source_metal_ios[1182] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2271,29 +2038,20 @@ static const char fs_path_source_metal_ios[1686] = { 0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x67, 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65, 0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65, - 0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20, - 0x66,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73, - 0x26,0x20,0x5f,0x31,0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66, - 0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20, - 0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x30,0x20,0x22,0x2e,0x2e, - 0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65, - 0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d, - 0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x3b,0x0a, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20, - 0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f, + 0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69, + 0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d, + 0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x66,0x73,0x5f,0x70, + 0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73,0x26,0x20,0x5f,0x31, + 0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x69, + 0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, + 0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b, + 0x30,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c, + 0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x33,0x39,0x3b,0x0a,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c, 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x20, @@ -2304,60 +2062,37 @@ static const char fs_path_source_metal_ios[1686] = { 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x5f,0x33,0x39,0x20,0x3d,0x20,0x6c,0x65,0x6e,0x67, 0x74,0x68,0x28,0x69,0x6e,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75, - 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c, - 0x69,0x6e,0x65,0x20,0x32,0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73, - 0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c, - 0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78, - 0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20, - 0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66, - 0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70, - 0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c, - 0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c, - 0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32, - 0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e,0x74,0x20,0x69,0x20, - 0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b,0x20,0x69,0x2b,0x2b, - 0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x32,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, + 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78,0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f, + 0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d, + 0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e, + 0x74,0x20,0x69,0x20,0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b, + 0x20,0x69,0x2b,0x2b,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28, 0x69,0x20,0x3e,0x3d,0x20,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x43,0x6f, 0x75,0x6e,0x74,0x20,0x2d,0x20,0x31,0x29,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x30, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61, - 0x6b,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d, - 0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72, - 0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67, - 0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x35,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33, - 0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61,0x6b,0x3b,0x0a,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x6e,0x74,0x20,0x5f,0x39,0x31, - 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x33,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20, - 0x3d,0x20,0x6d,0x69,0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38, - 0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28, - 0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d, - 0x5b,0x69,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, - 0x70,0x73,0x5b,0x5f,0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20, - 0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x37, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, - 0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74, - 0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69, + 0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34, + 0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e, + 0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x69,0x20,0x25, + 0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x5f, + 0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20,0x25,0x20,0x34,0x5d, + 0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e, + 0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65, + 0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #include @@ -2382,19 +2117,16 @@ static const char fs_path_source_metal_ios[1686] = { float2 texcoord0 [[attribute(1)]]; }; - #line 16 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_params& _21 [[buffer(0)]]) { main0_out out = {}; - #line 16 "../src/sokol/shader.glsl" out.gl_Position = _21.mvp * float4(in.position.x, in.position.y, 0.0, 1.0); - #line 17 "../src/sokol/shader.glsl" out.uv = in.texcoord0; return out; } */ -static const char vs_source_metal_sim[652] = { +static const char vs_source_metal_sim[544] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2413,29 +2145,23 @@ static const char vs_source_metal_sim[652] = { 0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28,0x30,0x29, 0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x74, 0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69, - 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x76,0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f, - 0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e, - 0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x36,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69, - 0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e, - 0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31, - 0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e,0x2e,0x74,0x65,0x78, - 0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75, - 0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x62,0x75,0x74,0x65,0x28,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76, + 0x65,0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20, + 0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69, + 0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20, + 0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x31,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x31,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2e,0x78,0x2c,0x20,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69, + 0x6f,0x6e,0x2e,0x79,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x75,0x76,0x20,0x3d,0x20,0x69,0x6e, + 0x2e,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20, + 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + }; /* #include @@ -2453,17 +2179,15 @@ static const char vs_source_metal_sim[652] = { float2 uv [[user(locn0)]]; }; - #line 12 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], texture2d tex [[texture(0)]], sampler texSmplr [[sampler(0)]]) { main0_out out = {}; - #line 12 "../src/sokol/shader.glsl" out.frag_color = tex.sample(texSmplr, in.uv); return out; } */ -static const char fs_source_metal_sim[473] = { +static const char fs_source_metal_sim[401] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2475,25 +2199,21 @@ static const char fs_source_metal_sim[473] = { 0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f, 0x69,0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29, - 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x32, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67, - 0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74, - 0x65,0x78,0x74,0x75,0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20, - 0x74,0x65,0x78,0x20,0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29, - 0x5d,0x5d,0x2c,0x20,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53, - 0x6d,0x70,0x6c,0x72,0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f, - 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70, - 0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e, - 0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20, - 0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74,0x65,0x78,0x74,0x75, + 0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20,0x74,0x65,0x78,0x20, + 0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29,0x5d,0x5d,0x2c,0x20, + 0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x74,0x65,0x78,0x53,0x6d,0x70,0x6c,0x72, + 0x20,0x5b,0x5b,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f, + 0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20, + 0x74,0x65,0x78,0x2e,0x73,0x61,0x6d,0x70,0x6c,0x65,0x28,0x74,0x65,0x78,0x53,0x6d, + 0x70,0x6c,0x72,0x2c,0x20,0x69,0x6e,0x2e,0x75,0x76,0x29,0x3b,0x0a,0x20,0x20,0x20, + 0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a, + 0x00, }; /* #include @@ -2520,29 +2240,21 @@ static const char fs_source_metal_sim[473] = { float2 position [[attribute(0)]]; }; - #line 17 "../src/sokol/shader.glsl" vertex main0_out main0(main0_in in [[stage_in]], constant vs_path_params& _22 [[buffer(0)]]) { main0_out out = {}; - #line 17 "../src/sokol/shader.glsl" out.gl_Position = _22.mvp * float4(in.position, 0.0, 1.0); - #line 19 "../src/sokol/shader.glsl" if (_22.fillType == 1) { - #line 21 "../src/sokol/shader.glsl" float2 _54 = _22.gradientEnd - _22.gradientStart; - #line 22 "../src/sokol/shader.glsl" float _59 = _54.x; float _64 = _54.y; - #line 23 "../src/sokol/shader.glsl" - out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / ((_59 * _59) + (_64 * _64)); + out.gradient_uv.x = dot(in.position - _22.gradientStart, _54) / fma(_59, _59, _64 * _64); } else { - #line 25 "../src/sokol/shader.glsl" if (_22.fillType == 2) { - #line 27 "../src/sokol/shader.glsl" out.gradient_uv = (in.position - _22.gradientStart) / float2(distance(_22.gradientStart, _22.gradientEnd)); } } @@ -2550,7 +2262,7 @@ static const char fs_source_metal_sim[473] = { } */ -static const char vs_path_source_metal_sim[1280] = { +static const char vs_path_source_metal_sim[989] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2572,66 +2284,47 @@ static const char vs_path_source_metal_sim[1280] = { 0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x0a,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x70,0x6f,0x73,0x69,0x74, 0x69,0x6f,0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28, - 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x31,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x76,0x65, - 0x72,0x74,0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d, - 0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e, - 0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63, - 0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f, - 0x70,0x61,0x72,0x61,0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75, - 0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20, - 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d, - 0x20,0x7b,0x7d,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x37,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, - 0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f, - 0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28, - 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30, - 0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x39, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, - 0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69, - 0x6e,0x65,0x20,0x32,0x31,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f, - 0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22, + 0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x65,0x72,0x74,0x65,0x78, + 0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30, + 0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73, + 0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74, + 0x61,0x6e,0x74,0x20,0x76,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x70,0x61,0x72,0x61, + 0x6d,0x73,0x26,0x20,0x5f,0x32,0x32,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72, + 0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69, + 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69, + 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x6d,0x76,0x70,0x20,0x2a, + 0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74, + 0x69,0x6f,0x6e,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a, + 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c, + 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b, 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20, 0x5f,0x35,0x34,0x20,0x3d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, 0x6e,0x74,0x45,0x6e,0x64,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64, - 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65, - 0x20,0x32,0x32,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f, - 0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39, - 0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35, - 0x34,0x2e,0x79,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76, - 0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69, - 0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69, - 0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f, - 0x20,0x28,0x28,0x5f,0x35,0x39,0x20,0x2a,0x20,0x5f,0x35,0x39,0x29,0x20,0x2b,0x20, - 0x28,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20,0x20,0x20, - 0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f, - 0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72, - 0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69, - 0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, - 0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x37,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20, - 0x3d,0x20,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d, - 0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61, - 0x72,0x74,0x29,0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73, - 0x74,0x61,0x6e,0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, - 0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61, - 0x64,0x69,0x65,0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20, - 0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, - + 0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x35,0x39,0x20,0x3d,0x20,0x5f, + 0x35,0x34,0x2e,0x78,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, + 0x6f,0x61,0x74,0x20,0x5f,0x36,0x34,0x20,0x3d,0x20,0x5f,0x35,0x34,0x2e,0x79,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,0x72,0x61, + 0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x2e,0x78,0x20,0x3d,0x20,0x64,0x6f,0x74, + 0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f, + 0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74, + 0x2c,0x20,0x5f,0x35,0x34,0x29,0x20,0x2f,0x20,0x66,0x6d,0x61,0x28,0x5f,0x35,0x39, + 0x2c,0x20,0x5f,0x35,0x39,0x2c,0x20,0x5f,0x36,0x34,0x20,0x2a,0x20,0x5f,0x36,0x34, + 0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73, + 0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x69,0x66,0x20,0x28,0x5f,0x32,0x32,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65, + 0x20,0x3d,0x3d,0x20,0x32,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74, + 0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x3d,0x20,0x28, + 0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x2d,0x20,0x5f,0x32, + 0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53,0x74,0x61,0x72,0x74,0x29, + 0x20,0x2f,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x64,0x69,0x73,0x74,0x61,0x6e, + 0x63,0x65,0x28,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x53, + 0x74,0x61,0x72,0x74,0x2c,0x20,0x5f,0x32,0x32,0x2e,0x67,0x72,0x61,0x64,0x69,0x65, + 0x6e,0x74,0x45,0x6e,0x64,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74, + 0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; /* #include @@ -2657,19 +2350,15 @@ static const char vs_path_source_metal_sim[1280] = { float2 gradient_uv [[user(locn0)]]; }; - #line 18 "../src/sokol/shader.glsl" fragment main0_out main0(main0_in in [[stage_in]], constant fs_path_uniforms& _18 [[buffer(0)]]) { main0_out out = {}; - #line 18 "../src/sokol/shader.glsl" if (_18.fillType == 0) { - #line 20 "../src/sokol/shader.glsl" out.frag_color = _18.colors[0]; } else { - #line 23 "../src/sokol/shader.glsl" float _39; if (_18.fillType == 1) { @@ -2679,33 +2368,23 @@ static const char vs_path_source_metal_sim[1280] = { { _39 = length(in.gradient_uv); } - #line 24 "../src/sokol/shader.glsl" - #line 25 "../src/sokol/shader.glsl" float4 color = mix(_18.colors[0], _18.colors[1], float4(smoothstep(_18.stops[0].x, _18.stops[0].y, _39))); - #line 26 "../src/sokol/shader.glsl" for (int i = 1; i < 15; i++) { - #line 28 "../src/sokol/shader.glsl" if (i >= (_18.stopCount - 1)) { - #line 30 "../src/sokol/shader.glsl" break; } - #line 33 "../src/sokol/shader.glsl" - #line 35 "../src/sokol/shader.glsl" - #line 34 "../src/sokol/shader.glsl" int _91 = i + 1; - #line 35 "../src/sokol/shader.glsl" color = mix(color, _18.colors[_91], float4(smoothstep(_18.stops[i / 4][i % 4], _18.stops[_91 / 4][_91 % 4], _39))); } - #line 37 "../src/sokol/shader.glsl" out.frag_color = color; } return out; } */ -static const char fs_path_source_metal_sim[1686] = { +static const char fs_path_source_metal_sim[1182] = { 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f, 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65, 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a, @@ -2725,29 +2404,20 @@ static const char fs_path_source_metal_sim[1686] = { 0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x67, 0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65, 0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a, - 0x23,0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63, - 0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c, - 0x73,0x6c,0x22,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69, - 0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65, - 0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20, - 0x66,0x73,0x5f,0x70,0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73, - 0x26,0x20,0x5f,0x31,0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30, - 0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30, - 0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x23, - 0x6c,0x69,0x6e,0x65,0x20,0x31,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f, - 0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73, - 0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66, - 0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20, - 0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x30,0x20,0x22,0x2e,0x2e, - 0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65, - 0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, - 0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d, - 0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x3b,0x0a, - 0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c,0x73,0x65,0x0a,0x20, - 0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x33,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f, + 0x75,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69, + 0x6e,0x20,0x69,0x6e,0x20,0x5b,0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d, + 0x5d,0x2c,0x20,0x63,0x6f,0x6e,0x73,0x74,0x61,0x6e,0x74,0x20,0x66,0x73,0x5f,0x70, + 0x61,0x74,0x68,0x5f,0x75,0x6e,0x69,0x66,0x6f,0x72,0x6d,0x73,0x26,0x20,0x5f,0x31, + 0x38,0x20,0x5b,0x5b,0x62,0x75,0x66,0x66,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29, + 0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74, + 0x20,0x6f,0x75,0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x69, + 0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c,0x54,0x79,0x70,0x65,0x20, + 0x3d,0x3d,0x20,0x30,0x29,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b, + 0x30,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x65,0x6c, + 0x73,0x65,0x0a,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x66,0x6c,0x6f,0x61,0x74,0x20,0x5f,0x33,0x39,0x3b,0x0a,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28,0x5f,0x31,0x38,0x2e,0x66,0x69,0x6c,0x6c, 0x54,0x79,0x70,0x65,0x20,0x3d,0x3d,0x20,0x31,0x29,0x0a,0x20,0x20,0x20,0x20,0x20, @@ -2758,60 +2428,37 @@ static const char fs_path_source_metal_sim[1686] = { 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x5f,0x33,0x39,0x20,0x3d,0x20,0x6c,0x65,0x6e,0x67, 0x74,0x68,0x28,0x69,0x6e,0x2e,0x67,0x72,0x61,0x64,0x69,0x65,0x6e,0x74,0x5f,0x75, - 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c, - 0x69,0x6e,0x65,0x20,0x32,0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73, - 0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c, - 0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73, - 0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e, - 0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78, - 0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20, - 0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66, - 0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70, - 0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c, - 0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c, - 0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x32, - 0x36,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e,0x74,0x20,0x69,0x20, - 0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b,0x20,0x69,0x2b,0x2b, - 0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e, - 0x65,0x20,0x32,0x38,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b, - 0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a, + 0x76,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69,0x78,0x28,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x30,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c,0x6f, + 0x72,0x73,0x5b,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x28,0x73,0x6d, + 0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x78,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, + 0x70,0x73,0x5b,0x30,0x5d,0x2e,0x79,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b, + 0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x66,0x6f,0x72,0x20,0x28,0x69,0x6e, + 0x74,0x20,0x69,0x20,0x3d,0x20,0x31,0x3b,0x20,0x69,0x20,0x3c,0x20,0x31,0x35,0x3b, + 0x20,0x69,0x2b,0x2b,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x66,0x20,0x28, 0x69,0x20,0x3e,0x3d,0x20,0x28,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x43,0x6f, 0x75,0x6e,0x74,0x20,0x2d,0x20,0x31,0x29,0x29,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x30, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61, - 0x6b,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d, - 0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x33,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72, - 0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67, - 0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x35,0x20,0x22,0x2e, - 0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73,0x68,0x61,0x64, - 0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33, - 0x34,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f, - 0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x7b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x62,0x72,0x65,0x61,0x6b,0x3b,0x0a,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20, 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x69,0x6e,0x74,0x20,0x5f,0x39,0x31, - 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20, - 0x33,0x35,0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c, - 0x2f,0x73,0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20, - 0x3d,0x20,0x6d,0x69,0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38, - 0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c, - 0x6f,0x61,0x74,0x34,0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28, - 0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d, - 0x5b,0x69,0x20,0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f, - 0x70,0x73,0x5b,0x5f,0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20, - 0x25,0x20,0x34,0x5d,0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20, - 0x20,0x20,0x20,0x20,0x20,0x20,0x7d,0x0a,0x23,0x6c,0x69,0x6e,0x65,0x20,0x33,0x37, - 0x20,0x22,0x2e,0x2e,0x2f,0x73,0x72,0x63,0x2f,0x73,0x6f,0x6b,0x6f,0x6c,0x2f,0x73, - 0x68,0x61,0x64,0x65,0x72,0x2e,0x67,0x6c,0x73,0x6c,0x22,0x0a,0x20,0x20,0x20,0x20, - 0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c, - 0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20, - 0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74, - 0x3b,0x0a,0x7d,0x0a,0x0a,0x00, + 0x20,0x3d,0x20,0x69,0x20,0x2b,0x20,0x31,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x6d,0x69, + 0x78,0x28,0x63,0x6f,0x6c,0x6f,0x72,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x63,0x6f,0x6c, + 0x6f,0x72,0x73,0x5b,0x5f,0x39,0x31,0x5d,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34, + 0x28,0x73,0x6d,0x6f,0x6f,0x74,0x68,0x73,0x74,0x65,0x70,0x28,0x5f,0x31,0x38,0x2e, + 0x73,0x74,0x6f,0x70,0x73,0x5b,0x69,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x69,0x20,0x25, + 0x20,0x34,0x5d,0x2c,0x20,0x5f,0x31,0x38,0x2e,0x73,0x74,0x6f,0x70,0x73,0x5b,0x5f, + 0x39,0x31,0x20,0x2f,0x20,0x34,0x5d,0x5b,0x5f,0x39,0x31,0x20,0x25,0x20,0x34,0x5d, + 0x2c,0x20,0x5f,0x33,0x39,0x29,0x29,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x20,0x20, + 0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e, + 0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c, + 0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x7d,0x0a,0x20,0x20,0x20,0x20,0x72,0x65, + 0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00, }; #if !defined(SOKOL_GFX_INCLUDED) #error "Please include sokol_gfx.h before shader.h" diff --git a/tests/android_tools/app/.gitignore b/tests/android_tools/app/.gitignore new file mode 100644 index 000000000..42afabfd2 --- /dev/null +++ b/tests/android_tools/app/.gitignore @@ -0,0 +1 @@ +/build \ No newline at end of file diff --git a/tests/android_tools/app/build.gradle.kts b/tests/android_tools/app/build.gradle.kts new file mode 100644 index 000000000..d7708230f --- /dev/null +++ b/tests/android_tools/app/build.gradle.kts @@ -0,0 +1,69 @@ +plugins { + alias(libs.plugins.androidApplication) + alias(libs.plugins.jetbrainsKotlinAndroid) +} + +android { + namespace = "app.rive.android_tools" + compileSdk = 34 + + defaultConfig { + applicationId = "app.rive.android_tools" + minSdk = 21 + targetSdk = 34 + versionCode = 1 + versionName = "1.0" + + testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" + vectorDrawables { + useSupportLibrary = true + } + } + + buildTypes { + release { + isMinifyEnabled = false + proguardFiles( + getDefaultProguardFile("proguard-android-optimize.txt"), + "proguard-rules.pro" + ) + } + } + compileOptions { + sourceCompatibility = JavaVersion.VERSION_1_8 + targetCompatibility = JavaVersion.VERSION_1_8 + } + kotlinOptions { + jvmTarget = "1.8" + } + buildFeatures { + compose = true + } + composeOptions { + kotlinCompilerExtensionVersion = "1.5.1" + } + packaging { + resources { + excludes += "/META-INF/{AL2.0,LGPL2.1}" + } + } +} + +dependencies { + + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.lifecycle.runtime.ktx) + implementation(libs.androidx.activity.compose) + implementation(platform(libs.androidx.compose.bom)) + implementation(libs.androidx.ui) + implementation(libs.androidx.ui.graphics) + implementation(libs.androidx.ui.tooling.preview) + implementation(libs.androidx.material3) + testImplementation(libs.junit) + androidTestImplementation(libs.androidx.junit) + androidTestImplementation(libs.androidx.espresso.core) + androidTestImplementation(platform(libs.androidx.compose.bom)) + androidTestImplementation(libs.androidx.ui.test.junit4) + debugImplementation(libs.androidx.ui.tooling) + debugImplementation(libs.androidx.ui.test.manifest) +} \ No newline at end of file diff --git a/tests/android_tools/app/proguard-rules.pro b/tests/android_tools/app/proguard-rules.pro new file mode 100644 index 000000000..481bb4348 --- /dev/null +++ b/tests/android_tools/app/proguard-rules.pro @@ -0,0 +1,21 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile \ No newline at end of file diff --git a/tests/android_tools/app/src/main/AndroidManifest.xml b/tests/android_tools/app/src/main/AndroidManifest.xml new file mode 100644 index 000000000..5a7eb9d88 --- /dev/null +++ b/tests/android_tools/app/src/main/AndroidManifest.xml @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/android_tools/app/src/main/java/app/rive/android_tools/gms.kt b/tests/android_tools/app/src/main/java/app/rive/android_tools/gms.kt new file mode 100644 index 000000000..3fda2a3cd --- /dev/null +++ b/tests/android_tools/app/src/main/java/app/rive/android_tools/gms.kt @@ -0,0 +1,5 @@ +package app.rive.android_tools + +import android.app.NativeActivity + +class gms : NativeActivity() {} \ No newline at end of file diff --git a/tests/android_tools/app/src/main/java/app/rive/android_tools/goldens.kt b/tests/android_tools/app/src/main/java/app/rive/android_tools/goldens.kt new file mode 100644 index 000000000..98c1d7864 --- /dev/null +++ b/tests/android_tools/app/src/main/java/app/rive/android_tools/goldens.kt @@ -0,0 +1,5 @@ +package app.rive.android_tools + +import android.app.NativeActivity + +class goldens : NativeActivity() {} \ No newline at end of file diff --git a/tests/android_tools/app/src/main/java/app/rive/android_tools/player.kt b/tests/android_tools/app/src/main/java/app/rive/android_tools/player.kt new file mode 100644 index 000000000..8e2075338 --- /dev/null +++ b/tests/android_tools/app/src/main/java/app/rive/android_tools/player.kt @@ -0,0 +1,5 @@ +package app.rive.android_tools + +import android.app.NativeActivity + +class player : NativeActivity() {} \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/drawable-v24/ic_launcher_foreground.xml b/tests/android_tools/app/src/main/res/drawable-v24/ic_launcher_foreground.xml new file mode 100644 index 000000000..2b068d114 --- /dev/null +++ b/tests/android_tools/app/src/main/res/drawable-v24/ic_launcher_foreground.xml @@ -0,0 +1,30 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/drawable/ic_launcher_background.xml b/tests/android_tools/app/src/main/res/drawable/ic_launcher_background.xml new file mode 100644 index 000000000..07d5da9cb --- /dev/null +++ b/tests/android_tools/app/src/main/res/drawable/ic_launcher_background.xml @@ -0,0 +1,170 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 000000000..6f3b755bf --- /dev/null +++ b/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml b/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml new file mode 100644 index 000000000..6f3b755bf --- /dev/null +++ b/tests/android_tools/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher.webp b/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher.webp new file mode 100644 index 000000000..c209e78ec Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp b/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp new file mode 100644 index 000000000..b2dfe3d1b Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher.webp b/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher.webp new file mode 100644 index 000000000..4f0f1d64e Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp b/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp new file mode 100644 index 000000000..62b611da0 Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher.webp b/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher.webp new file mode 100644 index 000000000..948a3070f Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp b/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp new file mode 100644 index 000000000..1b9a6956b Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp b/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp new file mode 100644 index 000000000..28d4b77f9 Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp b/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp new file mode 100644 index 000000000..9287f5083 Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp b/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp new file mode 100644 index 000000000..aa7d6427e Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp differ diff --git a/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp b/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp new file mode 100644 index 000000000..9126ae37c Binary files /dev/null and b/tests/android_tools/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp differ diff --git a/tests/android_tools/app/src/main/res/values/colors.xml b/tests/android_tools/app/src/main/res/values/colors.xml new file mode 100644 index 000000000..f8c6127d3 --- /dev/null +++ b/tests/android_tools/app/src/main/res/values/colors.xml @@ -0,0 +1,10 @@ + + + #FFBB86FC + #FF6200EE + #FF3700B3 + #FF03DAC5 + #FF018786 + #FF000000 + #FFFFFFFF + \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/values/strings.xml b/tests/android_tools/app/src/main/res/values/strings.xml new file mode 100644 index 000000000..a7421837c --- /dev/null +++ b/tests/android_tools/app/src/main/res/values/strings.xml @@ -0,0 +1,3 @@ + + android_tools + \ No newline at end of file diff --git a/tests/android_tools/app/src/main/res/values/themes.xml b/tests/android_tools/app/src/main/res/values/themes.xml new file mode 100644 index 000000000..d9b49996b --- /dev/null +++ b/tests/android_tools/app/src/main/res/values/themes.xml @@ -0,0 +1,5 @@ + + + +