src/Rasterization/Renderers/SVGRenderer.php
private static function calculateTotalOpacity(SVGNode $node)
    {
        $opacity = self::getNodeOpacity($node);

        $parent  = $node->getParent();
        if (isset($parent)) {
            return $opacity * self::calculateTotalOpacity($parent);
        }

        return $opacity;
    }
private static function calculateTotalOpacity(SVGNode $node)
    {
        $opacity = self::getNodeOpacity($node);

        $parent  = $node->getParent();
        if (isset($parent)) {
            return $opacity * self::calculateTotalOpacity($parent);
        }

        return $opacity;
    }
private static function calculateTotalOpacity ( SVGNode $ node ) { $ opacity = self :: getNodeOpacity ( $ node ) ; $ parent = $ node -> getParent ( ) ; if ( isset ( $ parent ) ) { return $ opacity * self :: calculateTotalOpacity ( $ parent ) ; } return $ opacity ; }
Calculates the node's total opacity by multiplying its own with all of
its parents' ones.

@param SVGNode $node The node of which to calculate the opacity.

@return float The node's total opacity.
Calculates the node s total opacity by multiplying its own with all of its parents ones .