anatomist  5.1.2
3D neuroimaging data viewer
anatomist::RefWindow Class Reference

#include <anatomist/reference/wReferential_3d.h>

Inheritance diagram for anatomist::RefWindow:
Collaboration diagram for anatomist::RefWindow:

Public Types

enum  ViewType { Sphere , Flat , Circle }
 
- Public Types inherited from AWindow3D
enum  ViewType {
  Oblique , Axial , Sagittal , Coronal ,
  ThreeD
}
 
enum  RenderingMode {
  Normal , Wireframe , Outlined , HiddenWireframe ,
  Fast
}
 
enum  ClipMode { NoClip , Single , Double }
 
typedef anatomist::GLWidgetManager *(* GLWidgetCreator) (anatomist::AWindow *win, QWidget *parent, const char *name, const QGLWidget *shareWidget, Qt::WindowFlags f)
 
- Public Types inherited from anatomist::AWindow
enum  Type { CTRL_WINDOW = 100 , WINDOW_2D = 101 , WINDOW_3D = 102 }
 
enum  SubType {
  AXIAL_WINDOW = 200 , SAGITTAL_WINDOW = 201 , CORONAL_WINDOW = 202 , OBLIQUE_WINDOW = 203 ,
  OTHER = 299
}
 
enum  RecordingState { OFF , ON , DISABLED }
 
- Public Types inherited from carto::RCObject
typedef int RefCounterType
 

Public Slots

void updateReferentialView ()
 
void setSphereView ()
 
void setFlatView ()
 
void toggleInfo ()
 
- Public Slots inherited from AWindow3D
virtual void polish ()
 
void resizeView ()
 
void changeSlice (int)
 
void changeTime (int)
 
void changeTimeSliders (int, int)
 
void changeReferential ()
 
void muteAxial ()
 
void muteCoronal ()
 
void muteSagittal ()
 
void muteOblique ()
 
void mute3D ()
 
void lightView ()
 
void pointsOfView ()
 
void tools ()
 
void syncViews (bool keepextrema=false)
 
void focusView ()
 
void toolsWinDestroyed ()
 
void povWinDestroyed ()
 
void lightWinDestroyed ()
 
virtual void Refresh ()
 
virtual void refreshNow ()
 Refresh the window (redraw the contained objects). More...
 
void refreshTemp ()
 Redraws temporary objects only. More...
 
void refreshTempNow ()
 
void refreshLightView ()
 Only redraws existing objects (in most cases, just calls existing OpenGL lists, except for observer-dependent objects) More...
 
void refreshLightViewNow ()
 
void setAutoRotationCenter ()
 
void askZoom ()
 
float getZoom () const
 
int getSliceSliderPosition ()
 
int getTimeSliderPosition ()
 
int getSliceSliderMaxPosition ()
 
int getTimeSliderMaxPosition ()
 
void setSliceSliderPosition (int position)
 
void setTimeSliderPosition (int position)
 
void switchToolbox ()
 
void setLinkedCursorPos ()
 
void openStereoView ()
 
void toggleStatusBarVisibility ()
 
bool toopTipsEnabled () const
 
void enableToolTips (bool)
 
void resizeEvent (QResizeEvent *)
 
QImage snapshotImage (int width=0, int height=0, int bufmode=0)
 Get a snapshot of the window, after a refresh if needed. More...
 
virtual carto::rc_ptr< anatomist::ViewStateviewState ()
 
- Public Slots inherited from ControlledWindow
virtual void activeControlChanged (QAction *)
 
virtual void updateControls ()
 
- Public Slots inherited from QAWindow
virtual void refreshNow ()
 Real drawing function, replacing AWindow::Refresh in subclasses of QAWindow - Don't forget to call QAWindow::refreshNow from overloaded functions. More...
 
virtual bool needsRedraw () const
 
virtual void detach ()
 detach view from a block More...
 
virtual void toggleToolBars ()
 
virtual void toggleFullScreen ()
 
void triggeredRefresh ()
 calls refreshNow() and cleanup More...
 

Public Member Functions

 RefWindow ()
 
virtual ~RefWindow ()
 
void tempDisableShuffle (bool disable=true)
 
virtual anatomist::AObjectobjectAtCursorPosition (int x, int y)
 pick the object at the cursor 2D position More...
 
void selectReferential (AObject *rmesh)
 
void selectTransformation (AObject *tmesh)
 
void unselect ()
 
virtual void unregisterObject (AObject *obj)
 
QGraphicsScene * graphicsScene ()
 
- Public Member Functions inherited from AWindow3D
 AWindow3D (ViewType t=Oblique, QWidget *parent=0, carto::Object params=carto::none(), Qt::WindowFlags f=Qt::WindowFlags())
 
virtual ~AWindow3D ()
 
virtual Type type () const
 Get the window type (2D, 3D or control) More...
 
virtual SubType subtype () const
 
virtual void registerObject (anatomist::AObject *obj, bool temporaryObject=false, int position=-1)
 
virtual bool positionFromCursor (int x, int y, Point3df &pos)
 Translates mouse position to Anatomist geometry position. More...
 
virtual std::list< anatomist::AObject * > * objectsAtCursorPosition (int x, int y, int tolerenceRadius)
 pick several objects at the cursor 2D position More...
 
virtual int polygonAtCursorPosition (int x, int y, const anatomist::AObject *obj)
 pick a polygon on a selected object at the cursor 2D position More...
 
int computeNearestVertexFromPolygonPoint (const anatomist::ViewState &vs, int poly, const anatomist::GLComponent *glc, const Point3df &position, Point3df &positionNearestVertex)
 print all infos about vertex picked on a polygon selected More...
 
void getInfos3DFromClickPoint (int x, int y, Point3df &position, int *poly, anatomist::AObject *objselect, std::string &objtype, std::vector< float > &texvalue, std::string &textype, Point3df &positionNearestVertex, int *indexNearestVertex, std::vector< std::string > &texlabels)
 
void getInfos3DFromPosition (const std::vector< float > &position, int poly, anatomist::AObject *objselect, std::string &objtype, std::vector< float > &texvalue, std::string &textype, Point3df &positionNearestVertex, int *indexNearestVertex, std::vector< std::string > &texlabels)
 same as above but from a 3+D position. More...
 
bool surfpaintIsVisible ()
 
void setVisibleSurfpaint (bool b)
 
bool constraintEditorIsActive ()
 
void setActiveConstraintEditor (bool b)
 
void loadConstraintData (const std::vector< std::string > &constraintList, int constraintType, anatomist::AObject *texConstraint)
 
std::vector< std::string > getConstraintList ()
 
int getConstraintType () const
 
anatomist::AObjectgetConstraintTexture ()
 
void printPositionAndValue ()
 
void displayInfoAtClickPosition (int x, int y)
 
std::string displayInfoAtClickPositionAsText (int x, int y, bool html=false)
 
virtual void displayClickPoint ()
 
void setViewPoint (float *quaternion, const float zoom)
 set the view of the scene More...
 
anatomist::Lightlight ()
 
void setLight (const anatomist::Light &light)
 
void setOrientationCube (bool state)
 Compass handling methods. More...
 
bool hasOrientationCube () const
 
void setBoundingFrame (bool state)
 Frame handling methods. More...
 
bool hasBoundingFrame () const
 
void setRenderingMode (RenderingMode mode)
 Rendering mode (normal, wireframe, fast) More...
 
RenderingMode renderingMode () const
 
virtual const std::set< unsigned > & typeCount () const
 
virtual std::set< unsigned > & typeCount ()
 
virtual const std::string & baseTitle () const
 
virtual void setPosition (const Point3df &position, const anatomist::Referential *orgref)
 Set position of cursor. More...
 
virtual void setPosition (const std::vector< float > &position, const anatomist::Referential *orgref)
 
virtual void updateWindowGeometry ()
 adapts geometry to the current contents and referential More...
 
virtual anatomist::Viewview ()
 
virtual const anatomist::Viewview () const
 
virtual void setViewType (ViewType t)
 Mute into a new view type (Axial, Sagittal, Coronal or Oblique) More...
 
ViewType viewType () const
 
bool isViewOblique () const
 
bool perspectiveEnabled () const
 
void enablePerspective (bool)
 
const aims::QuaternionsliceQuaternion () const
 
void setSliceQuaternion (const aims::Quaternion &q)
 
void setSliceOrientation (const Point3df &normal)
 
void resizeView (int w, int h)
 Tries to resize the viewing area to given size. More...
 
bool boundingBox (std::vector< float > &bmin, std::vector< float > &bmax) const
 Get bounding box in N-dimension mode (new in anatomist 4.6) More...
 
ClipMode clipMode () const
 
void setClipMode (ClipMode m)
 
float clipDistance () const
 
void setClipDistance (float d)
 
bool transparentZEnabled () const
 
void enableTransparentZ (bool)
 
bool cullingEnabled () const
 
void setCulling (bool)
 
bool flatShading () const
 
void setFlatShading (bool)
 
bool smoothing () const
 
void setSmoothing (bool)
 
void setFog (bool)
 
bool fog () const
 
virtual void setReferential (anatomist::Referential *ref)
 
virtual void update (const Observable *obs, void *)
 
void setLinkedCursorOnSliderChange (bool x)
 
bool linkedCursorOnSliderChange () const
 
AWindow3DleftEyeWindow ()
 
AWindow3DrightEyeWindow ()
 
void setLeftEyeWindow (AWindow3D *)
 
void setRightEyeWindow (AWindow3D *)
 
virtual void showToolBars (int state=2)
 Shows or hides all tools (menu, toolbars) around the main view area. More...
 
virtual void showStatusBar (int state=2)
 
QSlider * getSliceSlider (void) const
 
void renderAfter (anatomist::AObject *obj, anatomist::AObject *afterthis)
 adds a rendering order constraint: obj will be rendered immediately after afterthis. More...
 
void renderBefore (anatomist::AObject *obj, anatomist::AObject *beforethis)
 adds a rendering order constraint: obj will be rendered immediately before beforethis. More...
 
std::list< anatomist::AObject * >::iterator processRenderingOrder (std::list< anatomist::AObject * > &opaque) const
 calculates the objects rendering order, according to various constraints (opaque/transparent, order at register time, before/after constraints). More...
 
bool polygonsSortingEnabled () const
 
void setPolygonsSortingEnabled (bool)
 
bool polygonsSortingDirection () const
 returns false for back-to-front, true for front-to-back More...
 
void setPolygonsSortingDirection (bool dir)
 
virtual void sortPolygons (bool force=false)
 
void renderSelectionBuffer (anatomist::ViewState::glSelectRenderMode mode, const anatomist::AObject *selectedobject=0)
 
- Public Member Functions inherited from ControlledWindow
 ControlledWindow (QWidget *parent=0, const char *name=0, carto::Object options=carto::none(), Qt::WindowFlags f=Qt::WindowFlags())
 
virtual ~ControlledWindow ()
 
virtual void updateAvailableControls ()
 
virtual void updateActivableControls ()
 
virtual void updateActions ()
 
virtual void updateActiveControl ()
 
std::map< std::string, QAction * > getControlButtonObjects (void)
 
- Public Member Functions inherited from QAWindow
 QAWindow (QWidget *parent=0, const char *name=0, carto::Object params=carto::none(), Qt::WindowFlags f=Qt::WindowFlags())
 
virtual ~QAWindow ()
 
virtual void setGeometry (int x, int y, unsigned w, unsigned h)
 
virtual void geometry (int *x, int *y, unsigned *w, unsigned *h)
 Get position and dimensions of the window. More...
 
virtual void show ()
 
virtual void hide ()
 
virtual void iconify ()
 
virtual void unIconify ()
 
virtual bool close ()
 
void setFullScreen (int state=2)
 
bool isFullScreen () const
 
virtual void setTitle (const std::string &name)
 
virtual void enableDetachMenu (bool x)
 
void Refresh ()
 In QAWindows, Refresh() doesn't redraw right now. More...
 
virtual QToolBar * addToolBar (const QString &title, const QString &name)
 
virtual QToolBar * addToolBar (Qt::ToolBarArea area, const QString &title, const QString &name)
 
virtual void addToolBar (QToolBar *, const QString &name)
 
virtual void addToolBar (Qt::ToolBarArea area, QToolBar *toolbar, const QString &name)
 
virtual QToolBar * insertToolBar (int pos, Qt::ToolBarArea area, const QString &title, const QString &name)
 
virtual void removeToolBar (QToolBar *toolbar)
 
virtual QToolBar * removeToolBar (const QString &name)
 
QToolBar * toolBar (const QString &name)
 
void setDetachMenuAction (QAction *)
 
- Public Member Functions inherited from anatomist::AWindow
virtual ~AWindow ()
 Unregisters from the application and other objects. More...
 
void displayTalairach ()
 Affiche les coordonnees de Talairach qui correspondent a la position du curseur lie (window 2D) More...
 
virtual bool toolBarsVisible () const
 
virtual void setupWindow ()
 Sets correct size and lookup of the window. More...
 
virtual std::string Title () const
 
void setId (int id)
 Set the window identifier. More...
 
void SetRefreshFlag ()
 Set the refresh flag on. More...
 
void ResetRefreshFlag ()
 Set the refresh flag off. More...
 
bool lookupChanged () const
 
void setLookupChanged (bool flg=true)
 
int id () const
 Get the window identifier. More...
 
bool RefreshFlag () const
 Get the refresh flag status. More...
 
std::set< AObject * > Objects () const
 Get the objects. More...
 
bool hasObject (AObject *obj) const
 
virtual Point3df getPosition () const
 Get position of cursor. More...
 
float getTime () const
 Get time position of cursor. More...
 
virtual std::vector< float > getFullPosition () const
 
virtual void setTime (float time)
 Set time position of cursor. More...
 
ReferentialgetReferential () const
 
GeometrywindowGeometry () const
 
void setWindowGeometry (Geometry *geom)
 
int Group () const
 
void setGroup (int group)
 
void setHasCursor (int hasCursor)
 
bool hasCursor () const
 takes both the global and own flags into account More...
 
int hasSelfCursor () const
 returns the own flag of the window (see hasGlobalCursor) (tri-state) More...
 
virtual AObjectobjectAt (const std::vector< float > &pos)
 
virtual void selectObject (const std::vector< float > &pos, int modifier)
 Selects (highlights) object at a given 4D space position. More...
 
virtual void button3clicked (int x, int y)
 handles button3 click (menu) More...
 
virtual void findObjectsAt (const std::vector< float > &pos, std::set< AObject * > &shown, std::set< AObject * > &hidden)
 finds objects at given position (internal) More...
 
virtual void update (const Observable *observable, void *arg)
 This method is called whenever the observed object is changed. More...
 
virtual void recordImages ()
 
virtual RecordingState recordingState () const
 
virtual void startRecord ()
 
virtual void startRecord (const std::string &filename)
 
virtual void stopRecord ()
 
virtual bool needsRedraw () const
 returns true if a refresh has been triggered and not performed yet (in subclasses: AWindow always returns false) More...
 
bool isTemporary (AObject *o) const
 
const std::set< AObject * > & temporaryObjects () const
 
- Public Member Functions inherited from carto::SharedObject
 SharedObject ()
 
 SharedObject (const SharedObject &x)
 
virtual ~SharedObject ()
 
SharedObjectoperator= (const SharedObject &)
 
bool testDeletable ()
 
bool tryDelete ()
 
- Public Member Functions inherited from carto::WeakObject
void attachWeakPtr (weak_ptr< T > &) const
 
void detachWeakPtr (weak_ptr< T > &) const
 
void attachWeakPtr (weak_shared_ptr< T > &) const
 
void detachWeakPtr (weak_shared_ptr< T > &) const
 
virtual ~WeakObject ()
 
- Public Member Functions inherited from carto::RCObject
 RCObject ()
 
 RCObject (const RCObject &)
 
RCObjectoperator= (const RCObject &)
 
virtual ~RCObject ()
 
- Public Member Functions inherited from anatomist::Observer
virtual ~Observer ()
 
- Public Member Functions inherited from anatomist::ControlSwitchObserver
 ControlSwitchObserver ()
 
virtual ~ControlSwitchObserver ()
 
- Public Member Functions inherited from anatomist::Observable
 Observable ()
 Construct an Observable with zero observers. More...
 
virtual ~Observable ()
 does nothing More...
 
void addObserver (Observer *observer)
 Adds an observer to the set of observers for this object. More...
 
void deleteObserver (Observer *observer)
 Deletes an observer from the set of observers of this object. More...
 
void deleteObservers ()
 Clears the observer list so that this object no longer has any observers (doesn't call any observer method - see notifyUnregisterObservers() for this ) More...
 
int countObservers () const
 Returns the number of observers of this object. More...
 
virtual void notifyObservers (void *arg=0)
 If this object has changed, as indicated by the hasChanged method, then notify all of its observers. More...
 
virtual void notifyUnregisterObservers ()
 Notifies observable destruction to all observers and unregisters them. More...
 
bool hasChanged () const
 Tests if this object has changed. More...
 
bool obsHasChanged (int) const
 only valid during an Observer::update() More...
 
bool obsHasChanged (const std::string &) const
 only valid during an Observer::update() More...
 
void setChanged () const
 Indicates that this object has changed. More...
 

Additional Inherited Members

- Signals inherited from AWindow3D
void refreshed ()
 
void sliderChanged (int dim, int slice)
 
void orientationChanged ()
 
- Static Public Member Functions inherited from AWindow3D
static anatomist::Geometry setupWindowGeometry (const std::list< carto::shared_ptr< anatomist::AObject > > &objects, const aims::Quaternion &slicequat, const anatomist::Referential *wref=0, QGLWidget *glw=0, bool with3d=false)
 
static void setGLWidgetCreator (GLWidgetCreator)
 hook to create inherited QAGLWidgets (Vtk-enabled for instance) More...
 
- Static Public Member Functions inherited from anatomist::AWindow
static void setLeftRightDisplay (bool state)
 
static int leftRightDisplay ()
 
static void setLeftRightDisplaySize (int size)
 
static int leftRightDisplaySize ()
 
static void setDisplayedAnnotations (const std::vector< std::string > &annotation_list)
 
static std::vector< std::string > displayedAnnotations ()
 
static void setGlobalHasCursor (bool hasCursor)
 
static int hasGlobalCursor ()
 
static void setCursorSize (int cursorSize)
 
static int cursorSize ()
 
static void setUseDefaultCursorColor (bool state)
 Set the default color cursor flag. More...
 
static int useDefaultCursorColor ()
 Give the default color cursor flag. More...
 
static void setCursorColor (const AimsRGB &cursCol)
 Set the color cursor. More...
 
static AimsRGB cursorColor ()
 Give the color cursor. More...
 
static float selectTolerence ()
 Selection tolerence distance. More...
 
static void setSelectTolerence (float tol)
 Set the selection tolerence distance. More...
 
static void recordCbk (void *clientdata)
 
- Protected Slots inherited from AWindow3D
void freeResize ()
 
void saveSnapshot ()
 
void saveSnapshotWithCustomSize ()
 
- Protected Member Functions inherited from AWindow3D
void showReferential ()
 
void updateLeftRightAnnotations ()
 
void displayClickPos (Point3df clickPos)
 Display the click point. More...
 
void setupTimeSlider (const std::vector< float > &bmin, const std::vector< float > &bmax)
 
void setupSliceSlider (float mins, float maxs)
 
void setupSliceSlider ()
 
void updateViewTypeToolBar ()
 
void updateObject (anatomist::AObject *obj, anatomist::PrimList *pl=0, anatomist::ViewState::glSelectRenderMode selectmode=anatomist::ViewState::glSELECTRENDER_NONE)
 
void updateObject2D (anatomist::AObject *obj, anatomist::PrimList *pl=0, anatomist::ViewState::glSelectRenderMode selectmode=anatomist::ViewState::glSELECTRENDER_NONE)
 
void updateObject3D (anatomist::AObject *obj, anatomist::PrimList *pl=0, anatomist::ViewState::glSelectRenderMode selectmode=anatomist::ViewState::glSELECTRENDER_NONE)
 
anatomist::GLPrimitives cursorGLL () const
 
int updateSliceSlider ()
 
void updateTimeSliders ()
 
void registerObjectModifier (ObjectModifier *mod)
 Allows changing display lists from normal objects DLists. More...
 
void unregisterObjectModifier (ObjectModifier *mod)
 
bool autoFusion2D (anatomist::AObject *obj)
 build or modify the auto Fusion2D object when adding a new object. More...
 
void removeFromAutoFusion2D (anatomist::AObject *obj)
 delete or modify the auto Fusion2D object when removing an object More...
 
bool inAutoFusion (const anatomist::AObject *obj) const
 
- Protected Member Functions inherited from QAWindow
virtual void createTitle ()
 Creates a new title for the window. More...
 
virtual void dragEnterEvent (QDragEnterEvent *)
 
virtual void dragMoveEvent (QDragMoveEvent *)
 
virtual void dropEvent (QDropEvent *)
 
virtual void mouseMoveEvent (QMouseEvent *e)
 
virtual void closeEvent (QCloseEvent *event)
 
- Protected Member Functions inherited from anatomist::AWindow
 AWindow ()
 AWindow constructor registers itself in the application. More...
 
void setWindowTitle ()
 Set the title of the window. More...
 
virtual void unregisterObservable (Observable *obs)
 Called when an observable is destroyed, only called by Observable: don't use this function directly. More...
 
void manageAutoReferential ()
 automatically set the contained objects referential to the window if it has not been set manually, and if all objetcs share the same referential. More...
 
- Protected Member Functions inherited from carto::SharedObject
void disableRefCount ()
 
- Protected Member Functions inherited from carto::WeakObject
 WeakObject ()
 
 WeakObject (const WeakObject &)
 
WeakObjectoperator= (const WeakObject &)
 
- Protected Member Functions inherited from anatomist::Observer
virtual void cleanupObserver ()
 call this function from inherited classes destructors. More...
 
virtual void registerObservable (Observable *)
 only called by Observable: don't use this function directly More...
 
const std::set< Observable * > & observed () const
 
- Protected Member Functions inherited from anatomist::Observable
void clearChanged () const
 Indicates that this object has no longer changed, or that it has already notified all of its observers of its most recent change. More...
 
void obsSetChanged (int, bool=true) const
 int-based change flags (use enums to address them) More...
 
void obsSetChanged (const std::string &, bool=true) const
 string-based change flags More...
 
- Protected Attributes inherited from anatomist::AWindow
int _id
 Window identificator. More...
 
bool _refresh
 Should the window be refreshed? More...
 
bool _lookupChanged
 Lookup has changed (title or geometry) More...
 
std::list< carto::shared_ptr< AObject > > _objects
 List of the objects contained in the window. More...
 
std::set< AObject * > _sobjects
 Same but as a set (for fast search) More...
 
std::set< AObject * > _tempObjects
 
std::vector< float > _timepos
 Cursor time + next dimensions. More...
 
Referential_referential
 Referentiel. More...
 
Geometry_geometry
 Geometry. More...
 
std::string _title
 Title of the window. More...
 
int _instNumber
 Number of instance of the window class. More...
 
int _group
 Group number, for linked windows. More...
 
Point3df _position
 Click position. More...
 
- Static Protected Attributes inherited from AWindow3D
static std::set< unsigned > _count3d
 3D windows static counter More...
 
static std::string _baseTitle
 

Detailed Description

Definition at line 45 of file wReferential_3d.h.

Member Enumeration Documentation

◆ ViewType

Enumerator
Sphere 
Flat 
Circle 

Definition at line 50 of file wReferential_3d.h.

Constructor & Destructor Documentation

◆ RefWindow()

anatomist::RefWindow::RefWindow ( )

◆ ~RefWindow()

virtual anatomist::RefWindow::~RefWindow ( )
virtual

Member Function Documentation

◆ graphicsScene()

QGraphicsScene* anatomist::RefWindow::graphicsScene ( )

References slots.

◆ objectAtCursorPosition()

virtual anatomist::AObject* anatomist::RefWindow::objectAtCursorPosition ( int  x,
int  y 
)
virtual

pick the object at the cursor 2D position

Reimplemented from AWindow3D.

◆ selectReferential()

void anatomist::RefWindow::selectReferential ( AObject rmesh)

◆ selectTransformation()

void anatomist::RefWindow::selectTransformation ( AObject tmesh)

◆ setFlatView

void anatomist::RefWindow::setFlatView ( )
slot

◆ setSphereView

void anatomist::RefWindow::setSphereView ( )
slot

◆ tempDisableShuffle()

void anatomist::RefWindow::tempDisableShuffle ( bool  disable = true)

◆ toggleInfo

void anatomist::RefWindow::toggleInfo ( )
slot

◆ unregisterObject()

virtual void anatomist::RefWindow::unregisterObject ( AObject obj)
virtual

Reimplemented from AWindow3D.

◆ unselect()

void anatomist::RefWindow::unselect ( )

◆ updateReferentialView

void anatomist::RefWindow::updateReferentialView ( )
slot

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