# \#depth-buffer

**URL:** https://discourse.threejs.org/tag/depth-buffer/1229.md

[Latest](https://discourse.threejs.org/latest.md) · [Categories](https://discourse.threejs.org/categories.md) · [Tags](https://discourse.threejs.org/tags.md)

---

## [Depth Texture Experiment](https://discourse.threejs.org/t/depth-texture-experiment/89932)

<div class="topic-metadata">

**Author:** [@Tibi](https://discourse.threejs.org/u/Tibi)\
**Replies:** 2\
**Last updated:** [February 19, 2026, 11:38pm UTC](https://discourse.threejs.org/t/depth-texture-experiment/89932 "2026-02-19T23:38:03Z")

</div>

Realtime depth-driven line distortion experiment built with Three.js and custom GLSL shaders. This project samples a depth texture from a 3D face model and uses that depth data to displace thousands of line vertices i…

---

## [How to apply a color-only ShaderPass while preserving depth buffer for a later RenderPass?](https://discourse.threejs.org/t/how-to-apply-a-color-only-shaderpass-while-preserving-depth-buffer-for-a-later-renderpass/86735)

<div class="topic-metadata">

**Author:** [@ccinv](https://discourse.threejs.org/u/ccinv)\
**Replies:** 0\
**Last updated:** [September 4, 2025, 10:31pm UTC](https://discourse.threejs.org/t/how-to-apply-a-color-only-shaderpass-while-preserving-depth-buffer-for-a-later-renderpass/86735 "2025-09-04T22:31:08Z")

</div>

Hi, I’m working with EffectComposer and multiple RenderPass in three.js, and I ran into a depth-buffer issue when combining a ShaderPass with additional scenes. Here’s a minimal setup: import { EffectComposer } from 't…

---

## [Internal Faces in PyPlasm-Generated Tube Geometry](https://discourse.threejs.org/t/internal-faces-in-pyplasm-generated-tube-geometry/83201)

<div class="topic-metadata">

**Author:** [@alex\_night](https://discourse.threejs.org/u/alex_night)\
**Replies:** 3\
**Last updated:** [May 28, 2025, 7:19am UTC](https://discourse.threejs.org/t/internal-faces-in-pyplasm-generated-tube-geometry/83201 "2025-05-28T07:19:38Z")

</div>

Background I’m working with complex tube geometry generated using PyPlasm (a powerful geometry library) and rendering it in Three.js. The geometry extraction works flawlessly, but I’m facing a challenging transparency…

---

## [Computing perfectly snug near and far planes for depth rendering](https://discourse.threejs.org/t/computing-perfectly-snug-near-and-far-planes-for-depth-rendering/72622)

<div class="topic-metadata">

**Author:** [@grml](https://discourse.threejs.org/u/grml)\
**Replies:** 5\
**Last updated:** [October 23, 2024, 2:52am UTC](https://discourse.threejs.org/t/computing-perfectly-snug-near-and-far-planes-for-depth-rendering/72622 "2024-10-23T02:52:32Z")

</div>

I have a scene and a PerspectiveCamera, and I want to render the depth of the scene, perfectly normalized in the \[0, 1\] range. My thinking is that I should find the nearest and farthest projected vertex distances in the …

---

## [Selectively disable logarithmicDepthBuffer (WebGPU)](https://discourse.threejs.org/t/selectively-disable-logarithmicdepthbuffer-webgpu/70695)

<div class="topic-metadata">

**Author:** [@torrent](https://discourse.threejs.org/u/torrent)\
**Replies:** 0\
**Last updated:** [September 13, 2024, 11:35pm UTC](https://discourse.threejs.org/t/selectively-disable-logarithmicdepthbuffer-webgpu/70695 "2024-09-13T23:35:25Z")

</div>

Hi all–I have scoured the internet and researched for 6 weeks and have learned all about the new node-based shader system in order to attempt a solution to this, but have had no luck. My question is this: In three.webgp…

---

## [Three JS equivalent operation to BlitFramebuffer](https://discourse.threejs.org/t/three-js-equivalent-operation-to-blitframebuffer/52197)

<div class="topic-metadata">

**Author:** [@AEspinosaDev](https://discourse.threejs.org/u/AEspinosaDev)\
**Replies:** 6\
**Last updated:** [July 31, 2024, 6:51am UTC](https://discourse.threejs.org/t/three-js-equivalent-operation-to-blitframebuffer/52197 "2024-07-31T06:51:49Z")

</div>

Hi guys, I need to do a simple operation in my application, very common in certain techniques, but for some reason I can’t find how to do it in the Three Js framework. The operation is basically render to a certain ren…

---

## [Using rgba-packed texture in depth pre-pass?](https://discourse.threejs.org/t/using-rgba-packed-texture-in-depth-pre-pass/52782)

<div class="topic-metadata">

**Author:** [@vector3](https://discourse.threejs.org/u/vector3)\
**Replies:** 1\
**Last updated:** [October 1, 2023, 12:05am UTC](https://discourse.threejs.org/t/using-rgba-packed-texture-in-depth-pre-pass/52782 "2023-10-01T00:05:05Z")

</div>

Hi, I’m trying to use (externally rendered) depth textures (32-bit, rgba packed) in a depth prepass, so that all subsequently rendered geomtries will be depth-tested against this custom depth buffer. I’m using a custom…

---

## [Using ShadowMaterial with logarithmicDepthBuffer is affecting render-order](https://discourse.threejs.org/t/using-shadowmaterial-with-logarithmicdepthbuffer-is-affecting-render-order/37322)

<div class="topic-metadata">

**Author:** [@abgrac](https://discourse.threejs.org/u/abgrac)\
**Replies:** 3\
**Last updated:** [February 23, 2023, 12:38pm UTC](https://discourse.threejs.org/t/using-shadowmaterial-with-logarithmicdepthbuffer-is-affecting-render-order/37322 "2023-02-23T12:38:17Z")

</div>

Hello all! It’s my first post, nice to meet the community. I have a problem using ShadowMaterial and logarithmicDepthBuffer together, as the ShadowMaterial render order goes awry. Here’s a reproduction of the problem: …

---

## [Panorama with depth enhancement](https://discourse.threejs.org/t/panorama-with-depth-enhancement/38954)

<div class="topic-metadata">

**Author:** [@charlie\_says](https://discourse.threejs.org/u/charlie_says)\
**Replies:** 1\
**Last updated:** [November 29, 2022, 7:32pm UTC](https://discourse.threejs.org/t/panorama-with-depth-enhancement/38954 "2022-11-29T19:32:48Z")

</div>

Slightly off topic query: I was looking at the example on the three site: three.js vr - panorama with depth which I’ve got working with a model of my own. But, I noted some limitations, where you get distortions from th…

---

## [Depth sorting while drawing lines](https://discourse.threejs.org/t/depth-sorting-while-drawing-lines/42807)

<div class="topic-metadata">

**Author:** [@cebugdev](https://discourse.threejs.org/u/cebugdev)\
**Replies:** 0\
**Last updated:** [September 22, 2022, 6:57am UTC](https://discourse.threejs.org/t/depth-sorting-while-drawing-lines/42807 "2022-09-22T06:57:03Z")

</div>

we have an application that draws points and these points are in the mesh or within the mesh/model coordinates. getting the points and drawing circles in that position is easy, also we need to draw a line that connects …

---

## [Depth not working correctly](https://discourse.threejs.org/t/depth-not-working-correctly/42646)

<div class="topic-metadata">

**Author:** [@ennemli](https://discourse.threejs.org/u/ennemli)\
**Replies:** 0\
**Last updated:** [September 18, 2022, 1:22am UTC](https://discourse.threejs.org/t/depth-not-working-correctly/42646 "2022-09-18T01:22:23Z")

</div>

I created two scenes, one for two 2d renderings (Orthographic Camera), and one for 3d rendering(Perspective Camera), I applied an effect on the first scene (2d), and then I checked autoClear=false so I could render these…
