Link Search Menu Expand Document

Class OGLSpotLight

About :

	A spot Light as a position and can be oriented
Class diagram of class of OGLSpotLight.

Functions

Function summury
__init__(self, key=None)  
attach_to_camera(self, attach=True)  
is_attached_to_camera(self)  
set_position(self, x, y, z) Set position (more…)
set_spot(self, direction=(0, 0, -1), cutoff=180, exponent=0) Set spot paramaters when light is also directed (more…)
set_attenuation(self, constant=0.1, linear=0.05, quadratic=0) Set attenuation (more…)
__str__(self) To string translator (more…)

Methods desciption :

init

def __init__(self, key=None)

attach_to_camera

def attach_to_camera(self, attach=True)

is_attached_to_camera

def is_attached_to_camera(self)

set_position

def set_position(self, x, y, z)

Set position

  • → x,y,z : coordinates

set_spot

def set_spot(self, direction=(0, 0, -1), cutoff=180, exponent=0)

Set spot paramaters when light is also directed

  • → direction
  • → cutoff : angle of ligthing in degrees
  • → exponent : powerness

set_attenuation

def set_attenuation(self, constant=0.1, linear=0.05, quadratic=0)

Set attenuation

  • → constant
  • → linear
  • → quadratic

str

def __str__(self)

To string translator