netgen/libsrc/stlgeom/vsstl.hpp
Stefan Brüns 54705bc572 Fix use of unitialized stlgeometry member in constructor
stlgeometry is a private member of VisualSceneSTLGeometry/Meshing, and
can't point to any valid geometry when the constructor runs, so remove
any dereferences there.

Remove the misleading extern declaration of netgen::stlgeometry.
2022-07-13 16:02:54 +02:00

54 lines
1.3 KiB
C++

#ifndef FILE_VSSTL
#define FILE_VSSTL
/**************************************************************************/
/* File: vsstl.hpp */
/* Author: Joachim Schoeberl */
/* Date: 05. Jan. 2011 */
/**************************************************************************/
namespace netgen
{
class NGGUI_API VisualSceneSTLGeometry : public VisualScene
{
NgArray<int> trilists;
class STLGeometry * stlgeometry = nullptr;
public:
VisualSceneSTLGeometry ();
virtual ~VisualSceneSTLGeometry ();
void SetGeometry (class STLGeometry * astlgeometry) { stlgeometry = astlgeometry; }
virtual void BuildScene (int zoomall = 0);
virtual void DrawScene ();
};
class NGGUI_API VisualSceneSTLMeshing : public VisualScene
{
NgArray<int> trilists;
int selecttrig, nodeofseltrig;
class STLGeometry * stlgeometry = nullptr;
public:
VisualSceneSTLMeshing ();
virtual ~VisualSceneSTLMeshing ();
void SetGeometry (class STLGeometry * astlgeometry) { stlgeometry = astlgeometry; }
virtual void BuildScene (int zoomall = 0);
virtual void DrawScene ();
virtual void MouseDblClick (int px, int py);
int seltria;
};
}
#endif