Browse Source

新增两个类文件“ImageSaverBase.php”、“ImageSaverNumber.php”

master
yuanjiajia 3 years ago
parent
commit
938d8db8ac
  1. 21
      src/scene/ImageSaver.php
  2. 65
      src/scene/ImageSaverBase.php
  3. 11
      src/scene/ImageSaverNumber.php

21
src/scene/ImageSaver.php

@ -1,21 +0,0 @@
<?php
namespace Blobt\Luxcore\scene;
class ImageSaver extends BaseCfg
{
const TYPE_PATHCPU = 'PATHCPU';
const TYPE_PATHGPU = 'PATHGPU';
/**
* @var string 使用何种渲染引擎(可取值是 PATHCPU、PATHGPU、BIDIRCPU 三个字符串之一)
*/
public $type = self::TYPE_PATHGPU;
/**
* @var float 随机种子(取值:大于0的整数)
*/
public $filename = "RGB_IMAGEPIPELINE_0.png";
}

65
src/scene/ImageSaverBase.php

@ -0,0 +1,65 @@
<?php
namespace Blobt\Luxcore\scene;
class ImageSaverBase extends BaseCfg
{
/**
* 序列输出,根据需要的效果,进行相应的管线处理。文件保存格式:png
*/
const TYPE_RGB_IMAGEPIPELINE = 'RGB_IMAGEPIPELINE';
/**
* material\object informatin(材质或模型ID信息),不需要管线处理,文件保存格式:png
*/
const TYPE_MATERIAL_ID = 'MATERIAL_ID';
const TYPE_OBJECT_ID = 'OBJECT_ID';
const TYPE_MATERIAL_ID_COLOR = 'MATERIAL_ID_COLOR';
/**
* shadow mask(阴影遮罩),不需要管线处理,文件保存格式:png
*/
const TYPE_DIRECT_SHADOW_MASK = 'DIRECT_SHADOW_MASK';
const TYPE_INDIRECT_SHADOW_MASK = 'INDIRECT_SHADOW_MASK';
/**
* Basic informatin(基本信息)不需要管线处理,文件保存格式:exr
*/
const TYPE_ALBEDO = 'ALBEDO';
const TYPE_RGB = 'RGB';
const TYPE_DEPTH = 'DEPTH';
const TYPE_RGBA = 'RGBA';
const TYPE_ALPHA = 'ALPHA';
/**
* geometry information(几何图形信息),不需要管线处理,文件保存格式:exr
*/
const TYPE_POSITION = 'POSITION';
const TYPE_GEOMETRY_NORMAL = 'GEOMETRY_NORMAL';
const TYPE_SHADING_NORMAL = 'SHADING_NORMAL';
const TYPE_UV = 'UV';
const TYPE_AVG_SHADING_NORMAL = 'AVG_SHADING_NORMAL';
/**
* Render information(渲染信息),不需要管线处理,文件保存格式:exr
*/
const TYPE_IRRADIANCE = 'IRRADIANCE';
const TYPE_RAYCOUNT = 'RAYCOUNT';
const TYPE_SAMPLECOUNT = 'SAMPLECOUNT';
const TYPE_CONVERGENCE = 'CONVERGENCE';
const TYPE_NOISE = 'NOISE';
/**
* @var string 使用何种渲染引擎(可取值是 PATHCPU、PATHGPU、BIDIRCPU 三个字符串之一)
*/
public $type = self::TYPE_RGB_IMAGEPIPELINE;
/**
* @var float 随机种子(取值:大于0的整数)
*/
public $filename = self::TYPE_RGB_IMAGEPIPELINE."png";
}

11
src/scene/ImageSaverNumber.php

@ -0,0 +1,11 @@
<?php
namespace Blobt\Luxcore\scene;
class ImageSaverNumber extends ImageSaverBase
{
/**
* @var integer 图像输出序号,当一幅图像需要管线处理时,处理管线依据此参数处理对应的图像(取值大于0的整数)
*/
public $index = 0;
}
Loading…
Cancel
Save