clipElement.setId("ext-clip-" + ++clipId);
clipPath.setAttribute("x", String.valueOf(rect.getX()));
clipPath.setAttribute("y", String.valueOf(rect.getY()));
clipPath.setAttribute("width", String.valueOf(rect.getWidth()));
clipPath.setAttribute("height", String.valueOf(rect.getHeight()));
clipElement.appendChild(clipPath);
getDefinitions().appendChild(clipElement);
getElement(sprite).setAttribute("clip-path", "url(#" + clipElement.getId() + ")");
setClipElement(sprite, clipPath);
}