4 require_once(
"./Services/Preview/classes/class.ilPreviewSettings.php");
23 $name = get_class($this);
25 if (strpos($name,
"il") === 0)
26 $name = substr($name, 2);
28 if (strpos($name,
"Renderer") === (strlen($name) - 8))
29 $name = substr($name, 0, strlen($name) - 8) .
" Renderer";
41 $filepath =
"./Services/Preview/classes/class." . get_class($this) .
".php";
42 return !is_file($filepath);
81 require_once(
"./Services/Preview/classes/class.ilRenderedImage.php");
85 if (is_array($images) && count($images) > 0)
88 foreach ($images as $idx => $image)
92 $image->getImagePath(),
93 sprintf(
$preview->getFilePathFormat(), $idx + 1));
96 if($image->isTemporary())
123 $resizeArg = $imgSize .
"x" . $imgSize . (
ilUtil::isWindows() ?
"^" :
"\\") .
">";
127 "%s -background white -flatten -resize %s -quality %d -sharpen 0x0.5 %s",
135 return is_file($dest_img_path);
getMaximumNumberOfPreviews()
Gets the maximum number of preview pictures per object.
static getImageQuality()
Gets the quality (compression) of the preview images (1-100).
createPreviewImage($src_img_path, $dest_img_path)
Creates a preview image path from the specified source image.
getName()
Gets the name of the renderer.
const RENDER_STATUS_FAILED
isPlugin()
Determines whether the renderer is a plugin or a built in one.
Abstract parent class for all preview renderer classes.
const RENDER_STATUS_PENDING
static now()
Return current timestamp in Y-m-d H:i:s format.
static isWindows()
check wether the current client system is a windows system
render($preview, $obj, $async)
Creates the preview of the specified preview object.
static execConvert($args)
execute convert command
supports($preview)
Determines whether the specified preview object is supported by the renderer.
static getMaximumPreviews()
Gets the maximum number of preview pictures per object.
const RENDER_STATUS_CREATED
static getImageSize()
Gets the size of the preview images in pixels.
static escapeShellArg($a_arg)
getSupportedRepositoryTypes()
Gets an array containing the repository types (e.g.
getImageSize()
Gets the size of the preview images in pixels.
renderImages($obj)
Renders the specified object into images.
getImageQuality()
Gets the quality (compression) of the preview images (1-100).