PIRect complete
This commit is contained in:
@@ -38,11 +38,25 @@ template<typename Type>
|
||||
class PIP_EXPORT PILine {
|
||||
static_assert(std::is_arithmetic<Type>::value, "Type must be arithmetic");
|
||||
public:
|
||||
PIPoint p0;
|
||||
PIPoint p1;
|
||||
PIPoint<Type> p0;
|
||||
PIPoint<Type> p1;
|
||||
|
||||
PILine() {}
|
||||
|
||||
PILine(const PIPoint<Type> & p0_, const PIPoint<Type> & p1_) {
|
||||
p0 = p0_;
|
||||
p1 = p1_;
|
||||
}
|
||||
|
||||
bool isEmpty() const {
|
||||
return (p0 == p1);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
typedef PILine<int> PILinei;
|
||||
typedef PILine<uint> PILineu;
|
||||
typedef PILine<float> PILinef;
|
||||
typedef PILine<double> PILined;
|
||||
|
||||
#endif // PILINE_H
|
||||
|
||||
Reference in New Issue
Block a user