Skip to content

fix: restore transparent rendering and opacity for water visibility#1337

Merged
braedonsaunders merged 1 commit into
mainfrom
claude/investigate-water-rendering-9GuJz
Feb 4, 2026
Merged

fix: restore transparent rendering and opacity for water visibility#1337
braedonsaunders merged 1 commit into
mainfrom
claude/investigate-water-rendering-9GuJz

Conversation

@braedonsaunders

Copy link
Copy Markdown
Owner

The water was not rendering because the material was set to opaque mode with depthWrite=true but returning just a vec3 from colorNode. The original working version used transparent rendering.

Changes:

  • Add opacity field to QualitySettings (0.85-0.92 based on quality)
  • Add uOpacity uniform for dynamic opacity control
  • Update colorNode to return vec4(color, opacity) instead of vec3
  • Restore transparent rendering settings:
    • material.transparent = true
    • material.side = THREE.DoubleSide
    • material.depthWrite = false
  • Fix stale comment in normalNode section (confirms [0,1] encoding is correct)

The white-out fix (removing manual fresnel/specular) is preserved. The depth sorting fix (consistent water level per region) is preserved.

https://claude.ai/code/session_01ChDF73v8WwcjKe7cWV82iB

The water was not rendering because the material was set to opaque mode
with depthWrite=true but returning just a vec3 from colorNode. The original
working version used transparent rendering.

Changes:
- Add opacity field to QualitySettings (0.85-0.92 based on quality)
- Add uOpacity uniform for dynamic opacity control
- Update colorNode to return vec4(color, opacity) instead of vec3
- Restore transparent rendering settings:
  - material.transparent = true
  - material.side = THREE.DoubleSide
  - material.depthWrite = false
- Fix stale comment in normalNode section (confirms [0,1] encoding is correct)

The white-out fix (removing manual fresnel/specular) is preserved.
The depth sorting fix (consistent water level per region) is preserved.

https://claude.ai/code/session_01ChDF73v8WwcjKe7cWV82iB
@braedonsaunders braedonsaunders merged commit 062280d into main Feb 4, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants