Render: getFocalLength

getFocalLength()
  • Returns the optimal focusing distance in stereo mode.  (3D glasses)

Return Type: 

  • float number
Note:
  • By default stereo mode is turned off. 
     
  • Properties >> Render button >> Stereo tab >> Stereo
Sample Code

################  get the focal length in Stereo mode

# import bge module
import bge

# get the render module
rend = bge.render

# get the focal length
focus = rend.getFocalLength()