yuanjiajia
3 years ago
5 changed files with 38 additions and 66 deletions
-
14examples/print.php
-
11src/scene/BaseCfg.php
-
13src/scene/Film.php
-
24src/scene/file/ImageSaver.php
-
36src/scene/file/ImageSaverNumber.php
@ -1,36 +0,0 @@ |
|||
<?php |
|||
|
|||
namespace Blobt\Luxcore\scene\file; |
|||
use Blobt\Luxcore\core\Base; |
|||
|
|||
class ImageSaverNumber extends ImageSaverBase |
|||
{ |
|||
/** |
|||
* @var integer 图像输出序号,当一幅图像需要管线处理时,处理管线依据此参数处理对应的图像(取值大于0的整数) |
|||
*/ |
|||
public $index = 0; |
|||
|
|||
/** |
|||
* 设置默认的图像输出文件名及格式 |
|||
*/ |
|||
public function __construct($config = []) |
|||
{ |
|||
|
|||
Base::__construct($config); |
|||
if( in_array($this->type,self::PNG ) ) |
|||
{ |
|||
$this->filename = "{$this->type}_{$this->index}.png"; |
|||
} |
|||
else if ( in_array($this->type,self::EXR) ) |
|||
{ |
|||
$this->filename = "{$this->type}_{$this->index}.exr"; |
|||
} |
|||
else |
|||
{ |
|||
$this->filename = "{$this->type}_{$this->index}.jpg"; |
|||
} |
|||
|
|||
} |
|||
} |
|||
|
|||
?>
|
Write
Preview
Loading…
Cancel
Save
Reference in new issue