STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Types | Public Member Functions | Static Public Attributes | Private Attributes | Static Private Attributes | List of all members
Concurrency::graphics::double_2 Class Reference

Represent a short vector of 2 doubles. More...

#include <amp_short_vectors.h>

Public Types

typedef double value_type
 

Public Member Functions

 __declspec (property(get=get_x, put=set_x)) double x
 Property for accessing element 0 of this double_2 as a double. More...
 
 __declspec (property(get=get_x, put=set_x)) double r
 Property for accessing element 0 of this double_2 as a double. More...
 
double get_x () const __GPU
 Returns element 0 of this double_2. More...
 
double & ref_x () __GPU
 Returns reference to element 0 of this double_2. More...
 
double & ref_r () __GPU
 Returns reference to element 0 of this double_2. More...
 
void set_x (double _Value) __GPU
 Set element 0 of this double_2 with a double. More...
 
 __declspec (property(get=get_y, put=set_y)) double y
 Property for accessing element 1 of this double_2 as a double. More...
 
 __declspec (property(get=get_y, put=set_y)) double g
 Property for accessing element 1 of this double_2 as a double. More...
 
double get_y () const __GPU
 Returns element 1 of this double_2. More...
 
double & ref_y () __GPU
 Returns reference to element 1 of this double_2. More...
 
double & ref_g () __GPU
 Returns reference to element 1 of this double_2. More...
 
void set_y (double _Value) __GPU
 Set element 1 of this double_2 with a double. More...
 
 double_2 () __GPU
 Default constructor, initializes all elements with 0. More...
 
 double_2 (double _V0, double _V1) __GPU
 Constructor. More...
 
 double_2 (double _V) __GPU
 Constructor. More...
 
 double_2 (const uint_2 &_Other) __GPU
 Constructor. Each element is initialized by casting from the corresponding element in _Other. More...
 
 double_2 (const int_2 &_Other) __GPU
 Constructor. Each element is initialized by casting from the corresponding element in _Other. More...
 
 double_2 (const float_2 &_Other) __GPU
 Constructor. Each element is initialized by casting from the corresponding element in _Other. More...
 
 double_2 (const unorm_2 &_Other) __GPU
 Constructor. Each element is initialized by casting from the corresponding element in _Other. More...
 
 double_2 (const norm_2 &_Other) __GPU
 Constructor. Each element is initialized by casting from the corresponding element in _Other. More...
 
double_2 operator- () const __GPU
 
double_2operator++ () __GPU
 
double_2 operator++ (int) __GPU
 
double_2operator-- () __GPU
 
double_2 operator-- (int) __GPU
 
double_2operator+= (const double_2 &_Other) __GPU
 
double_2operator-= (const double_2 &_Other) __GPU
 
double_2operator*= (const double_2 &_Other) __GPU
 
double_2operator/= (const double_2 &_Other) __GPU
 
 __declspec (property(get=get_xy, put=set_xy)) double_2 xy
 Property for accessing element 0, and 1 of this double_2 as a double_2. More...
 
 __declspec (property(get=get_xy, put=set_xy)) double_2 rg
 Property for accessing element 0, and 1 of this double_2 as a double_2. More...
 
double_2 get_xy () const __GPU
 Returns a double_2 that is composed of element 0, and element 1 of this double_2. More...
 
void set_xy (const double_2 &_Value) __GPU
 Set element 0, and 1 of this double_2 with a double_2. More...
 
 __declspec (property(get=get_yx, put=set_yx)) double_2 yx
 Property for accessing element 1, and 0 of this double_2 as a double_2. More...
 
 __declspec (property(get=get_yx, put=set_yx)) double_2 gr
 Property for accessing element 1, and 0 of this double_2 as a double_2. More...
 
double_2 get_yx () const __GPU
 Returns a double_2 that is composed of element 1, and element 0 of this double_2. More...
 
void set_yx (const double_2 &_Value) __GPU
 Set element 1, and 0 of this double_2 with a double_2. More...
 

Static Public Attributes

static const int size = 2
 

Private Attributes

value_type _M_x
 
value_type _M_y
 

Static Private Attributes

static const _Short_vector_base_type_id _Base_type_id = _Double_type
 

Detailed Description

Represent a short vector of 2 doubles.

Member Typedef Documentation

Constructor & Destructor Documentation

Concurrency::graphics::double_2::double_2 ( )
inline

Default constructor, initializes all elements with 0.

18707  {
18708  _M_x = 0;
18709  _M_y = 0;
18710  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
Concurrency::graphics::double_2::double_2 ( double  _V0,
double  _V1 
)
inline

Constructor.

Parameters
_V0The value to initialize element 0.
_V1The value to initialize element 1.
18722  {
18723  _M_x = _V0;
18724  _M_y = _V1;
18725  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
Concurrency::graphics::double_2::double_2 ( double  _V)
inline

Constructor.

Parameters
_VThe value for initialization.
18734  {
18735  _M_x = _V;
18736  _M_y = _V;
18737  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
Concurrency::graphics::double_2::double_2 ( const uint_2 _Other)
inlineexplicit

Constructor. Each element is initialized by casting from the corresponding element in _Other.

Parameters
_OtherThe object used to initialize.
22673  {
22674  uint_2 _Value = _Other;
22675  _M_x = static_cast<value_type>(_Value.x);
22676  _M_y = static_cast<value_type>(_Value.y);
22677  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double value_type
Definition: amp_short_vectors.h:18593
Concurrency::graphics::double_2::double_2 ( const int_2 _Other)
inlineexplicit

Constructor. Each element is initialized by casting from the corresponding element in _Other.

Parameters
_OtherThe object used to initialize.
22680  {
22681  int_2 _Value = _Other;
22682  _M_x = static_cast<value_type>(_Value.x);
22683  _M_y = static_cast<value_type>(_Value.y);
22684  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double value_type
Definition: amp_short_vectors.h:18593
Concurrency::graphics::double_2::double_2 ( const float_2 _Other)
inlineexplicit

Constructor. Each element is initialized by casting from the corresponding element in _Other.

Parameters
_OtherThe object used to initialize.
22687  {
22688  float_2 _Value = _Other;
22689  _M_x = static_cast<value_type>(_Value.x);
22690  _M_y = static_cast<value_type>(_Value.y);
22691  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double value_type
Definition: amp_short_vectors.h:18593
Concurrency::graphics::double_2::double_2 ( const unorm_2 _Other)
inlineexplicit

Constructor. Each element is initialized by casting from the corresponding element in _Other.

Parameters
_OtherThe object used to initialize.
22694  {
22695  unorm_2 _Value = _Other;
22696  _M_x = static_cast<value_type>(_Value.x);
22697  _M_y = static_cast<value_type>(_Value.y);
22698  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double value_type
Definition: amp_short_vectors.h:18593
Concurrency::graphics::double_2::double_2 ( const norm_2 _Other)
inlineexplicit

Constructor. Each element is initialized by casting from the corresponding element in _Other.

Parameters
_OtherThe object used to initialize.
22701  {
22702  norm_2 _Value = _Other;
22703  _M_x = static_cast<value_type>(_Value.x);
22704  _M_y = static_cast<value_type>(_Value.y);
22705  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double value_type
Definition: amp_short_vectors.h:18593

Member Function Documentation

Concurrency::graphics::double_2::__declspec ( property(get=get_x, put=set_x )

Property for accessing element 0 of this double_2 as a double.

Concurrency::graphics::double_2::__declspec ( property(get=get_x, put=set_x )

Property for accessing element 0 of this double_2 as a double.

Concurrency::graphics::double_2::__declspec ( property(get=get_y, put=set_y )

Property for accessing element 1 of this double_2 as a double.

Concurrency::graphics::double_2::__declspec ( property(get=get_y, put=set_y )

Property for accessing element 1 of this double_2 as a double.

Concurrency::graphics::double_2::__declspec ( property(get=get_xy, put=set_xy )

Property for accessing element 0, and 1 of this double_2 as a double_2.

Concurrency::graphics::double_2::__declspec ( property(get=get_xy, put=set_xy )

Property for accessing element 0, and 1 of this double_2 as a double_2.

Concurrency::graphics::double_2::__declspec ( property(get=get_yx, put=set_yx )

Property for accessing element 1, and 0 of this double_2 as a double_2.

Concurrency::graphics::double_2::__declspec ( property(get=get_yx, put=set_yx )

Property for accessing element 1, and 0 of this double_2 as a double_2.

double Concurrency::graphics::double_2::get_x ( ) const
inline

Returns element 0 of this double_2.

Returns
Element 0 of this double_2.
18617  {
18618  return _M_x;
18619  }
value_type _M_x
Definition: amp_short_vectors.h:18598
double_2 Concurrency::graphics::double_2::get_xy ( ) const
inline

Returns a double_2 that is composed of element 0, and element 1 of this double_2.

Returns
a double_2.
18878  {
18879  return double_2(_M_x, _M_y);
18880  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double Concurrency::graphics::double_2::get_y ( ) const
inline

Returns element 1 of this double_2.

Returns
Element 1 of this double_2.
18667  {
18668  return _M_y;
18669  }
value_type _M_y
Definition: amp_short_vectors.h:18599
double_2 Concurrency::graphics::double_2::get_yx ( ) const
inline

Returns a double_2 that is composed of element 1, and element 0 of this double_2.

Returns
a double_2.
18910  {
18911  return double_2(_M_y, _M_x);
18912  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2& Concurrency::graphics::double_2::operator*= ( const double_2 _Other)
inline
18843  {
18844  double_2 _Value1 = *this;
18845  double_2 _Value2 = _Other;
18846  _Value1.x *= _Value2.x;
18847  _Value1.y *= _Value2.y;
18848  *this = _Value1;
18849  return *this;
18850  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2& Concurrency::graphics::double_2::operator++ ( )
inline
18791  {
18792  double_2 _Value = *this;
18793  ++_Value._M_x;
18794  ++_Value._M_y;
18795  *this = _Value;
18796  return *this;
18797  }
_In_ _Value
Definition: corecrt_wstdlib.h:65
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2 Concurrency::graphics::double_2::operator++ ( int  )
inline
18800  {
18801  double_2 _Result = *this;
18802  ++(*this);
18803  return _Result;
18804  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
_Result
Definition: corecrt_wconio.h:362
double_2& Concurrency::graphics::double_2::operator+= ( const double_2 _Other)
inline
18823  {
18824  double_2 _Value1 = *this;
18825  double_2 _Value2 = _Other;
18826  _Value1.x += _Value2.x;
18827  _Value1.y += _Value2.y;
18828  *this = _Value1;
18829  return *this;
18830  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2 Concurrency::graphics::double_2::operator- ( void  ) const
inline
18785  {
18786  double_2 _Value = *this;
18787  return double_2(-_Value.x, -_Value.y);
18788  }
_In_ _Value
Definition: corecrt_wstdlib.h:65
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2& Concurrency::graphics::double_2::operator-- ( )
inline
18807  {
18808  double_2 _Value = *this;
18809  --_Value._M_x;
18810  --_Value._M_y;
18811  *this = _Value;
18812  return *this;
18813  }
_In_ _Value
Definition: corecrt_wstdlib.h:65
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2 Concurrency::graphics::double_2::operator-- ( int  )
inline
18816  {
18817  double_2 _Result = *this;
18818  --(*this);
18819  return _Result;
18820  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
_Result
Definition: corecrt_wconio.h:362
double_2& Concurrency::graphics::double_2::operator-= ( const double_2 _Other)
inline
18833  {
18834  double_2 _Value1 = *this;
18835  double_2 _Value2 = _Other;
18836  _Value1.x -= _Value2.x;
18837  _Value1.y -= _Value2.y;
18838  *this = _Value1;
18839  return *this;
18840  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double_2& Concurrency::graphics::double_2::operator/= ( const double_2 _Other)
inline
18853  {
18854  double_2 _Value1 = *this;
18855  double_2 _Value2 = _Other;
18856  _Value1.x /= _Value2.x;
18857  _Value1.y /= _Value2.y;
18858  *this = _Value1;
18859  return *this;
18860  }
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
double& Concurrency::graphics::double_2::ref_g ( )
inline

Returns reference to element 1 of this double_2.

Returns
Reference to element 1 of this double_2.
18687  {
18688  return _M_y;
18689  }
value_type _M_y
Definition: amp_short_vectors.h:18599
double& Concurrency::graphics::double_2::ref_r ( )
inline

Returns reference to element 0 of this double_2.

Returns
Reference to element 0 of this double_2.
18637  {
18638  return _M_x;
18639  }
value_type _M_x
Definition: amp_short_vectors.h:18598
double& Concurrency::graphics::double_2::ref_x ( )
inline

Returns reference to element 0 of this double_2.

Returns
Reference to element 0 of this double_2.
18627  {
18628  return _M_x;
18629  }
value_type _M_x
Definition: amp_short_vectors.h:18598
double& Concurrency::graphics::double_2::ref_y ( )
inline

Returns reference to element 1 of this double_2.

Returns
Reference to element 1 of this double_2.
18677  {
18678  return _M_y;
18679  }
value_type _M_y
Definition: amp_short_vectors.h:18599
void Concurrency::graphics::double_2::set_x ( double  _Value)
inline

Set element 0 of this double_2 with a double.

Parameters
_Valuea double value.
18648  {
18649  _M_x = _Value;
18650  }
value_type _M_x
Definition: amp_short_vectors.h:18598
_In_ _Value
Definition: corecrt_wstdlib.h:65
void Concurrency::graphics::double_2::set_xy ( const double_2 _Value)
inline

Set element 0, and 1 of this double_2 with a double_2.

Parameters
_Valuea double_2 value.
18889  {
18890  double_2 _Val = _Value;
18891  _M_x = _Val.x;
18892  _M_y = _Val.y;
18893  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
_FwdIt const _Ty _Val
Definition: algorithm:1938
void Concurrency::graphics::double_2::set_y ( double  _Value)
inline

Set element 1 of this double_2 with a double.

Parameters
_Valuea double value.
18698  {
18699  _M_y = _Value;
18700  }
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
void Concurrency::graphics::double_2::set_yx ( const double_2 _Value)
inline

Set element 1, and 0 of this double_2 with a double_2.

Parameters
_Valuea double_2 value.
18921  {
18922  double_2 _Val = _Value;
18923  _M_y = _Val.x;
18924  _M_x = _Val.y;
18925  }
value_type _M_x
Definition: amp_short_vectors.h:18598
value_type _M_y
Definition: amp_short_vectors.h:18599
_In_ _Value
Definition: corecrt_wstdlib.h:65
double_2() __GPU
Default constructor, initializes all elements with 0.
Definition: amp_short_vectors.h:18706
_FwdIt const _Ty _Val
Definition: algorithm:1938

Member Data Documentation

const _Short_vector_base_type_id Concurrency::graphics::double_2::_Base_type_id = _Double_type
staticprivate
value_type Concurrency::graphics::double_2::_M_x
private
value_type Concurrency::graphics::double_2::_M_y
private
const int Concurrency::graphics::double_2::size = 2
static

The documentation for this class was generated from the following file: