We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

Cascaded Shadow Maps (CSM)

Home Forums General Questions Cascaded Shadow Maps (CSM)

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #72446
    hans
    Customer

    Hi
    I am very interested in version 4.6 of Cascaded Shadow Maps (CSM) and tested it, but the results were not satisfactory. During this process, I reinstalled the software, created a new project, and tried to change various parameters but still did not solve the problem.

    PCF (Poisson Disk) mode:
    1. Shadow casting error.
    2. The texture surface is not affected by lighting.

    ESM mode:
    1. When dragging the map, a large number of moir é patterns will appear.
    2. The edges of the shadow appear jagged.

    • This topic was modified 7 months, 2 weeks ago by wpadm.
    • This topic was modified 7 months, 2 weeks ago by wpadm.
    Attachments:
    You must be logged in to view attached files.
    #72466

    Hello
    It seems that the Margin is too large and/or ESM Bias is not configured correctly.
    To better understand the problem, could you please provide a minimal version of the scene where the problem persists?

    Attachments:
    You must be logged in to view attached files.

    Verge3D Developer

    #72468
    kdv
    Participant

    4096×4096 CSM shadows (PCF, 4 cascades, blur radius 2.0, scale bias 2.0)
    https://v3d.net/m3s

    2048×2048 CSM shadows (PCF, 4 cascades, blur radius 1.0, scale bias 2.5)
    https://v3d.net/lvj

    It’s kinda art to tune the sun’s shadows )))

    ESM shadows? I wouldn’t recommend using them at all. They are slow and they are aweful.
    https://www.soft8soft.com/topic/verge3d-4-5-pre1-available/#post-66586

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #72476
    hans
    Customer

    <p data-immersive-translate-walked=”f182feb6-d2c1-46ed-aedd-ba5e155df377″ data-immersive-translate-paragraph=”1″>Hello<br data-immersive-translate-walked=”f182feb6-d2c1-46ed-aedd-ba5e155df377″>
    It seems that the Margin is too large and/or ESM Bias is not configured correctly.<br data-immersive-translate-walked=”f182feb6-d2c1-46ed-aedd-ba5e155df377″>
    To better understand the problem, could you please provide a minimal version of the scene where the problem persists?

    @Nurgeldi Doletov
    Hello
    I have tried various values for Margin and ESM Bias, but I have not been able to solve the problem
    I will provide you with the minimum 3dsmax model for persistent issues
    Link: https://pan.baidu.com/s/116ki6GX6eDpVB9wN3ZRx9A?pwd=55sr
    If more complex scenarios are needed, I can provide them later

    #72477
    hans
    Customer

    Thank you KDV. Your scene is fantastic.
    But I need a very large scene, such as: 1 square kilometer

    #72478
    kdv
    Participant

    decrese the scale. even if you scene is 100m by 100m you can present it as 1km by 1 km. For example, thise tiny scene seems to be a quite large scene.
    https://v3d.net/m5o

    This parameter affects the quality of the sun’s shadows significantly:

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #72487
    hans
    Customer

    Perhaps my scene is more complex…
    Your scene’s shadow edges have become jagged, you can pull the camera closer to verify

    #72488
    kdv
    Participant

    Your scene’s shadow edges have become jagged

    They are always jagged in any case. Blur Radius makes them smoother. In that demo the blurring radius is just 1,5. Comparing to your second screenshot there is no jagging at all ))) Also you could compare to this demo. But who am I to give you advice on getting good shadows? It’s only between you and S8S :unsure:

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #72500
    hans
    Customer

    Thank you for your suggestion
    PCF (Poisson Disk) shadow, after many attempts, the effect is suitable for large scenes.
    During this process, the distance between the light and the target cannot exceed 300 meters, otherwise there will be projection errors.
    ESM shadows are not suitable for large scenes because their edge aliasing problem cannot be solved.

    • This reply was modified 7 months, 2 weeks ago by hans.
    #72503

    Yes, in general the problem with ESM is that they are quite hard to set up, so it is best to use CSM with PCF (Poission Disk).
    It might be helpful, these are the settings that gave the best results for me:

    https://v3d.net/v57 (4096px shadow map)
    https://v3d.net/v58 (2048px shadow map)

    Attachments:
    You must be logged in to view attached files.

    Verge3D Developer

    #72507
    kdv
    Participant

    https://v3d.net/v57 (4096px shadow map)

    Increase the blur radius to 2.0 for even better result (less jagging, softer shadows)
    https://v3d.net/v5d

    Puzzles and JS coding. Fast and expensive.

    If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.

    #72530
    hans
    Customer

    Great!
    I think it’s perfect.
    Thank you very much to Nurgeldi Doletov and kdv.

Viewing 12 posts - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.