Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

This script shows how to use the Multilight API through scripting.
It opens an MXI file, parses all the lights and changes their intensity to 500 Watts

Example
// This script shows how to use the Multilight API through scripting
// It opens an MXI file, parses all the lights and changes their intensity to 500 Watts

Maxwell.openMxi( "C:\multilight_test.mxi" );
var nLights = Multilight.getLightsCount();
for( var i = 0; i < nLights; i++ )
{
   if( Multilight.isLightMuted( i ) == false )
   {
      Multilight.setLightEmissionType( i, 0 ); // Custom emitter
      Multilight.setLightLuminanceType( i, 0 ); // Watts
      Multilight.setLightIntensity( i, 500 );
   }
}

Multilight.refreshAllLights(); // Upload viewers

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////



  • No labels