# panda3d.core.LPoint3f¶

from panda3d.core import LPoint3f

class LPoint3f

Bases: LVecBase3f

This is a three-component point in space (as opposed to a three-component vector, which represents a direction and a distance). Some of the methods are slightly different between LPoint3 and LVector3; in particular, subtraction of two points yields a vector, while addition of a vector and a point yields a point.

Inheritance diagram

__init__() → None
__init__(param0: LPoint3f) → None
__init__(copy: LVecBase2f, z: float) → None
__init__(copy: LVecBase3f) → None
__init__(fill_value: float) → None
__init__(x: float, y: float, z: float) → None
static zero() → LPoint3f

Returns a zero-length point.

Return type

LPoint3f

static unitX() → LPoint3f

Returns a unit X point.

Return type

LPoint3f

static unitY() → LPoint3f

Returns a unit Y point.

Return type

LPoint3f

static unitZ() → LPoint3f

Returns a unit Z point.

Return type

LPoint3f

getXy() → LPoint2f

Returns a 2-component vector that shares just the first two components of this vector.

Return type

LPoint2f

getXz() → LPoint2f

Returns a 2-component vector that shares just the first and last components of this vector.

Return type

LPoint2f

getYz() → LPoint2f

Returns a 2-component vector that shares just the last two components of this vector.

Return type

LPoint2f

cross(other: LVecBase3f) → LPoint3f
Return type

LPoint3f

normalized() → LPoint3f

Normalizes the vector and returns the normalized vector as a copy. If the vector was a zero-length vector, a zero length vector will be returned.

Return type

LPoint3f

project(onto: LVecBase3f) → LPoint3f

Returns a new vector representing the projection of this vector onto another one. The resulting vector will be a scalar multiple of onto.

Return type

LPoint3f

static origin(cs: CoordinateSystem) → LPoint3f

Returns the origin of the indicated coordinate system. This is always 0, 0, 0 with all of our existing coordinate systems; it’s hard to imagine it ever being different.

Return type

LPoint3f

static rfu(right: float, fwd: float, up: float, cs: CoordinateSystem) → LPoint3f

Returns a point described by right, forward, up displacements from the origin, wherever that maps to in the given coordinate system.

Return type

LPoint3f

static getClassType() → TypeHandle
Return type

TypeHandle

property xy

Returns a 2-component vector that shares just the first two components of this vector.

Return type

LPoint2f

property xz

Returns a 2-component vector that shares just the first and last components of this vector.

Return type

LPoint2f

property yz

Returns a 2-component vector that shares just the last two components of this vector.

Return type

LPoint2f