https://github.com/royalicing/goldenorb
Framework-agnostic web components
https://github.com/royalicing/goldenorb
Last synced: 5 months ago
JSON representation
Framework-agnostic web components
- Host: GitHub
- URL: https://github.com/royalicing/goldenorb
- Owner: RoyalIcing
- Created: 2024-10-08T12:34:51.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-11-11T07:37:57.000Z (7 months ago)
- Last Synced: 2026-01-08T17:25:28.194Z (5 months ago)
- Language: Elixir
- Size: 81.1 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# GoldenOrb
**TODO: Add description**
## Installation
If [available in Hex](https://hex.pm/docs/publish), the package can be installed
by adding `golden_orb` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:golden_orb, "~> 0.1.0"}
]
end
```
Documentation can be generated with [ExDoc](https://github.com/elixir-lang/ex_doc)
and published on [HexDocs](https://hexdocs.pm). Once published, the docs can
be found at .
## WebGL2 Shaders
```elixir
defmodule ShaderA do
uniform r: Vec2, t: F32
uniform do
# uniform vec2 r;
@r Vec2
# uniform float t;
@t F32
end
#global do
# export do
# # out vec4 fragColor;
# @fragColor Vec4
# end
#end
main(frag: Vec4) :: Vec4 do
# vec2 st = gl_FragCoord.xy/r.xy;
st = @gl_FragCoord.xy / @r.xy
# st.x *= r.x/r.y;
st.x = st.x * (@r.x / @r.y)
# vec3 color = vec3(0.);
# local(color = vec3(0))
var!(color) = vec3(0)
color = vec3(st.x, st.y, abs(sin(t)))
vec4(color, 1.0)
end
end
```