![]() |
![]() |
![]() |
V_Sim API - Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
ToolPanel* panelIsosurfacesInit (); gboolean panelIsosurfacesSet_used (VisuData *dataObj
,gboolean used
); gboolean panelIsosurfacesLoad_file (const char *file_name
,gboolean fit_to_box
,VisuData *data
,GHashTable *table
,double **box
); gboolean panelIsosurfacesParse_XMLFile (const gchar *filename
,GError **error
); gboolean panelIsosurfacesShow_all (gboolean show
); void panelIsosurfacesEdit_surfaceProperties (GtkTreeIter *iter
); void panelIsosurfacesAdd_withValue (gchar *filename
,float value
,gchar *name
); enum PanelIsosurfacesColumnId; GtkListStore* panelIsosurfacesGet_listStore (); gboolean panelIsosurfacesHide (Plane **planes
); #define SURFACE_NAME_STR #define SURFACE_NAME_CHOOSE GtkWidget* panelIsosurfacesGenerate_isoValues (int *nbValues
,float **values
,gchar **name
,float minVal
,float maxVal
);
This module contains the panel used to draw isosurfaces. From it, you can draw isosurfaces on screen after they are loaded through the surfaces module. You can also access tools to manage and create .surf files, these tools are related to the panelSurfacesTools module.
gboolean panelIsosurfacesSet_used (VisuData *dataObj
,gboolean used
);
Change the status of the isosurface extension, drawn or not.
|
the current VisuData (can be NULL) ; |
|
a boolean. |
Returns : |
TRUE if the OpenGLAskForReDraw signal should be emitted. |
gboolean panelIsosurfacesLoad_file (const char *file_name
,gboolean fit_to_box
,VisuData *data
,GHashTable *table
,double **box
);
Tries to load the given file_name
and if it succeeds, adds loaded surfaces
to the isosurfaces panel. In all cases, all previously loaded surfaces are
removed from the panel (and from memory).
|
the file you want to try to load |
|
whether these isosurfaces should be resized in order to fit to the current VisuBox ; |
|
the VisuData to fit the box to (can be NULL if fit_to_box
is false ;
|
|
a set of different Option (can be NULL). |
|
a location to store the 6 values defining the loaded box (can be NULL). |
Returns : |
TRUE in case of success. |
gboolean panelIsosurfacesParse_XMLFile (const gchar *filename
,GError **error
);
This routine reads an XML file and setup the resources and the isovalues to the selected row accordingly.
|
a location to read the XML data. |
|
a location to store possible error. |
Returns : |
TRUE on success. |
gboolean panelIsosurfacesShow_all (gboolean show
);
Shows or hides all surfaces and check their "draw" status in the panel accordingly.
|
TRUE to show all surfaces, FALSE to hide them. |
Returns : |
TRUE if surface list should be rebuild and redraw. |
void panelIsosurfacesEdit_surfaceProperties
(GtkTreeIter *iter
);
Opens a new window allowing to edit surface properties.
|
the currently selected row iter (or NULL). |
void panelIsosurfacesAdd_withValue (gchar *filename
,float value
,gchar *name
);
Create and add a surface created from the given scalar field. This
field must already be loaded. If name
is not given, the surface will
be called "Isosurface id" where id is an increasing counter.
|
the name of the scalar field from which to add a surface ; |
|
the iso value ; |
|
the name used to identify the new surface (can be NULL). |
typedef enum { COLUMN_FIELD_LABEL, COLUMN_FIELD_POINTER, NB_COLUMN_FIELD } PanelIsosurfacesColumnId;
Thesse are the description of the columns stored in the GtkListStore
of this panel. See panelIsosurfacesGet_listStore()
to access this liststore.
a string, the description of the scalar field. | |
the pointer to the ScalarField object. | |
the number of columns. |
GtkListStore* panelIsosurfacesGet_listStore ();
This method gives read access to the GtkListStore used to store the scalar field files.
Returns : |
the GtkListStore used by this panel to store its scalar fields. It should be considered read-only. |
gboolean panelIsosurfacesHide (Plane **planes
);
Must be called after the initialisation of the plane subpanel. It applies the masking scheme of planes on current surfaces.
|
an array of planes to be applied (NULL terminated). |
Returns : |
TRUE if the surface should be rebuilt. |
#define SURFACE_NAME_STR "Choose an id name"
The default string used to name surfaces that are not associated to any public surface ressource.
#define SURFACE_NAME_CHOOSE "<span size=\"smaller\"><i>"SURFACE_NAME_STR"</i></span>"
The string used in the tree view to represent the surfaces that don't share surface resources.
GtkWidget* panelIsosurfacesGenerate_isoValues (int *nbValues
,float **values
,gchar **name
,float minVal
,float maxVal
);
This method opens a little dialog window that is made to help the
user enter a list of values for creation of iso-surfaces. These values
are generated between minVal
and maxVal
.
|
a location of an integer to store the number of generated values ; |
|
a pointer on a float array. The target of this pointer must be
NULL and it will be allocated after a call to this method. Use
g_free() after use to free it.
|
|
a pointer to store a name. The target of this pointer must be NULL on enter. It is associated only if a name is given. |
|
the minimum value for the range ; |
|
the maximum value for the range. |
Returns : |
the dialog widget. |