set_scene_3d_light_paramT_set_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_param (算子)

名称

set_scene_3d_light_paramT_set_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_param — 设置三维场景中光源的参数。

签名

set_scene_3d_light_param( : : Scene3D, LightIndex, GenParamName, GenParamValue : )

Herror T_set_scene_3d_light_param(const Htuple Scene3D, const Htuple LightIndex, const Htuple GenParamName, const Htuple GenParamValue)

void SetScene3dLightParam(const HTuple& Scene3D, const HTuple& LightIndex, const HTuple& GenParamName, const HTuple& GenParamValue)

void HScene3D::SetScene3dLightParam(Hlong LightIndex, const HTuple& GenParamName, const HTuple& GenParamValue) const

void HScene3D::SetScene3dLightParam(Hlong LightIndex, const HString& GenParamName, const HString& GenParamValue) const

void HScene3D::SetScene3dLightParam(Hlong LightIndex, const char* GenParamName, const char* GenParamValue) const

void HScene3D::SetScene3dLightParam(Hlong LightIndex, const wchar_t* GenParamName, const wchar_t* GenParamValue) const   ( Windows only)

static void HOperatorSet.SetScene3dLightParam(HTuple scene3D, HTuple lightIndex, HTuple genParamName, HTuple genParamValue)

void HScene3D.SetScene3dLightParam(int lightIndex, HTuple genParamName, HTuple genParamValue)

void HScene3D.SetScene3dLightParam(int lightIndex, string genParamName, string genParamValue)

def set_scene_3d_light_param(scene_3d: HHandle, light_index: int, gen_param_name: MaybeSequence[str], gen_param_value: MaybeSequence[Union[str, int, float]]) -> None

描述

set_scene_3d_light_paramset_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_param sets parameters of a light source in the 3D scene Scene3DScene3DScene3DScene3Dscene3Dscene_3d. The name and value of a parameter must be given in GenParamNameGenParamNameGenParamNameGenParamNamegenParamNamegen_param_name and GenParamValueGenParamValueGenParamValueGenParamValuegenParamValuegen_param_value. The following parameters can be set:

'ambient'"ambient""ambient""ambient""ambient""ambient"

Ambient part of the light source. Must be given as a tuple of three numbers.

Default: [0.2, 0.2, 0.2]

'diffuse'"diffuse""diffuse""diffuse""diffuse""diffuse"

Diffuse part of the light source. Must be given as a tuple of three numbers.

Default: [0.8, 0.8, 0.8]

执行信息

参数

Scene3DScene3DScene3DScene3Dscene3Dscene_3d (输入控制)  scene_3d HScene3D, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

3D 场景的句柄。

LightIndexLightIndexLightIndexLightIndexlightIndexlight_index (输入控制)  integer HTupleintHTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Index of the light source.

GenParamNameGenParamNameGenParamNameGenParamNamegenParamNamegen_param_name (输入控制)  string(-array) HTupleMaybeSequence[str]HTupleHtuple (string) (string) (HString) (char*)

通用参数的名称。

默认值: 'ambient' "ambient" "ambient" "ambient" "ambient" "ambient"

值列表: 'ambient'"ambient""ambient""ambient""ambient""ambient", 'diffuse'"diffuse""diffuse""diffuse""diffuse""diffuse"

GenParamValueGenParamValueGenParamValueGenParamValuegenParamValuegen_param_value (输入控制)  string(-array) HTupleMaybeSequence[Union[str, int, float]]HTupleHtuple (string / integer / real) (string / int / long / double) (HString / Hlong / double) (char* / Hlong / double)

通用参数的值。

默认值: [0.2,0.2,0.2]

建议值: [0.2,0.2,0.2]

结果

set_scene_3d_light_paramset_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_param 在所有参数正确时返回 2 ( H_MSG_TRUE )。如有必要,则抛出异常。

可能的前趋

add_scene_3d_instanceadd_scene_3d_instanceAddScene3dInstanceAddScene3dInstanceAddScene3dInstanceadd_scene_3d_instance

模块

三维计量