{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreigmfbemzvkucg6srjuyotbrwr6iietaca6dahws3xaxe47ywzyb5e",
    "uri": "at://did:plc:dxjzgxe7cvirxkwfjr2tjspt/app.bsky.feed.post/3mfhs5dr7qwr2"
  },
  "path": "/t/february-2026-monthly-wip-screenshot-thread/49404#post_11",
  "publishedAt": "2026-02-22T17:33:26.000Z",
  "site": "https://hub.jmonkeyengine.org",
  "textContent": "\n    uniform vec4 m_MainColor;\n\n    uniform vec4 m_NoiseColor;\n    uniform float m_NoiseSize;\n    uniform float m_NoiseAmount;\n    uniform float m_NoiseOscillationChance;\n    uniform float m_NoiseOscillationForce;\n\n    uniform float m_Progress;\n\n    in vec3 mPosition;\n\n    float hash(vec2 p) {\n        p = fract(p * vec2(123.34, 456.21));\n        p += dot(p, p + 45.32);\n        return fract(p.x * p.y);\n    }\n\n    float rand(vec2 co, float probability, float seed) {\n        float gridSize = 10.0;\n        vec2 gridPos = floor(co * gridSize);\n\n        return step(1.0 - probability, hash(gridPos + seed));\n    }\n\n    vec4 generateWave(\n        float phase,\n        float frequency,\n        float width,\n        float opacity\n    ) {\n        vec4 waveColor = m_MainColor;\n\n        float waveProgress = pow(abs(sin((phase + m_Progress * frequency) + (mPosition.y))), 1.0 / width);\n        waveColor.a *= waveProgress;\n\n        waveColor.a *= opacity;\n        waveColor.rgb *= smoothstep(0.0, 0.8, waveColor.a);\n        return waveColor;\n    }\n\n    void main(){\n        vec4 wavesColor =\n            generateWave(0.0, 0.05, 0.1000, 0.4) +\n            generateWave(0.3, 0.02, 0.0750, 0.4) +\n            generateWave(0.7, 0.08, 0.2000, 0.4) +\n            generateWave(0.0, 0.10, 0.0100, 0.6) +\n            generateWave(0.0, 0.20, 0.0001, 1.0);\n\n        float noiseAmount = m_NoiseAmount;\n        float noiseOscillation = rand(vec2(0.0), m_NoiseOscillationChance, m_Progress) * m_NoiseOscillationForce;\n        noiseAmount += noiseOscillation;\n\n        float randomValue = rand(mPosition.xy / m_NoiseSize, noiseAmount, m_Progress);\n        float noiseInfluence = max(randomValue - wavesColor.a, 0.0);\n\n        vec4 noiseColor = m_NoiseColor * noiseInfluence;\n\n        gl_FragColor = wavesColor + noiseColor;\n    }\n\n\n\nThis is the fragment shader I am using. The most notable difference with respect to the pseudo-random functions I have found on the web was the usage of hashing + step threshold rather than sinusoidal functions. Using sin, the wavy artifacts are evident at low resolutions, while I needed my randomness to look like a random grid of binary 0-1 values.",
  "title": "(February 2026) Monthly WIP Screenshot Thread"
}