This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Reference here: http://www.mrao.cam.ac.uk/~dag/CUBEHELIX/ | |
| skg_color128_t skg_col_helix128(float h, float s, float l, float alpha) { | |
| const float tau = 6.28318f; | |
| l = fminf(1,l); | |
| float angle = tau * (h+(1/3.f)); | |
| float amp = s * l * (1.f - l); | |
| float a_cos = cosf(angle); | |
| float a_sin = sinf(angle); | |
| float r = l + amp * (-0.14861f * a_cos + 1.78277f * a_sin); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Shader "Unlit/UnlitShadowed Wavy" | |
| { | |
| Properties | |
| { | |
| _MainTex ("Texture", 2D) = "white" {} | |
| _SwaySpeed("Sway Speed", float) = .5 | |
| _WorldCoherence("Sway Coherence", float) = 0.1 | |
| _WindDirection("Wind Direction", Vector) = (1,1,0,0) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Copyright(c) 2019 Nick Klingensmith (@koujaku). All rights reserved. | |
| // | |
| // This work is licensed under the terms of the MIT license. | |
| // For a copy of this license, see < https://opensource.org/licenses/MIT > | |
| #pragma once | |
| #include <stdio.h> | |
| #include <stdint.h> |
NewerOlder