Phaser API Documentation

  Version: 
getBounds([out])

Description:

Returns a rectangle containing the bounds of the Camera.

If the Camera does not have any bounds the rectangle will be empty.

The rectangle is a copy of the bounds, so is safe to modify.

Parameters:

name type arguments description
out Phaser.Geom.Rectangle <optional>

An optional Rectangle to store the bounds in. If not given, a new Rectangle will be created.

Returns:
Description:

A rectangle containing the bounds of this Camera.

Since: 3.16.0