Panda3D
Public Member Functions | Static Public Member Functions

LVector2d Class Reference

This is a two-component vector offset. More...

#include "lvector2.h"

Inheritance diagram for LVector2d:
LVecBase2d

List of all members.

Public Member Functions

 LVector2d (const LVecBase2d &copy)
 LVector2d (double fill_value)
 LVector2d (double x, double y)
LVector2d operator* (double scalar) const
LVecBase2d operator+ (const LVecBase2d &other) const
LVector2d operator+ (const LVector2d &other) const
LVector2d operator- (const LVector2d &other) const
LVecBase2d operator- (const LVecBase2d &other) const
LVector2d operator- () const
LVector2d operator/ (double scalar) const
LVector2doperator= (const LVecBase2d &copy)
LVector2doperator= (double fill_value)
LVector2d project (const LVecBase2d &onto) const
 Returns a new vector representing the projection of this vector onto another one.
double signed_angle_deg (const LVector2d &other) const
 returns the signed angled between two vectors.
double signed_angle_rad (const LVector2d &other) const
 returns the signed angled between two vectors.

Static Public Member Functions

static TypeHandle get_class_type ()
static void init_type ()
static const LVector2dunit_x ()
 Returns a unit X vector.
static const LVector2dunit_y ()
 Returns a unit Y vector.
static const LVector2dzero ()
 Returns a zero-length vector.

Detailed Description

This is a two-component vector offset.

Definition at line 403 of file lvector2.h.


Member Function Documentation

LVector2d LVector2d::project ( const LVecBase2d onto) const [inline]

Returns a new vector representing the projection of this vector onto another one.

The resulting vector will be a scalar multiple of onto.

Reimplemented from LVecBase2d.

Definition at line 631 of file lvector2.h.

double LVector2d::signed_angle_deg ( const LVector2d other) const [inline]

returns the signed angled between two vectors.

normalization is NOT necessary

Definition at line 653 of file lvector2.h.

double LVector2d::signed_angle_rad ( const LVector2d other) const [inline]

returns the signed angled between two vectors.

normalization is NOT necessary

Definition at line 642 of file lvector2.h.

const LVector2d & LVector2d::unit_x ( ) [inline, static]

Returns a unit X vector.

Reimplemented from LVecBase2d.

Definition at line 538 of file lvector2.h.

const LVector2d & LVector2d::unit_y ( ) [inline, static]

Returns a unit Y vector.

Reimplemented from LVecBase2d.

Definition at line 548 of file lvector2.h.

const LVector2d & LVector2d::zero ( ) [inline, static]

Returns a zero-length vector.

Reimplemented from LVecBase2d.

Definition at line 528 of file lvector2.h.

Referenced by EggTransform::get_component_vec2().


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations