private void setMatParams() {

        GeometryList l = lightReceivers;

        //iterate through all the geometries in the list to gather the materials

        matCache.clear();
        for (int i = 0; i < l.size(); i++) {
            Material mat = l.get(i).getMaterial();
            //checking if the material has the post technique and adding it to the material cache
            if (mat.getMaterialDef().getTechniqueDefs(postTechniqueName) != null) {
                if (!matCache.contains(mat)) {
                    matCache.add(mat);
                }
            } else {
                needsfallBackMaterial = true;
            }
        }

        //iterating through the mat cache and setting the parameters
        for (Material mat : matCache) {
            mat.setColor("Splits", splits);
            mat.setFloat("ShadowMapSize", shadowMapSize);

            for (int j = 0; j < nbSplits; j++) {
                mat.setMatrix4("LightViewProjectionMatrix" + j, lightViewProjectionsMatrices[j]);
            }
            for (int j = 0; j < nbSplits; j++) {
                mat.setTexture("ShadowMap" + j, shadowMaps[j]);
            }
            mat.setBoolean("HardwareShadows", compareMode == CompareMode.Hardware);
            mat.setInt("FilterMode", filterMode.ordinal());
            mat.setFloat("PCFEdge", edgesThickness);
            mat.setFloat("ShadowIntensity", shadowIntensity);

            if (fadeInfo != null) {
                mat.setVector2("FadeInfo", fadeInfo);
            }

        }

        applyHWShadows = false;
        applyFilterMode = false;
        applyPCFEdge = false;
        applyShadowIntensity = false;
        applyFadeInfo = false;

        //At least one material of the receiving geoms does not support the post shadow techniques
        //so we fall back to the forced material solution (transparent shadows won't be supported for these objects)
        if (needsfallBackMaterial) {
            setPostShadowParams();
        }

    }
For debugging purpose Allow to "snapshot" the current frustum to the
scene
jme3-core/src/main/java/com/jme3/shadow/PssmShadowRenderer.java