Skip to content

set_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_paramT_set_scene_3d_light_param🔗

Short description🔗

set_scene_3d_light_paramSetScene3dLightParamSetScene3dLightParamset_scene_3d_light_paramT_set_scene_3d_light_param — Set parameters of a light in a 3D scene.

Signature🔗

set_scene_3d_light_param( scene_3d Scene3D, integer LightIndex, string GenParamName, string GenParamValue )void SetScene3dLightParam( const HTuple& Scene3D, const HTuple& LightIndex, const HTuple& GenParamName, const HTuple& GenParamValue )static void HOperatorSet.SetScene3dLightParam( HTuple scene3D, HTuple lightIndex, HTuple genParamName, HTuple 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

Herror T_set_scene_3d_light_param( 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)

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

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

Description🔗

set_scene_3d_light_paramSetScene3dLightParam sets parameters of a light source in the 3D scene Scene3Dscene3Dscene_3d. The name and value of a parameter must be given in GenParamNamegenParamNamegen_param_name and GenParamValuegenParamValuegen_param_value. The following parameters can be set:

  • 'ambient'"ambient": Ambient part of the light source. Must be given as a tuple of three numbers.

    Default: [0.2, 0.2, 0.2][0.2, 0.2, 0.2].

  • 'diffuse'"diffuse": Diffuse part of the light source. Must be given as a tuple of three numbers.

    Default: [0.8, 0.8, 0.8][0.8, 0.8, 0.8].

Execution information🔗

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

Parameters🔗

Scene3Dscene3Dscene_3d (input_control) scene_3d → (handle)HTuple (HHandle)HScene3D, HTuple (IntPtr)HHandleHtuple (handle)

Handle of the 3D scene.

LightIndexlightIndexlight_index (input_control) integer → (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)

Index of the light source.

GenParamNamegenParamNamegen_param_name (input_control) string(-array) → (string)HTuple (HString)HTuple (string)MaybeSequence[str]Htuple (char*)

Names of the generic parameters.

Default: 'ambient'"ambient"
List of values: 'ambient', 'diffuse'"ambient", "diffuse"

GenParamValuegenParamValuegen_param_value (input_control) string(-array) → (string / integer / real)HTuple (HString / Hlong / double)HTuple (string / int / long / double)MaybeSequence[Union[str, int, float]]Htuple (char* / Hlong / double)

Values of the generic parameters.

Default: [0.2, 0.2, 0.2][0.2, 0.2, 0.2]
Suggested values: [0.2, 0.2, 0.2][0.2, 0.2, 0.2]

Result🔗

set_scene_3d_light_paramSetScene3dLightParam returns 2 (H_MSG_TRUE) if all parameters are correct. If necessary, an exception is raised.

Combinations with other operators🔗

Combinations

Possible predecessors

add_scene_3d_instanceAddScene3dInstance

Module🔗

3D Metrology