# Skybox with ortho camera

**URL:** <https://forum.babylonjs.com/t/skybox-with-ortho-camera/55011>\
**Category:** Bugs\
**Tags:** camera, orthographic, skybox\
**Created:** [November 26, 2024, 5:50pm UTC](https://forum.babylonjs.com/t/skybox-with-ortho-camera/55011 "2024-11-26T17:50:35Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kmatzen](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmatzen/32/42356_2.png) [@kmatzen](https://forum.babylonjs.com/u/kmatzen)\
**Post date:** [November 26, 2024, 5:50pm UTC](https://forum.babylonjs.com/t/skybox-with-ortho-camera/55011/1 "2024-11-26T17:50:35Z")

</div>

> **[Babylon.js Playground](https://playground.babylonjs.com/#UU7RQ%234225)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL and WebGPU 3D scenes

createDefaultSkybox seems to work fine with a perspective camera, but once I switch to an orthographic camera, the skybox disappears. If I set `skybox.ignoreCameraMaxZ = false;` then it renders correctly again. Is this intended?

---

<div class="post-metadata">

**Author:** ![Cedric](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/cedric/32/2742_2.png) [@Cedric](https://forum.babylonjs.com/u/Cedric)\
**Post date:** [November 27, 2024, 8:43am UTC](https://forum.babylonjs.com/t/skybox-with-ortho-camera/55011/2 "2024-11-27T08:43:48Z")

</div>

Yes, ortho camera is different from perspective camera. For example, minZ that is usually close to 0 for perpective is different. like this:

> **[Babylon.js Playground](https://playground.babylonjs.com/#UU7RQ%234226)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL and WebGPU 3D scenes

min/max z are in world coordinates but in clip space for perspective camera. So clipped geometry is different.

---

<div class="post-metadata">

**Author:** ![kmatzen](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmatzen/32/42356_2.png) [@kmatzen](https://forum.babylonjs.com/u/kmatzen)\
**Post date:** [December 3, 2024, 4:27am UTC](https://forum.babylonjs.com/t/skybox-with-ortho-camera/55011/3 "2024-12-03T04:27:22Z")

</div>

I’m not quite sure what the attached playground is supposed to be illustrating. If you swap out the default skybox with an environment map such as textures/environment.env, then it becomes more clear that what is being rendered is the backside of the skybox behind the camera, which makes sense since the near clip is being extended to be behind the camera.
