Flutter Engine
The Flutter Engine
Classes | Namespaces | Macros | Typedefs | Functions
point.h File Reference
#include <algorithm>
#include <cmath>
#include <cstdint>
#include <ostream>
#include <string>
#include <type_traits>
#include "impeller/geometry/scalar.h"
#include "impeller/geometry/size.h"
#include "impeller/geometry/type_traits.h"

Go to the source code of this file.

Classes

struct  impeller::TPoint< T >
 

Namespaces

namespace  impeller
 
namespace  std
 

Macros

#define ONLY_ON_FLOAT_M(Modifiers, Return)
 
#define ONLY_ON_FLOAT(Return)   DL_ONLY_ON_FLOAT_M(, Return)
 

Typedefs

using impeller::Point = TPoint< Scalar >
 
using impeller::IPoint = TPoint< int64_t >
 
using impeller::IPoint32 = TPoint< int32_t >
 
using impeller::UintPoint32 = TPoint< uint32_t >
 
using impeller::Vector2 = Point
 
using impeller::Quad = std::array< Point, 4 >
 

Functions

template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator+ (const TPoint< F > &p1, const TPoint< I > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator+ (const TPoint< I > &p1, const TPoint< F > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator- (const TPoint< F > &p1, const TPoint< I > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator- (const TPoint< I > &p1, const TPoint< F > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator* (const TPoint< F > &p1, const TPoint< I > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator* (const TPoint< I > &p1, const TPoint< F > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator/ (const TPoint< F > &p1, const TPoint< I > &p2)
 
template<class F , class I , class = MixedOp<F, I>>
constexpr TPoint< Fimpeller::operator/ (const TPoint< I > &p1, const TPoint< F > &p2)
 
template<class T , class U , class = std::enable_if_t<std::is_arithmetic_v<U>>>
constexpr TPoint< Timpeller::operator* (U s, const TPoint< T > &p)
 
template<class T , class U , class = std::enable_if_t<std::is_arithmetic_v<U>>>
constexpr TPoint< Timpeller::operator/ (U s, const TPoint< T > &p)
 
template<class T , class U >
constexpr TPoint< Timpeller::operator+ (const TSize< U > &s, const TPoint< T > &p)
 
template<class T , class U >
constexpr TPoint< Timpeller::operator- (const TSize< U > &s, const TPoint< T > &p)
 
template<class T , class U >
constexpr TPoint< Timpeller::operator* (const TSize< U > &s, const TPoint< T > &p)
 
template<class T , class U >
constexpr TPoint< Timpeller::operator/ (const TSize< U > &s, const TPoint< T > &p)
 
template<class T >
std::ostream & std::operator<< (std::ostream &out, const impeller::TPoint< T > &p)
 

Macro Definition Documentation

◆ ONLY_ON_FLOAT

#define ONLY_ON_FLOAT (   Return)    DL_ONLY_ON_FLOAT_M(, Return)

Definition at line 24 of file point.h.

◆ ONLY_ON_FLOAT_M

#define ONLY_ON_FLOAT_M (   Modifiers,
  Return 
)
Value:
template <typename U = T> \
Modifiers std::enable_if_t<std::is_floating_point_v<U>, Return>

Definition at line 21 of file point.h.