self:get_fov
Client
Retrieves the camera's field of view
Syntax
local result = self:get_fov()Only applicable in perspective projection mode. Refer core.camera.set_projection to configure the active projection mode.
- Perspective mode required — calling this function in any other projection mode will have no effect.
- Recommended usage — combine with
core.camera.projection.PERSPECTIVEto switch projection before adjusting FOV.
Parameters
| No parameters are accepted by this function |
|---|
Returns
| Type | Name | Description |
|---|---|---|
float | result | Current field of view in degrees |
Examples
local entity = core.camera.create()
core.engine.print("info", entity:get_fov())