public function rasterize(SVGRasterizer $rasterizer) { if ($this->getComputedStyle('display') === 'none') { return; } $visibility = $this->getComputedStyle('visibility'); if ($visibility === 'hidden' || $visibility === 'collapse') { return; } $rasterizer->render('polygon', array('open' => false, 'points' => $this->getPoints()), $this); }
public function rasterize(SVGRasterizer $rasterizer) { if ($this->getComputedStyle('display') === 'none') { return; } $visibility = $this->getComputedStyle('visibility'); if ($visibility === 'hidden' || $visibility === 'collapse') { return; } $d = $this->getDescription(); if (!isset($d)) { return; } $commands = $rasterizer->getPathParser()->parse($d); $subpaths = $rasterizer->getPathApproximator()->approximate($commands); foreach ($subpaths as $subpath) { $rasterizer->render('polygon', array('open' => true, 'points' => $subpath), $this); } }
public function rasterize(SVGRasterizer $rasterizer) { if ($this->getComputedStyle('display') === 'none') { return; } $visibility = $this->getComputedStyle('visibility'); if ($visibility === 'hidden' || $visibility === 'collapse') { return; } $r = $this->getRadius(); $rasterizer->render('ellipse', array('cx' => $this->getCenterX(), 'cy' => $this->getCenterY(), 'rx' => $r, 'ry' => $r), $this); }
public function rasterize(SVGRasterizer $rasterizer) { if ($this->getComputedStyle('display') === 'none') { return; } $visibility = $this->getComputedStyle('visibility'); if ($visibility === 'hidden' || $visibility === 'collapse') { return; } $rasterizer->render('line', array('x1' => $this->getX1(), 'y1' => $this->getY1(), 'x2' => $this->getX2(), 'y2' => $this->getY2()), $this); }
public function rasterize(SVGRasterizer $rasterizer) { if ($this->getComputedStyle('display') === 'none') { return; } $visibility = $this->getComputedStyle('visibility'); if ($visibility === 'hidden' || $visibility === 'collapse') { return; } $rasterizer->render('rect', array('x' => $this->getX(), 'y' => $this->getY(), 'width' => $this->getWidth(), 'height' => $this->getHeight()), $this); }