Table of Contents

Class PlacementCameraUtils

Namespace
GridPlacement.GDScript
Assembly
MoonBark.GridPlacement.GDScript.dll

Camera and viewport projection utilities for world coordinate calculations.\n\nPure, static helpers used across systems (e.g., GridPositioner) and tests. These functions are deterministic and do not touch the scene tree beyond reading data from provided Camera2D/Viewport instances.

class PlacementCameraUtils extends RefCounted
PlacementCameraUtils

Fields

ProjectionMethod

Projection methods for screen to world conversion

const ProjectionMethod = PlacementEnums.ProjectionMethod

Properties

vp_rect

var vp_rect: Rect2 = cam.get_viewport_rect()

Methods

proj_method_to_string

static func proj_method_to_string(p_method: ProjectionMethod) -> String:

Parameters

p_method

Returns

get_center_of_camera_viewport

static func get_center_of_camera_viewport(cam : Camera2D) -> Vector2:

Parameters

cam

Returns