I’m using HDR image as skybox set to Skybox/Cubemap material.
Skybox is 2k HDR. Why do i see it blured after build?
Hello Saad Baig,
The blurring of your skybox after the build can be caused by several factors related to the texture size and how it’s processed. Here are some important points to consider:
-
Texture Size: Ensure your HDR skybox texture size is a power of two. If it isn’t, the engine may resize it to the nearest power of two, which can lead to blurriness. Unity logs a warning if the skybox texture size is not a power of two (see the documentation).
-
Material Settings: Check if you’re using the “Better Cubemap” shader from Needle Engine, which allows for blurriness adjustments. Ensure the properties for
_BackgroundBlurriness
are set correctly (see the documentation). -
Auto Bake Settings: Verify if the automatic baking is enabled for your skybox material. If baking isn’t correctly set up, it may lead to unexpected visual results after building (see the documentation) (see releases).
-
Lighting and Environment Factors: Consider how environmental lighting is affecting your skybox. Make sure you’re exporting the correct environment settings during the build. A cubemap used for baking can also cause issues if not correctly set (see the documentation) (see the documentation).
-
Build Format: The format used for the HDR image can also impact clarity. Make sure you’re using suitable formats for your target platforms (e.g., PNG or EXR) (see the documentation).
-
Resolution Clamping: If your skybox resolution is too high (greater than 4096) and you’re using an EXR format, the engine will automatically clamp the size, which can lead to a blurry output (see the documentation).
Make sure to inspect these aspects in your project settings and shader configurations. If you continue experiencing issues, please share specific details regarding the shader settings or any warning messages you receive during the build process.
Let me know if you need further assistance!
3 replies left
thread_oc10koSAoJmamudeERgjBRia
Reply to this message to continue the conversation
Hi Saad Baig,
Based on the images you provided, it seems that the HDR skybox looks clear in the Unity editor but becomes blurred after export. Here are some potential causes and solutions:
-
Texture Size Limitation: Ensure your HDR skybox texture is not too large. The engine might clamp textures over a certain size (e.g., 4096) which could lead to blurriness during export (see the documentation). Check if your skybox is over this limit, and if so, try reducing its dimensions (see the documentation).
-
Power of Two Requirement: The texture size should be a power of two. If it’s not, the engine may resize it, leading to unexpected results. Check your texture size and, if needed, adjust it to be the next power of two (see the documentation).
-
Cubemap Reflection: Ensure that you’re using an appropriate shader for the skybox. Consider switching to a “Better Cubemap (Needle)” shader, which provides improved quality and supports back-end options like blurriness (see export) (see the documentation).
-
Skybox Export Settings: You may need to adjust the
SkyboxExportSettings
component in your scene. This will allow you to customize the skybox resolution during export (see export). Adding this component gives more control over how the skybox is exported. -
Compression Settings: If you are exporting as a glTF file, check the compression settings. High compression can affect image quality, leading to the blurred appearance (see export).
If after checking these settings the issue persists, please provide further context on the settings of the SkyboxExportSettings
component or any warnings noticed during the export process.
Let me know if you need additional guidance!
2 replies left
thread_oc10koSAoJmamudeERgjBRia
Reply to this message to continue the conversation
Do you have a SkyboxExportSettings component in the scene?
Yes it is.
How is it configured?
skybox export settings component is added on the Export GameObject with rest of the other html meta etc components
You clamp the skybox resolution to 256 pixel in the Skybox Export Settings component. Please remove the component or increase the max resolution!
Okay will try that. thanks!
This topic was automatically closed 13 days after the last reply. New replies are no longer allowed.