added runtime assert to prevent dangerous simplex to simplex assignment in the case of OCF optional attributes.
This commit is contained in:
parent
8465fa432c
commit
3b152298cc
|
@ -731,6 +731,13 @@ template <class T> class WedgeNormal3dOcf: public WedgeNormalOcf<vcg::Point3d, T
|
|||
|
||||
template < class T> class InfoOcf: public T {
|
||||
public:
|
||||
// You should never ever try to copy a vertex that has OCF stuff.
|
||||
// use ImportLocal function.
|
||||
inline InfoOcf &operator=(const InfoOcf &other) {
|
||||
assert(0); return *this;
|
||||
}
|
||||
|
||||
|
||||
vector_ocf<typename T::FaceType> &Base() const { return *_ovp;}
|
||||
|
||||
template <class LeftF>
|
||||
|
|
|
@ -638,7 +638,13 @@ template <class T> class RadiusdOcf: public RadiusOcf<double, T> {};
|
|||
|
||||
template < class T> class InfoOcf: public T {
|
||||
public:
|
||||
vector_ocf<typename T::VertType> &Base() const { return *_ovp;}
|
||||
// You should never ever try to copy a vertex that has OCF stuff.
|
||||
// use ImportLocal function.
|
||||
inline InfoOcf &operator=(const InfoOcf &other) {
|
||||
assert(0); return *this;
|
||||
}
|
||||
|
||||
vector_ocf<typename T::VertType> &Base() const { return *_ovp;}
|
||||
|
||||
inline int Index() const {
|
||||
typename T::VertType const *tp=static_cast<typename T::VertType const*>(this);
|
||||
|
|
Loading…
Reference in New Issue