Salome HOME
0021196: [CEA 456] Integration and merge modification for debian packages
[modules/visu.git] / idl / VISU_Gen.idl
1 //  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 //  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 //  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 //
6 //  This library is free software; you can redistribute it and/or
7 //  modify it under the terms of the GNU Lesser General Public
8 //  License as published by the Free Software Foundation; either
9 //  version 2.1 of the License.
10 //
11 //  This library is distributed in the hope that it will be useful,
12 //  but WITHOUT ANY WARRANTY; without even the implied warranty of
13 //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 //  Lesser General Public License for more details.
15 //
16 //  You should have received a copy of the GNU Lesser General Public
17 //  License along with this library; if not, write to the Free Software
18 //  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 //
20 //  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 //
22 //  File   : VISU_Gen.idl
23 //  Author : Alexey Petrov
24
25 /*! \file VISU_Gen.idl This file conatins a set of interfaces of the %VISU module.
26  *     This module provides various forms of data visualization in %SALOME application.
27  *     These forms include data tables, XY plots, 3d representations
28  *     and combination of these forms.
29  */
30
31 #ifndef __VISU_GEN__
32 #define __VISU_GEN__
33
34 #include "SALOME_Exception.idl"
35 #include "SALOME_GenericObj.idl"
36 #include "SALOME_Component.idl"
37 #include "SALOMEDS.idl"
38 #include "SALOMEDS_Attributes.idl"
39 #include "MED.idl"
40
41 /*!
42   The main package of interfaces of the post-processing module %VISU.
43 */
44 module VISU {
45   //-------------------------------------------------------
46   typedef string IdType;
47
48   typedef sequence<string> string_array;
49   typedef sequence<double> double_array;
50
51   /*!
52    * This enumeration contains a set of elements defining the type
53    * of the scaling, which can be applied on different presentations.
54    */
55   enum Scaling{ LINEAR, /*!< Linear type of scaling. */
56                 LOGARITHMIC /*!< Logarithmic type of scaling. */
57               };
58
59   /*!
60    * This enumeration contains a set of elements defining
61    * what kind of value will be extracted from gauss points data.
62    */
63   enum GaussMetric {
64     AVERAGE, /*!< Average value (default). */
65     MINIMUM, /*!< Minimum value. */
66     MAXIMUM  /*!< Maximum value. */
67   };
68
69   /*!
70    * This enumeration contains a set of elements defining the
71    * type of the %entity (topological units) constituting a mesh.
72    */
73   enum Entity {
74     NODE, /*!< Node corresponds to a geometrical point. */
75     EDGE, /*!< Edge corresponds to a geometrical line connecting two points. */
76     FACE, /*!< Face corresponds to a geometrical plane bounded by several lines. */
77     CELL, /*!< Cell is a volumic element of a mesh */
78     NONE  /*!< Indicates undefined entity value */
79   };
80
81   /*!
82    * Marker type (used for point rendering)
83    */
84   enum MarkerType {
85     MT_NONE,
86     MT_POINT,
87     MT_PLUS,
88     MT_STAR,
89     MT_O,
90     MT_X,
91     MT_O_POINT,
92     MT_O_PLUS,
93     MT_O_STAR,
94     MT_O_X,
95     MT_USER
96   };
97
98   /*!
99    * Marker scale (used for point rendering)
100    */
101   enum MarkerScale {
102     MS_NONE,
103     MS_10,
104     MS_15,
105     MS_20,
106     MS_25,
107     MS_30,
108     MS_35,
109     MS_40,
110     MS_45,
111     MS_50,
112     MS_55,
113     MS_60,
114     MS_65,
115     MS_70
116   };
117
118   /*!
119    * Tables' sort order
120    */
121   enum SortOrder {
122     AscendingOrder, /*!< The table items are sorted ascending */
123     DescendingOrder /*!< The table items are sorted descending */
124   };
125
126   /*!
127    * Tables' sort policy (specifies how empty cells are taken into account when sorting)
128    */
129   enum SortPolicy {
130     EmptyLowest,    /*!< Empty cells are considered as lowest values */
131     EmptyHighest,   /*!< Empty cells are considered as highest values */
132     EmptyFirst,     /*!< Empty cells are always first */
133     EmptyLast,      /*!< Empty cells are always last */
134     EmptyIgnore     /*!< Empty cells are ignored (stay at initial positions) */
135   };
136
137   /*!
138    * This enumeration contains a set of elements defining the type of the %VISU object.
139    * This enumeration is used for navigation between a set of %VISU interfaces.
140    */
141   enum VISUType {
142     TNONE, /*!< Not a %VISU object */
143     TCURVE, /*!< Curve line object for construction of 2D XY plots */
144     TTABLE, /*!< Table containing numerical data */
145     TCONTAINER, /*!< Container object used for storing a set of curve lines */
146     TMESH, /*!< Meshing object */
147     TSCALARMAP, /*!< Scalarmap 3D presentation object */
148     TISOSURFACES, /*!< Iso surface 3D presentation object */
149     TDEFORMEDSHAPE, /*!< Deformed shape 3D presentation object */
150     TSCALARMAPONDEFORMEDSHAPE, /*!< Scalar map on deformed shape 3D presentation object. It is obsolete. Use TDEFORMEDSHAPEANDSCALARMAP instead */
151     TDEFORMEDSHAPEANDSCALARMAP, /*!< Deformed shape and scalar map 3D presentation object */
152     TGAUSSPOINTS, /*!< Gauss Points 3D presentation object */
153     TPLOT3D, /*!< Plot3D 3D presentation object */
154     TPOINTMAP3D, /*!< 3D presentation for table object */
155     TCUTPLANES, /*!< Cut planes 3D presentation object */
156     TCUTLINES, /*!< Cut lines 3D presentation object */
157     TCUTSEGMENT, /*!< Cut segment 3D presentation object */
158     TVECTORS, /*!< Vectors 3D presentation object */
159     TSTREAMLINES, /*!< Streamlines 3D presentation object */
160     TVISUGEN, /*!< %VISU generator used for performing operations with different %VISU objects */
161     TVIEWMANAGER, /*!< View manager used for performing operations with different views */
162     TRESULT, /*!< The data on which different presentations are based */
163     TXYPLOT, /*!< 2D XY plot consisting of one or several curve lines */
164     TTABLEVIEW, /*!< Table view is used for displaying data tables */
165     TVIEW3D, /*!< 3D view is used for displaying 3D graphical presentations */
166     TGAUSSVIEW, /*!< 3D view is used for displaying Gauss Points graphical presentations */
167     TENTITY, /*!< An element composing a mesh: node, edge, face or cell */
168     TFAMILY, /*!< The whole mesh can be divided into one or several submeshes, called families, which are defined by the user. Each family in its turn is composed of entities of a definite type. */
169     TGROUP, /*!< A group of families */
170     TFIELD, /*!< Field represents the results of calculations (it can be scalar or vector values), grouped together under one physical concept. */
171     TTIMESTAMP, /*!<Time stamp represents a subfield: the results of calculations are taken in one definite moment. */
172     TANIMATION, /*!< Represents Animation object. */
173     TEVOLUTION, /*!< Represents Evolution object. */
174     TCOLOREDPRS3DHOLDER, /*!< Colored 3D presentation holder */
175     TCOLOREDPRS3DCACHE, /*!< Colored 3D presentation cache */
176     TPART, /*!< MULTIPR: part of a mesh */
177     TALL
178   };
179
180   /* Clipping planes management */
181   struct ClippingPlane {
182     double X;
183     double Y;
184     double Z;
185     double dX;
186     double dY;
187     double dZ;
188     boolean isAuto;
189     string name;
190   };
191
192   interface Base {
193     /*!
194      * Returns ID of the object.
195      */
196     IdType GetID();
197
198     /*!
199      * Returns the type of the presentable object
200      */
201     VISUType GetType();
202   };
203
204   /*!
205    *  \brief Removable object interface
206    *
207    *  Removable object interface is the root class of all removable objects.
208    */
209   interface RemovableObject : Base {
210     /*!
211      *  Remove object from study.
212      */
213     void RemoveFromStudy();
214   };
215
216   /*! \brief Presentable object interface
217    *
218    * Presentable object interface is the root class of all presentable objects.
219    */
220   interface PrsObject : RemovableObject {
221   };
222
223   //-------------------------------------------------------
224   /*! \brief Interface of curve representation.
225    *
226    * Manages presentation parameters of one curve.
227    * It can be used for presentation of a set of curves using a combined presentation.
228    */
229   interface Curve : PrsObject {
230     /*!
231      * Sets the title of the curve.
232      * \param theTitle This string parameter defines the title of this curve.
233      */
234     void SetTitle(in string theTitle);
235
236     /*!
237      * Gets the title of the curve.
238      * \return String value corresponding to the title of the curve.
239      */
240     string GetTitle();
241
242     /*!
243      * Sets the color of the curve.
244      * \param theColor The color of the curve. This parameter is taken
245      *                 from the <VAR>Orientation</VAR> enumeration.
246      */
247     void SetColor(in SALOMEDS::Color theColor);
248
249     /*!
250      * Gets the color of the curve.
251      * \return Color of the curve. The returned value will correspond
252      *         to one of the elements the <VAR>Color</VAR> enumeration.
253      */
254     SALOMEDS::Color GetColor();
255
256     /*!
257      * This enumeration contains a set of elements defining the
258      * presentation type of markers (data points) with help of
259      * which the curve is constructed on the graphics.
260      */
261     enum MarkerType { NONE,
262                       CIRCLE,
263                       RECTANGLE,
264                       DIAMOND,
265                       DTRIANGLE,
266                       UTRIANGLE,
267                       LTRIANGLE,
268                       RTRIANGLE,
269                       CROSS,
270                       XCROSS
271     };
272
273     /*!
274      * Sets the presentation type of markers (data points) with help of
275      * which the curve is constructed on the graphics.
276      * \param theType This parameter defines the type of marker with help
277      *                of which the curve is constructed on the graphics.
278      *                It is taken from <VAR>MarkerType</VAR> enumeration.
279      */
280     void SetMarker(in MarkerType theType);
281
282     /*!
283      * Gets the presentation type of markers (data points) with
284      * help of which the curve is constructed on the graphics.
285      * \return The type of marker with help of which the curve is constructed
286      *         on the graphics. The returned value will correspond to
287      *         one of the elements the <VAR>MarkerType</VAR> enumeration.
288      */
289     MarkerType GetMarker();
290
291     /*!
292      * This enumeration contains a set of elements defining the
293      * type of presentation of a curve line on the graphics.
294      */
295     enum LineType{ VOIDLINE, SOLIDLINE, DASHLINE, DOTLINE, DASHDOTLINE, DASHDOTDOTLINE};
296
297     /*!
298      * Sets the type of presentation of curve lines on the graphics.
299      * \param theType This parameter defines the type of presentation of curve lines on the graphics.
300      * \param theLineWidth Long value defining the width of the curve line.
301      */
302     void SetLine(in LineType theType, in long theLineWidth);
303
304     /*!
305      * Gets the type of representation of curve lines on the graphics.
306      * \return The type of representation of curve lines on the graphics.
307      */
308     LineType GetLine();
309
310     /*!
311      * Gets the width of the curve line.
312      * \return Long value corresponding to the width of the curve line.
313      */
314     long GetLineWidth();
315   };
316
317   //-------------------------------------------------------
318   /*! \brief %Container presentable object interface
319    *
320    * This class is provided in order to create one presentation using several presentable objects.
321    * This can provide a combination of a set of curves to display them in XY plot view.
322    */
323   interface Container : PrsObject {
324     /*!
325      * Adds a curve into the container.
326      * \param theCurve The added curve.
327      */
328     void AddCurve(in Curve theCurve);
329
330     /*!
331      * Removes a curve from the container.
332      * \param theCurve The removed curve.
333      */
334     void RemoveCurve(in Curve theCurve);
335
336     /*!
337      * Gets the number of curves which are stored in the container.
338      * \return A long value corresponding to the number of curves which are stored in the container.
339      */
340     long GetNbCurves();
341
342     /*!
343      * Removes all curves from the container.
344      */
345     void Clear();
346   };
347
348   //-------------------------------------------------------
349   interface Result;
350   /*! \brief 3D presentation interface
351    *
352    * This is a root class for all 3D presentations, which can be displayed in %VISU module.
353    */
354   interface Prs3d : PrsObject, SALOME::GenericObj
355   {
356     /*!
357      * Move the 3D presentation according to the given offset parameters
358      */
359     void SetOffset(in float theDx, in float theDy, in float theDz);
360
361     /*!
362      * Gets offset parameters for the 3D presentation
363      */
364     void GetOffset(out float theDx, out float theDy, out float theDz);
365
366     /*!
367      * Set standard point marker for the object
368      * \param theType standard marker type
369      * \param theScale standard marker scale
370      */
371     void SetMarkerStd(in MarkerType theType, in MarkerScale theScale);
372
373     /*!
374      * Set custom point marker for the object. The texture can be added
375      * by LoadTexture() function
376      * \param theTextureId texture ID
377      */
378     void SetMarkerTexture(in long theTextureId);
379
380     /*!
381      * Get type of the point marker assigned to the object
382      * \return current marker type (MT_NONE if no marker is set)
383      */
384     MarkerType GetMarkerType();
385
386     /*!
387      * Get scale of the point marker assigned to the object
388      * \return current marker scale (MS_NONE if no marker is set)
389      */
390     MarkerScale GetMarkerScale();
391
392     /*!
393      * Get texture idenifier of the point marker assigned to the object
394      * \return marker texture ID (0 if no marker set)
395      */
396     long GetMarkerTexture();
397
398     /*!
399      * Gets memory size actually used by the presentation (Mb).
400      */
401     float GetMemorySize();
402   };
403
404   /*!
405    * This enumeration contains a set of elements defining the
406    * type of presentation of the mesh.
407    */
408   enum PresentationType{ POINT,
409                          WIREFRAME,
410                          SHADED,
411                          INSIDEFRAME,
412                          SURFACEFRAME,
413                          FEATURE_EDGES,
414                          SHRINK
415   };
416
417   /*!
418    * This enumeration contains a set of elements defining the
419    * type of presentation of the 2D quadratic mesh elements.
420    */
421   enum Quadratic2DPresentationType{
422     LINES,
423     ARCS
424   };
425
426   /*! \brief Interface of the mesh.
427    *
428    * Manages presentation parameters of a 3D presentation of a mesh.
429    * This object can be used for presentation of set of curves using Container class.
430    */
431   interface Mesh : Prs3d {
432     /*!
433      * Sets the color of mesh cells.
434      * \param theColor The color of the cells. This parameter is taken from <VAR>Color</VAR> enumeration.
435      */
436     void SetCellColor(in SALOMEDS::Color theColor);
437
438     /*!
439      * Gets the color of mesh cells.
440      */
441     SALOMEDS::Color GetCellColor();
442
443     /*!
444      * Sets the color of mesh nodes.
445      * \param theColor The color of the nodes. This parameter is taken from <VAR>Color</VAR> enumeration.
446      */
447     void SetNodeColor(in SALOMEDS::Color theColor);
448
449     /*!
450      * Gets the color of mesh nodes.
451      */
452     SALOMEDS::Color GetNodeColor();
453
454     /*!
455      * Sets the color of mesh links.
456      * \param theColor The color of the links. This parameter is taken from <VAR>Color</VAR> enumeration.
457      */
458     void SetLinkColor(in SALOMEDS::Color theColor);
459
460     /*!
461      * Gets the color of mesh links.
462      */
463     SALOMEDS::Color GetLinkColor();
464
465     /*!
466      * Sets the type of representation of a mesh.
467      * \param theType The of representation of a mesh. This parameter is
468      *                taken from <VAR>PresentationType</VAR> enumeration.
469      */
470     void SetPresentationType(in PresentationType theType);
471
472     /*!
473      * Gets the type of representation of the mesh.
474      * \return The type of representation of the mesh.
475      */
476     PresentationType GetPresentationType();
477
478
479     /*!
480      * Sets the type of representation of a 2D quadratic mesh elements.
481      * \param theType The type of representation of 2D quadratic mesh elements.
482      *                This parameter is taken from
483      *                      <VAR>Quadratic2DPresentationType</VAR> enumeration.
484      */
485     void SetQuadratic2DPresentationType(in Quadratic2DPresentationType theType);
486
487     /*!
488      * Gets the type of representation of the 2D quadratic mesh elements.
489      * \return The type of representation of the 2D quadratic mesh elements.
490      */
491     Quadratic2DPresentationType GetQuadratic2DPresentationType();
492
493     /*!
494      * Switches shrink mode of presentation
495      * Note: SetPresentationType(SHRINK) is same as SetShrink(True)
496      */
497     void SetShrink(in boolean toShrink);
498
499     /*!
500      * Returns current state of shrink mode
501      */
502     boolean IsShrank();
503   };
504
505
506   //-------------------------------------------------------
507   /*! \brief Basic Interface for the %Colored 3D Presentations
508    *
509    * This interface is responsable for coloring of 3D field presentations
510    * according the scalar values applied to different cells.
511    * As well it contains presentation parameters of the scalar bar. The scalar
512    * bar is displayed along with each colored field presentation and serves for
513    * consulting the correspondance between colors and data values.
514    */
515   interface ColoredPrs3dBase : Prs3d
516   {
517     /*!
518      * Sets scalar range - min and max boundaries of the scalar bar.
519      * \param theMin  Min boundary of the scalar bar.
520      * \param theMax  Max boundary of the scalar bar.
521      */
522     void SetRange(in double theMin, in double theMax);
523
524     /*!
525      * Gets the min boundary of the scalar bar.
526      */
527     double GetMin();
528
529     /*!
530      * Gets the max boundary of the scalar bar.
531      */
532     double GetMax();
533
534     /*!
535      * Sets scalar range that corresponds to the source data.
536      */
537     void SetSourceRange();
538
539     /*!
540      * Gets the min boundary of the scalar bar from source data.
541      */
542     double GetSourceMin();
543
544     /*!
545      * Gets the max boundary of the scalar bar from source data.
546      */
547     double GetSourceMax();
548
549     /*!
550      * Defines whether the scalar range corresponds to the source data or not.
551      */
552     boolean IsRangeFixed();
553
554     /*! \brief Position of the scalar bar.
555      *
556      * Sets the position of the scalar bar origin on the screen.
557      * \param X   Horizontal position. The value can be between 0 and 1.
558      * \param Y   Vertical position. The value can be between 0 and 1.
559      */
560     void SetPosition(in double X, in double Y);
561
562     /*!
563      * Gets horizontal position of the scalar bar origin.
564      */
565     double GetPosX();
566
567     /*!
568      * Gets vertical position of the scalar bar origin.
569      */
570     double GetPosY();
571
572     /*! \brief Size of this presentable object.
573      *
574      * Sets the size of the scalar bar.
575      * \param theWidth  Width of this presentable object. The value can be between 0 and 1.
576      * \param theHeight  Height of this presentable object. The value can be between 0 and 1.
577      */
578     void SetSize(in double theWidth, in double theHeight);
579
580     /*!
581      * Gets the width of this presentable object.
582      * \return A double value corresponding to the width of this presentable object.
583      */
584     double GetWidth();
585
586     /*!
587      * Gets the height of this presentable object.
588      * \return A double value corresponding to the height of this presentable object.
589      */
590     double GetHeight();
591
592     /*!
593      * Sets the number of colors which will be used for presentation of this presentable object.
594      * \param theNbColors A long value defining the number of colors.
595      */
596     void SetNbColors(in long theNbColors);
597
598     /*!
599      * Gets the number of colors which will be used for visualization of this presentable object.
600      * \return A long value corresponding to the number of colors which
601      *         will be used for visualization of this presentable object.
602      */
603     long GetNbColors();
604     /*!
605      * Sets the number of labels which will be used for indication of color gradation
606      * of the scalar bar.
607      * \param theNbLabels A long value defining the number of labels.
608      */
609     void SetLabels(in long theNbLabels);
610
611     /*!
612      * Gets the number of labels which will be used for indication of color gradation of the scalar bar.
613      * \return A long value corresponding to the number of labels which will
614      *         be used for indication of color gradation of the scalar bar.
615      */
616     long GetLabels();
617
618     /*! %Orientation of the scalar bar (to provide backward compatibility). */
619     enum Orientation {
620       HORIZONTAL, /*!< Horizontal orientation of the scalar bar.*/
621       VERTICAL    /*!< Vertical orientation of the scalar bar.*/
622     };
623
624     /*!
625      * Sets the type of orientation of the scalar bar (to provide backward compatibility).
626      * \param theOrientation This parameter defines the orientation of the scalar bar.
627      *                       It is taken from the <VAR>Orientaton</VAR> enumeration.
628      */
629     void SetBarOrientation(in Orientation theOrientation);
630
631     /*!
632      * Gets the type of orientation of the scalar bar (to provide backward compatibility).
633      */
634     Orientation GetBarOrientation();
635   };
636
637   /*! \brief Additional Interface for the %Colored 3D Presentations
638    *
639    */
640
641   interface ColoredPrs3d : ColoredPrs3dBase
642   {
643     /*!
644      * Sets the title of the scalar bar. By default - the name of the selected result is used.
645      * \param theName String parameter defining the name of the scalar bar.
646      */
647     void SetTitle(in string theName);
648
649     /*!
650      * Gets the title of the scalar bar.
651      */
652     string GetTitle();
653
654     /*! Sets the method of coloring of the elements composing a 3D presentation.
655      */
656     void SetScalarMode(in long theScalarMode);
657
658     /*! Gets the method of coloring of the elements composing a 3D presentation.
659      */
660     long GetScalarMode();
661
662     /*!
663      * Set the visibility of a distribution curve.
664      * \param theIs is used to switch on/off the visibility of a distribution curve.
665      */
666     void SetIsDistributionVisible(in boolean theIs);
667
668     //! Gets current visibility of a distribution curve
669     boolean GetIsDistributionVisible();
670
671     //! Gets current filtering by scalars mode
672     boolean IsScalarFilterUsed();
673
674     void UseScalarFiltering( in boolean theUseScalarFilter );
675
676     /*!
677      * Sets scalar range - min and max boundaries of the scalar bar.
678      * \param theMin  Min boundary of the scalar bar.
679      * \param theMax  Max boundary of the scalar bar.
680      * \param theIsFilter  if true then filter by scalars.
681      */
682     void SetScalarFilterRange( in double theMin, in double theMax );
683
684     double GetScalarFilterMin();
685
686     double GetScalarFilterMax();
687
688     /*!
689      * Add group as geometry of presentation.
690      * \param theMeshName  - mesh name
691      * \param theGroupName - group name
692      */
693     void AddMeshOnGroup(in string theGroupName);
694
695     /*!
696      * PrsMerger method:
697      * Remove all groups.(The scalar map will be placed on all mesh).
698      */
699     void RemoveAllGeom();
700   };
701
702
703   //-------------------------------------------------------
704   interface View3D;
705   interface ColoredPrs3dCache;
706
707
708   //-------------------------------------------------------
709   /*! \brief %ColoredPrs3dHolder interface.
710    * Interface of 3d presentation's holder, which represents colored 3d presentations,
711    * created on fields. It is publishing in the object browser in a separate folder
712    * and can be controled by viewer's slider.
713    */
714   interface ColoredPrs3dHolder : PrsObject, SALOME::GenericObj
715   {
716     /*!
717      * Presentation input parameters.
718      */
719     struct BasicInput
720     {
721       Result myResult;
722       string myMeshName;
723       Entity myEntity;
724       string myFieldName;
725       long myTimeStampNumber;
726     };
727
728     /*!
729      * Apply input parameters to last visited presentation in the cache.
730      */
731     boolean Apply(in ColoredPrs3d thePrs3d,
732                   in BasicInput theInput,
733                   in View3D theView3D);
734
735     /*!
736      * Gets the last visited presentation in the cache.
737      */
738     ColoredPrs3d GetDevice();
739
740     /*!
741      * Gets type of the managed presentations.
742      */
743     VISUType GetPrsType();
744
745     /*! Defines timestamp representation.
746      */
747     struct TimeStampInfo
748     {
749       string myTime;
750       long myNumber;
751     };
752
753     /*! Defines representation range of timestamps.
754      */
755     typedef sequence<TimeStampInfo> TimeStampsRange;
756
757     /*!
758      * Gets TimeStampsRange information from the last visited presentation.
759      */
760     TimeStampsRange GetTimeStampsRange();
761
762     /*!
763      * Gets input parameters of the last visited presentation.
764      */
765     BasicInput GetBasicInput();
766
767     /*!
768      * Gets a %ColoredPrs3dCache, to which the holder belongs
769      */
770     ColoredPrs3dCache GetCache();
771
772     /*!
773      * Gets memory size actually used by the holder (Mb).
774      */
775     float GetMemorySize();
776   };
777
778
779   //-------------------------------------------------------
780   /*! \brief %ColoredPrs3dCache interface.
781    * This interface is responsible for memory management of 3d presentations.
782    * One cache corresponds to one study.
783    */
784   interface ColoredPrs3dCache : RemovableObject, SALOME::GenericObj
785   {
786     /*! This enumeration contains the cache memory modes. */
787     enum MemoryMode {
788       MINIMAL, /*!< Minimal memory mode (default behaviour). */
789       LIMITED  /*!< Limited memory mode (fixed memory size for presentations). */
790     };
791
792     /*! This enumeration defines how to enlarge the cache limited memory. */
793     enum EnlargeType {
794       NO_ENLARGE, /*!< No need to enlarge (default behaviour). */
795       ENLARGE,    /*!< Enlarge limited memory. */
796       IMPOSSIBLE  /*!< Impossible to enlarge (not enough free memory). */
797     };
798
799     /*! Sets a memory mode.*/
800     void SetMemoryMode(in MemoryMode theMode);
801
802     /*! Gets a memory mode.*/
803     MemoryMode GetMemoryMode();
804
805     /*! Sets a memory size for limited mode (Mb). */
806     void SetLimitedMemory(in float theMemorySize);
807
808     /*! Gets a memory size for limited mode (Mb). */
809     float GetLimitedMemory();
810
811     /*!
812      * Gets memory size actually used by the cache system (Mb).
813      */
814     float GetMemorySize();
815
816     /*! Creates %ColoredPrs3dHolder.*/
817     ColoredPrs3dHolder CreateHolder(in VISUType theType,
818                                     in ColoredPrs3dHolder::BasicInput theInput);
819
820     /*! Gets a memory which is required to create a holder. */
821     EnlargeType GetRequiredMemory(in VISUType theType,
822                                   in ColoredPrs3dHolder::BasicInput theInput,
823                                   out float theRequiredMemory);
824   };
825
826
827   //-------------------------------------------------------
828   /*! \brief Interface of the %Scalar Map
829    *
830    * This interface is responsable for coloring of 3D field presentations
831    * according the scalar values applied to different cells.
832    * As well it contains presentation parameters of the scalar bar. The scalar
833    * bar is displayed along with each colored field presentation and serves for
834    * consulting the correspondance between colors and data values.
835    */
836
837   interface ScaledPrs3d {
838     /*!
839      * Sets the type of scaling of the values reflected by the scalar bar.
840      * \param theScaling The value of this parameter is taken from the <VAR>Scaling</VAR> enumeration.
841      */
842     void SetScaling(in Scaling theScaling);
843
844     /*!
845      * Gets the type of scaling of the values reflected by this presentation.
846      */
847     Scaling GetScaling();
848   };
849
850   interface ScalarMap : ColoredPrs3d, ScaledPrs3d {
851
852     /*!
853      * Returns visibility state of scalar bar
854      */
855     boolean IsBarVisible();
856
857     /*!
858      * Sets visibility state of scalar bar
859      */
860     void SetBarVisible(in boolean theVisible);
861
862     /*!
863      * Sets the gauss metric for the presentation.
864      * \param theGaussMetric The value of this parameter is taken from the <VAR>GaussMetric</VAR> enumeration.
865      */
866     void SetGaussMetric(in GaussMetric theGaussMetric);
867
868     /*!
869      * Gets the gauss metric of the presentation.
870      */
871     GaussMetric GetGaussMetric();
872
873     /*!
874      * Sets the color of mesh links.
875      * \param theColor The color of the links. This parameter is taken from <VAR>Color</VAR> enumeration.
876      */
877     void SetLinkColor(in SALOMEDS::Color theColor);
878
879     /*!
880      * Gets the color of mesh links.
881      */
882     SALOMEDS::Color GetLinkColor();
883   };
884
885   //-------------------------------------------------------
886   /*! \brief Gauss Points presentation interface
887    *
888    * Presentation parameters of the Gauss Points presentation.
889    */
890   //-------------------------------------------------------
891   interface GaussPoints : ColoredPrs3d
892   {
893     //! Set flag indicating which scalar bar is active.
894     void SetIsActiveLocalScalarBar(in boolean theFlag);
895
896     //! Get flag indicating which scalar bar is active.
897     boolean GetIsActiveLocalScalarBar();
898
899     //! Set flag indicating visibility of global scalar bar.
900     void SetIsDispGlobalScalarBar(in boolean theFlag);
901
902     //! Get flag indicating visibility of global scalar bar.
903     boolean GetIsDispGlobalScalarBar();
904
905     //! Set value of the distance between global and local scalar bars.
906     void SetSpacing(in double theSpacing);
907
908     //! Get value of the distance between global and local scalar bars.
909     double GetSpacing();
910
911     /*!
912      * Returns visibility state of scalar bar
913      */
914     boolean IsBarVisible();
915
916     /*!
917      * Sets visibility state of scalar bar
918      */
919     void SetBarVisible(in boolean theVisible);
920
921     /*!
922      * Set the Multicolored mode.
923      * \param theIsColored is used to switch between Results and Geometry modes.
924      * Multiple colors are using when the presentation is
925      * drawing in the Results mode, one color - in the Geometry mode.
926      */
927     void SetIsColored(in boolean theIsColored);
928
929     //! Gets current color mode
930     boolean GetIsColored();
931
932     /*! Sets the color of this presentation in case of IsColored switched off.
933      * \param theColor The color of this presentation. This parameter
934      *                 is taken from the <VAR>Color</VAR> enumeration.
935      */
936     void SetColor(in SALOMEDS::Color theColor);
937
938     /*!
939      * When the Bicolor parameter is set to true, scalar bars are
940      * drawing with two colors : red color correspoonds to positive
941      * scalar values, blue color - to negative values.
942      */
943     void SetBiColor(in boolean theIsBiColor);
944
945     //! Get the Bicolor mode.
946     boolean GetBiColor();
947
948     //! Checks whether the Gauss Points will be deformed or not
949     boolean GetIsDeformed();
950
951     //! Apply deformation on the Gauss Points
952     void SetIsDeformed(in boolean theIsDeformed);
953
954     /*!
955      *  Sets the scale factor for scalar values
956      *  (how much corresponding mesh elements should be translated).
957      *  \param theScaleFactor The scaling factor.
958      */
959     void SetScaleFactor(in double theScaleFactor);
960
961     /*!
962      *  Gets the scale factor for scalar values.
963      *  (how much corresponding mesh elements is translated)
964      */
965     double GetScaleFactor();
966
967     /*!
968      * This enumeration contains a set of elements defining the type of representation of the vector head.
969      */
970     enum PrimitiveType {
971       SPRITE,
972       POINT,
973       SPHERE
974     };
975
976     //! Set type of the primitives which is used for drawing the Gauss Points
977     void SetPrimitiveType(in PrimitiveType thePrimitiveType);
978
979     //! Get type of the primitives which is used for drawing the Gauss Points
980     PrimitiveType GetPrimitiveType();
981
982     //! Sets Point Sprite clamp
983     void SetClamp(in double theClamp);
984
985     //! Gets Point Sprite clamp
986     double GetClamp();
987
988     //! Sets minimum size of Point Sprites
989     void SetMinSize(in double theMinSize);
990
991     //! Gets minimum size of Point Sprites
992     double GetMinSize();
993
994     //! Sets maximum size of Point Sprites
995     void SetMaxSize(in double theMaxSize);
996
997     //! Gets maximum size of Point Sprites
998     double GetMaxSize();
999
1000     //! Sets magnification for Point Sprites
1001     void SetMagnification(in double theMagnification);
1002
1003     //! Gets magnification for Point Sprites
1004     double GetMagnification();
1005
1006     //! Sets the increment of changing Magnification parameter
1007     void SetMagnificationIncrement(in double theIncrement);
1008
1009     //! Gets the increment of changing Magnification parameter
1010     double GetMagnificationIncrement();
1011
1012     //! Sets Point Sprites size
1013     void SetGeomSize(in double theGeomSize);
1014
1015     //! Sets size of Point Sprite
1016     double GetGeomSize();
1017
1018     //! Get path to the image using for Main Point Sprite texture
1019     string GetMainTexture();
1020
1021     //! Get path to the image using for Alpha Point Sprite texture
1022     string GetAlphaTexture();
1023
1024     //! Points Main and AlphaMask images to be used by Point Sprites
1025     void SetTextures(in string theMainTexture, in string theAlphaTexture);
1026
1027     //! Sets Point Sprite Alpha threshold
1028     void SetAlphaThreshold(in double theAlphaThreshold);
1029
1030     //! Gets Point Sprite Alpha threshold
1031     double GetAlphaThreshold();
1032
1033     //! Sets resolution of the Geometrical Sphere
1034     void SetResolution(in long theResolution);
1035
1036     //! Sets resolution of the Geometrical Sphere
1037     long GetResolution();
1038
1039     //! Sets how many faces of can be drawn in the Geometrical Sphere primitive mode
1040     void SetFaceLimit(in long theFaceLimit);
1041
1042     //! Defines how many faces of can be drawn in the Geometrical Sphere primitive mode
1043     long GetFaceLimit();
1044
1045
1046   };
1047
1048
1049   /*! \brief MonoColor presentation presentation interface
1050    *
1051    * Presentation parameters of the MonoColor presentation.
1052    */
1053   interface MonoColorPrs : ScalarMap {
1054
1055     /*! This boolean method returns True if this deformed shape presentation is colored.
1056      */
1057     boolean IsColored();
1058
1059     /*! Shows this presentation in colored mode.
1060      * \param theColored If this boolean parameter is True this presentable
1061      *                   object will be shown in colored mode.
1062      */
1063     void ShowColored(in boolean theColored);
1064
1065     /*! Gets the color of this presentable object.
1066      * \return The color of this presentable object.
1067      */
1068     SALOMEDS::Color GetColor();
1069
1070     /*! Sets the color of this presentation.
1071      * \param theColor The color of this presentation. This parameter
1072      *                 is taken from the <VAR>Color</VAR> enumeration.
1073      */
1074     void SetColor(in SALOMEDS::Color theColor);
1075   };
1076
1077
1078   /*! \brief Deformed shape presentation interface
1079    *
1080    * Presentation parameters of the deformed shape presentation.
1081    */
1082   interface DeformedShape : MonoColorPrs
1083   {
1084     /*!
1085      * Sets the scale of the presentatable object.
1086      * \param theScale Double value defining the scale of this presentable object.
1087      */
1088     void SetScale(in double theScale);
1089
1090     /*!
1091      * Gets the scale of the presentatable object.
1092      */
1093     double GetScale();
1094
1095   };
1096
1097   //-------------------------------------------------------
1098   /*! \brief Deformation interface
1099    *
1100    * This is base interface for building of the deformed presentations
1101    */
1102   interface Deformation{
1103     /*!
1104      * Sets the scale of the presentatable object.
1105      * \param theScale Double value defining the scale of this presentable object.
1106      */
1107     void SetScale(in double theScale);
1108
1109     /*!
1110      * Gets the scale of the presentatable object.
1111      */
1112     double GetScale();
1113
1114     /*!
1115      * Sets the vectorial field
1116      * \param theEntity    - entity of vectorial field
1117      * \param theFieldName - the name of vectorial field
1118      */
1119     void SetVectorialField(in Entity theEntity,
1120                            in string theFieldName);
1121
1122     /*!
1123      * Get vectorial entity
1124      */
1125     Entity GetVectorialFieldEntity();
1126
1127     /*!
1128      * Get scalar field name
1129      */
1130     string GetVectorialFieldName();
1131
1132   };
1133
1134   //-------------------------------------------------------
1135   /*! \brief OptionalDeformation interface
1136    *
1137    * This is interface for switch on/off of the deformation of the presentation
1138    */
1139   interface OptionalDeformation : Deformation{
1140
1141     /*!
1142      * Sets the deformation flag of the presentatable object.
1143      * \param theFlag Boolean value defining the deformation flag of this presentable object.
1144      */
1145     void UseDeformation(in boolean theFlag);
1146
1147     /*!
1148      * Gets the deformation flag of the presentatable object.
1149      */
1150     boolean IsDeformed();
1151   };
1152
1153   //-------------------------------------------------------
1154   /*! \brief Scalar Map on Deformed shape presentation interface
1155    *
1156    * Presentation parameters of the scalar map on deformed shape presentation.
1157    */
1158   interface DeformedShapeAndScalarMap : ScalarMap {
1159
1160     /*!
1161      * Sets the scale of the presentatable object.
1162      * \param theScale Double value defining the scale of this presentable object.
1163      */
1164     void SetScale(in double theScale);
1165
1166     /*!
1167      * Gets the scale of the presentatable object.
1168      */
1169     double GetScale();
1170
1171     /*!
1172      * Sets the scalar field
1173      * \param theEntity    - entity of scalar field
1174      * \param theFieldName - the name of scalar field
1175      * \param theTimeStampNumber - the timestamp number for the scalar field
1176      */
1177     void SetScalarField(in Entity theEntity,
1178                         in string theFieldName,
1179                         in long theTimeStampNumber);
1180
1181
1182     /*!
1183      * Get scalar entity
1184      */
1185     Entity GetScalarEntity();
1186
1187     /*!
1188      * Get scalar field name
1189      */
1190     string GetScalarFieldName();
1191
1192     /*!
1193      * Get timestamp number for the scalar field
1194      */
1195     long GetScalarTimeStampNumber();
1196   };
1197
1198
1199   //-------------------------------------------------------
1200   /*!
1201    *  \brief Plot3D interface
1202    *
1203    *  Presentation parameters of Plot3D presentation. This type of presentation
1204    *  consists of deforming initial planar mesh according to values assigned to the mesh elements.
1205    *  If mesh not planar but volumic one, it is possible to generate intermediate planar mesh.
1206    */
1207   interface Plot3dBase {
1208     /*!
1209      *  Sets the scale factor for scalar values
1210      *  (how much corresponding mesh elements should be translated).
1211      *  \param theScaleFactor The scaling factor.
1212      */
1213     void SetScaleFactor (in double theScaleFactor);
1214
1215     /*!
1216      *  Gets the scale factor for scalar values.
1217      *  (how much corresponding mesh elements is translated)
1218      */
1219     double GetScaleFactor();
1220
1221     /*!
1222      *  Sets presentation type: contour or surface.
1223      *  \param theIsContourPrs Define, whether presentation type is contour.
1224      */
1225     void SetContourPrs (in boolean theIsContourPrs );
1226
1227     /*!
1228      *  Returns true if presentation type is contour.
1229      */
1230     boolean GetIsContourPrs();
1231
1232     /*!
1233      *  Sets the number of contours.
1234      *  \param theNb The number of contours.
1235      */
1236     void SetNbOfContours (in long theNb);
1237
1238     /*!
1239      *  Gets the number of contours.
1240      */
1241     long GetNbOfContours();
1242   };
1243
1244   interface Plot3D : ScalarMap, Plot3dBase {
1245     /*!
1246      *  This enumeration contains a set of elements defining
1247      *  the type of orientation in 3D space of the cutting plane.
1248      */
1249     enum Orientation { XY,   /*!< The object is located in the plane formed by X and Y axis. */
1250                        YZ,   /*!< The object is located in the plane formed by Y and Z axis. */
1251                        ZX }; /*!< The object is located in the plane formed by Z and X axis. */
1252
1253     /*!
1254      *  Sets the orientation in 3D space of cutting plane for the presentation.
1255      *  \param theOrientation This parameter defines the type of orientation of cutting plane
1256      *         in 3D space. It is taken from the <VAR>Orientation</VAR> enumeration.
1257      *  \param theXAngle The angle of rotation of the cutting plane
1258      *         around the first axis of the chosen orientation.
1259      *  \param theXAngle The angle of rotation of the cutting plane
1260      *         around the second axis of the chosen orientation.
1261      */
1262     void SetOrientation (in Orientation theOrientation, in double theXAngle, in double theYAngle);
1263
1264     /*!
1265      *  Gets the type of orientation in 3D space of cutting plane.
1266      */
1267     Orientation GetOrientationType();
1268
1269     /*!
1270      *  Gets rotation angle of the cutting plane
1271      *  around the first axis of the chosen orientation.
1272      */
1273     double GetRotateX();
1274
1275     /*!
1276      *  Gets rotation angle of the cutting plane
1277      *  around the second axis of the chosen orientation.
1278      */
1279     double GetRotateY();
1280
1281     /*!
1282      *  Sets the position of a cutting plane.
1283      *  \param thePlanePosition The position of the cutting plane.
1284      *  \param theIsRelative Define, whether the input position is relative.
1285      */
1286     void SetPlanePosition (in double  thePlanePosition,
1287                            in boolean theIsRelative);
1288
1289     /*!
1290      *  Gets the position of the cutting plane
1291      */
1292     double GetPlanePosition();
1293
1294     /*!
1295      *  Returns true if a position of cutting plane is relative
1296      */
1297     boolean IsPositionRelative();
1298   };
1299
1300  //-------------------------------------------------------
1301   /*! \brief %Table representation interface
1302    *
1303    * Presentation parameters of the %Table view.
1304    */
1305   interface Table : PrsObject {
1306     /*!
1307      * Sets the title of the table.
1308      * \param theTitle String parameter defining the title of this table.
1309      */
1310     void SetTitle(in string theTitle);
1311
1312     /*!
1313      * Gets the title of the table.
1314      * \return A string value containing the title of the table.
1315     */
1316     string GetTitle();
1317
1318     /*!
1319      * This enumeration contains a set of elements defining the orientation of the table.
1320      */
1321     enum Orientation {
1322       HORIZONTAL, /*!< Horizontal orientation of the table. */
1323       VERTIACAL   /*!< Vertical orientation of the table. */
1324     };
1325
1326     /*!
1327      * Sets orientation of the table.
1328      * \param theOrientation This input parameter defines the orientation of the table.
1329      *                       It is taken from the <VAR>Orientation</VAR> enumeration.
1330      */
1331     void SetOrientation(in Orientation theOrientation);
1332
1333     /*!
1334      * Gets orientation of the table.
1335      * \return Orientation of the table. The returned value will correspond
1336      *         to one of the elements the <VAR>Orientation</VAR> enumeration.
1337      */
1338     Orientation GetOrientation();
1339
1340     /*!
1341      * Gets the number of rows of the table.
1342      * \return Long value corresponding to the number of rows of the table
1343      */
1344     long GetNbRows();
1345
1346     /*!
1347      * Gets the number of columns of the table.
1348      * \return Long value corresponding to the number of columns of the table
1349      */
1350     long GetNbColumns();
1351
1352     /*!
1353      * Sorts the specified row of the table.
1354      * \param theRow Index of the row to sort
1355      * \param theSortOrder Sort order (see <VAR>SortOrder</VAR> enumeration)
1356      * \param theSortPolicy Sort policy (see <VAR>SortPolicy</VAR> enumeration)
1357      */
1358     void SortRow(in long theRow, in SortOrder theSortOrder, in SortPolicy theSortPolicy);
1359
1360     /*!
1361      * Sorts the specified column of the table.
1362      * \param theRow Index of the column to sort
1363      * \param theSortOrder Sort order (see <VAR>SortOrder</VAR> enumeration)
1364      * \param theSortPolicy Sort policy (see <VAR>SortPolicy</VAR> enumeration)
1365      */
1366     void SortColumn(in long theColumn, in SortOrder theSortOrder, in SortPolicy theSortPolicy);
1367
1368     /*!
1369      * Sorts the table by the specified row.
1370      * \param theRow Index of the row, by which the table has to be sort
1371      * \param theSortOrder Sort order (see <VAR>SortOrder</VAR> enumeration)
1372      * \param theSortPolicy Sort policy (see <VAR>SortPolicy</VAR> enumeration)
1373      */
1374     void SortByRow(in long theRow, in SortOrder theSortOrder, in SortPolicy theSortPolicy);
1375
1376     /*!
1377      * Sorts the table by the specified column.
1378      * \param theColumn Index of the column, by which the table has to be sort
1379      * \param theSortOrder Sort order (see <VAR>SortOrder</VAR> enumeration)
1380      * \param theSortPolicy Sort policy (see <VAR>SortPolicy</VAR> enumeration)
1381      */
1382     void SortByColumn(in long theColumn, in SortOrder theSortOrder, in SortPolicy theSortPolicy);
1383   };
1384
1385   //-------------------------------------------------------
1386   /*! \brief %PointMap3d representation interface
1387    *
1388    * Presentation parameters of the %Table Point Map in 3d view.
1389    */
1390   interface PointMap3d : ColoredPrs3dBase, ScaledPrs3d, Plot3dBase, Table {
1391   };
1392
1393   //-------------------------------------------------------
1394   /*! \brief Cut planes interface
1395    *
1396    * Presentation parameters of Cut planes presentation. This type of presentation
1397    * consists of cutting your initial mesh by a definite number of planes. As the
1398    * result you will see these planes which will be cutted by the borders of the mesh.
1399    */
1400   interface CutPlanes : ScalarMap, OptionalDeformation {
1401     /*!
1402      * This enumeration contains a set of elements defining the type of orientation in 3D space
1403      * of the cut planes.
1404      */
1405     enum Orientation {XY, /*!< The object is located in the plane formed by X and Y axis. */
1406                       YZ, /*!< The object is located in the plane formed by Y and Z axis. */
1407                       ZX}; /*!< The object is located in the plane formed by Z and X axis. */
1408
1409     /*!
1410      * Sets the type of orientation in 3D space of cut planes presentation.
1411      * \param theOrientation This parameter defines the type of orientation of cut planes
1412      *                       in 3D space. It is taken from the <VAR>Orientation</VAR> enumeration.
1413      * \param theXAngle The angle of rotation of the cut planes around
1414      *                  the first axis of the chosen orientation.
1415      * \param theXAngle The angle of rotation of the cut planes around
1416      *                  the second axis of the chosen orientation.
1417      */
1418     void SetOrientation(in Orientation theOrientation, in double theXAngle, in double theYAngle);
1419
1420     /*!
1421      * Gets the type of orientation in 3D space of cut planes presentation.
1422      */
1423     Orientation GetOrientationType();
1424
1425     /*!
1426      * Gets rotation angle of the cut plane presentation around the first axis of the chosen orientation.
1427      */
1428     double GetRotateX();
1429
1430     /*!
1431      * Gets rotation angle of the cut plane presentation around the second axis of the chosen orientation.
1432      */
1433     double GetRotateY();
1434
1435     /*!
1436      * Sets the displacement of the cut planes in 3D space.
1437      *
1438      * \param theDisp This parameter defines position of the cut planes
1439      * in 3D space. It varies from 0 to 1. If the chosen value is 0.5, the cut planes
1440      * will be evenly located regarding each other; in other words, the distance between all
1441      * of them will be equal. If the value is higher or lower than 0.5, the planes will be displaced
1442      * to one or another side.
1443      */
1444     void SetDisplacement(in double theDisp);
1445
1446     /*!
1447      * Gets the displacement of the cut planes in 3D space.
1448      */
1449     double GetDisplacement();
1450
1451     /*!
1452      * Sets the position of a definite cut plane.
1453      * \param thePlaneNumber The number of this cut plane.
1454      * \param thePlanePosition The position of this cut plane.
1455      */
1456      void SetPlanePosition(in long thePlaneNumber, in double thePlanePosition);
1457
1458     /*!
1459      * Sets the position of the choosen plane to default value.
1460      * \param thePlaneNumber The number of this cut plane.
1461      */
1462      void SetDefault(in long thePlaneNumber);
1463
1464     /*!
1465      * Gets the position of the choosen plane
1466      */
1467     double GetPlanePosition(in long thePlaneNumber);
1468
1469     /*!
1470      * Determines whether the choosen plane has default position.
1471      * \param thePlaneNumber The number of this cut plane.
1472      */
1473     boolean IsDefault(in long thePlaneNumber);
1474
1475     /*!
1476      * Sets the number of cut planes.
1477      * \param theNb The number of cut planes.
1478      */
1479     void SetNbPlanes(in long theNb);
1480
1481     /*!
1482      * Gets the number of cut planes.
1483      */
1484     long GetNbPlanes();
1485   };
1486
1487   //-------------------------------------------------------
1488   /*! \brief Base interface for Cut Lines and Cut Segment tools
1489    *
1490    */
1491   interface CutLinesBase : ScalarMap {
1492     /*!
1493      * Sets the number of cut lines.
1494      * \param theNb The number of cut lines.
1495      */
1496     void SetNbLines(in long theNb);
1497
1498     /*!
1499      * Gets the number of cut lines.
1500      */
1501     long GetNbLines();
1502
1503     /*! Invert all curves of corresponding table
1504      * \param theInvert - Invert all curves, if value is TRUE, else not.
1505      */
1506     void SetAllCurvesInverted(in boolean theInvert);
1507
1508     /*! Checks the orientation of all curves
1509      * \retval TRUE - if all curves are inverted, else FALSE
1510      */
1511     boolean IsAllCurvesInverted();
1512
1513     /*! Sets values which cutlines would be shown: aboslute or relative values
1514      * \param theAbsLength - boolean value, TRUE or false.
1515      */
1516     void SetUseAbsoluteLength(in boolean theAbsLength);
1517
1518     /*! Checks values of cutlines: using aboslute or relative values
1519      */
1520     boolean IsUseAbsoluteLength();
1521   };
1522
1523   //-------------------------------------------------------
1524   /*! \brief Cut lines presentation.
1525    *
1526    * Presentation parameters of a Cut lines presentation.
1527    * Cut Lines is a type of presentation which displays colored cells
1528    *   with applied scalar values on the mesh where lines are placed.
1529    * The procedure of construction of a Cut Lines presentation reuses the algorithm
1530    *   of creation of Cut Planes presentation and consists of two steps:
1531    *
1532    *   1. From Cut Planes presentation one plane is taken and
1533    *      it is used as base plane for construction of cut lines.
1534    *   2. This plane is cut by a regular array of planes. The result of this
1535    *      operation is a regular array of lines in space, belonging to the same plane
1536    *      and having the same orientation. They are located inside or on the mesh.
1537    */
1538   interface CutLines : CutLinesBase {
1539     /*!
1540      * Sets the type of orientation in 3D space of the base plane of a cut lines presentation.
1541      * \param theOrientation The orientation of the base plane in 3D space.
1542      * \param theXAngle The angle of rotation of the base plane around
1543      *                  the first axis of the chosen orientation.
1544      * \param theXAngle The angle of rotation of the base plane around
1545      *                  the second axis of the chosen orientation.
1546      */
1547     void SetOrientation(in CutPlanes::Orientation theOrientation, in double theXAngle, in double theYAngle);
1548
1549     /*!
1550      * Sets the type of orientation in 3D space of the cutting planes of a cut lines presentation.
1551      * \param theOrientation This parameter defines the type of orientation of the cutting planes
1552      *                       in 3D space. It is taken from the <VAR>Orientation</VAR> enumeration.
1553      * \param theXAngle The angle of rotation of the cutting planes
1554      *                  around the first axis of the chosen orientation.
1555      * \param theXAngle The angle of rotation of the cutting planes
1556      *                  around the second axis of the chosen orientation.
1557      */
1558     void SetOrientation2(in CutPlanes::Orientation theOrientation, in double theXAngle, in double theYAngle);
1559
1560     /*!
1561      * Gets the type of orientation in 3D space of the base plane of a cut lines presentation.
1562      */
1563     CutPlanes::Orientation GetOrientationType();
1564
1565     /*!
1566      * Gets the type of orientation in 3D space of the cutting planes of a cut lines presentation.
1567      */
1568     CutPlanes::Orientation GetOrientationType2();
1569
1570     /*!
1571      * Gets rotation angle of the base plane around the first axis of the chosen orientation.
1572      */
1573     double GetRotateX();
1574
1575     /*!
1576      * Gets rotation angle of the cutting planes around the first axis of the chosen orientation.
1577      */
1578     double GetRotateX2();
1579
1580     /*!
1581      * Gets rotation angle of the base plane around the second axis of the chosen orientation.
1582      */
1583     double GetRotateY();
1584
1585     /*!
1586      * Gets rotation angle of the cutting planes around the second axis of the chosen orientation.
1587      */
1588     double GetRotateY2();
1589
1590     /*!
1591      * Sets the displacement of the base plane of the cut lines presentation in 3D space.
1592      *
1593      * \param theDisp This parameter defines position of the base plane
1594      * in 3D space. It varies from 0 to 1.
1595      */
1596     void SetDisplacement(in double theDisp);
1597
1598     /*!
1599      * Sets the displacement of the cutting planes of the cut lines presentation in 3D space.
1600      *
1601      * \param theDisp This parameter defines position of the cutting planes
1602      * in 3D space. It varies from 0 to 1.
1603      */
1604     void SetDisplacement2(in double theDisp);
1605
1606     /*!
1607      * Gets the displacement of the base plane of the cut lines presentation in 3D space.
1608      */
1609     double GetDisplacement();
1610
1611     /*!
1612      * Gets the displacement of the cutting planes of the cut lines presentation in 3D space.
1613      */
1614     double GetDisplacement2();
1615
1616     /*! Sets the position of the base plane in 3D space.
1617      * \param thePlanePosition A double value defining the position of the base plane in 3D space.
1618      */
1619     void SetBasePlanePosition(in double thePlanePosition);
1620
1621     /*! Gets the position of the base plane in 3D space.
1622      */
1623     double GetBasePlanePosition();
1624
1625     /*! Sets the position of one of cutting planes in 3D space.
1626      * \param thePlaneNumber A long value defining the order number of this cutting plane.
1627      * \param thePlanePosition A double value defining the position of the base plane in 3D space.
1628      */
1629     void SetLinePosition(in long thePlaneNumber, in double thePlanePosition);
1630
1631     /*! Gets the position of one of cutting planes in 3D space.
1632      * \param thePlaneNumber A long value defining the order number of this cutting plane.
1633      */
1634     double GetLinePosition(in long thePlaneNumber);
1635
1636     /*! Sets the position of the base plane to default value.
1637      */
1638     void SetDefault();
1639
1640     /*!
1641      * Determines whether the base plane has default position.
1642      * \return True if the base plane has default position.
1643      */
1644     boolean IsDefault();
1645
1646     /*!
1647      * Sets the position of the choosen cutting plane to default value.
1648      * \param thePlaneNumber The number of this cutting plane.
1649      */
1650     void SetDefaultPosition(in long thePlaneNumber);
1651
1652     /*!
1653      * Determines whether the choosen cutting plane has default position.
1654      * \param thePlaneNumber The number of this cutting plane.
1655      * \return True if this cutting plane has default position.
1656      */
1657     boolean IsDefaultPosition(in long thePlaneNumber);
1658   };
1659
1660   //-------------------------------------------------------
1661   /*! \brief Cut segment presentation.
1662    *
1663    * Presentation parameters of a Cut segment presentation.
1664    * Cut Segment is a simplified variant of Cut Lines presentation, which is used
1665    * to display a single line instead of set of them. Axis of this line is defined
1666    * by coordinates of two points in 3D space.
1667    */
1668   interface CutSegment : CutLinesBase {
1669     /*!
1670      * Sets coordinates of the first point of axis of the segment.
1671      * \param theX X coordinate of the point
1672      * \param theY Y coordinate of the point
1673      * \param theZ Z coordinate of the point
1674      */
1675     void SetPoint1(in double theX, in double theY, in double theZ);
1676
1677     /*!
1678      * Gets coordinates of the first point of axis of the segment.
1679      * \param theX X coordinate of the point
1680      * \param theY Y coordinate of the point
1681      * \param theZ Z coordinate of the point
1682      */
1683     void GetPoint1(out double theX, out double theY, out double theZ);
1684
1685     /*!
1686      * Sets coordinates of the second point of axis of the segment.
1687      * \param theX X coordinate of the point
1688      * \param theY Y coordinate of the point
1689      * \param theZ Z coordinate of the point
1690      */
1691     void SetPoint2(in double theX, in double theY, in double theZ);
1692
1693     /*!
1694      * Gets coordinates of the second point of axis of the segment.
1695      * \param theX X coordinate of the point
1696      * \param theY Y coordinate of the point
1697      * \param theZ Z coordinate of the point
1698      */
1699     void GetPoint2(out double theX, out double theY, out double theZ);
1700   };
1701
1702   /*! \brief Interface of the stream lines representation
1703    *
1704    * This interface contains presentation parameters of stream lines presentations.
1705    * <BR>Stream lines is a type of presentation transforming into lines the
1706    * cells with vectors having most similar direction. A stream line can be thought
1707    * of as the path that a massless particle takes in a vector field.
1708    * Streamlines are used to convey the structure of a vector field.
1709    * Usually streamlines are created to explore the most interesting features in the field.
1710    */
1711   interface StreamLines : MonoColorPrs {
1712     /*! This enumerations contains a set of elements necessary
1713      * for definition of direction of the stream lines.
1714      */
1715     enum Direction{ FORWARD,
1716                     BACKWARD,
1717                     BOTH
1718     };
1719
1720     /*! Sets the parameters of the stream lines presentation.
1721      * \param theIntStep Inegration step is a parameter of smoothness of the stream lines.
1722      *                   This parameter defines the accuracy of construction of the streamlines.
1723      *                   A smaller value of this parameter allows to construct smoother
1724      *                   streamlines (at the cost of more computation time).
1725      * \param thePropogationTime This parameter controls the maximum length of
1726      *                           the stream line (measured in units of time).
1727      * \param theStepLength This parameter defines the size of the output line segments
1728      *                      that make up the streamline (which is represented as a polyline).
1729      * \param thePrs3d The source presentation. The points of the field located on this source
1730      *                 presentation will serve as starting points for generation of stream lines.
1731      * \note If this parameter is not defined, your stream lines
1732      *       presentation will be generated on all points of the field.
1733      * \param thePercents This parameter defines the quantity of points of the field
1734      *                    (from 0 to 100%) which will be used as starting points for
1735      *                    construction of the stream lines. Thus, the value of this
1736      *                    parameter can vary from 0 to 1.
1737      * \param theDirection Direction of the stream lines (Forward, Backward or Both).
1738      * \return True if all parameters are properly set.
1739      */
1740     boolean SetParams(in double theIntStep,
1741                       in double thePropogationTime,
1742                       in double theStepLength,
1743                       in Prs3d thePrs3d,
1744                       in double thePercents,
1745                       in Direction theDirection);
1746
1747     /*! Gets the value of integration step of the stream lines presentation.
1748      */
1749     double GetIntegrationStep();
1750
1751     /*! Gets the value of propagation time of the stream lines presentation.
1752      */
1753     double GetPropagationTime();
1754
1755     /*! Gets the value of step length of the stream lines presentation.
1756      */
1757     double GetStepLength();
1758
1759     /*! Returns the source presentation used for generation of the stream lines.
1760      */
1761     Prs3d GetSource();
1762
1763     /*! Gets the quantity of points of the field used as starting
1764      *  points for generation of the stream lines presentation.
1765      */
1766     double GetUsedPoints();
1767
1768     /*! Returns the direction of the stream lines.
1769      */
1770     Direction GetDirection();
1771   };
1772
1773   /*! \brief Interface of the isometric surface presentation
1774    *
1775    * This interface contains presentation parameters of
1776    * isometric surface presentations.
1777    * <BR>Iso surfaces presentation combines all equal scalar
1778    * values on the cells and on the basis of them constructs
1779    * isobaric surfaces, which form this presentation.
1780    */
1781   interface IsoSurfaces : MonoColorPrs {
1782     /*!
1783      * Sets the number of isometric surfaces.
1784      * \param theNb A long value defining the number of isometric surfaces
1785      *              which will be used for construction of this presentation.
1786      */
1787     void SetNbSurfaces(in long theNb);
1788
1789     /*!
1790      * Gets the number of isometric surfaces
1791      */
1792     long GetNbSurfaces();
1793
1794     /*!
1795      * Returns TRUE if labels with values are shown
1796      */
1797     boolean IsLabeled();
1798
1799     /*!
1800      * Set show or not value labels
1801      */
1802     void ShowLabels(in boolean theShow, in long theNb);
1803
1804     /*!
1805      * Returns Nb of labels per surface
1806      */
1807    long GetNbLabels();
1808
1809   };
1810
1811   //-------------------------------------------------------
1812   /*! \brief Interface of the vector presentation.
1813    *
1814    * This interface contains presentation parameters of vector presentations.
1815    */
1816   interface Vectors : DeformedShape {
1817     /*!
1818      * Sets the width of the lines of the vectors.
1819      * \param theWidth A double value defining the width of the lines of the vectors.
1820      */
1821     void SetLineWidth(in double theWidth);
1822
1823     /*!
1824      * Gets the width of the lines of the vectors.
1825      */
1826     double GetLineWidth();
1827
1828     /*!
1829      * This enumeration contains a set of elements defining the type of representation of the vector head.
1830      */
1831     enum GlyphType{ ARROW,
1832                     CONE2,
1833                     CONE6,
1834                     NONE
1835                   };
1836
1837     /*!
1838      * Sets the type of representation of the vector head.
1839      * \param theType This parameter defines the type of representation of the vector head.
1840      * This value is taken from the <VAR>GlyphType</VAR> enumeration.
1841      */
1842     void SetGlyphType(in GlyphType theType);
1843
1844     /*!
1845      * Gets the type of representation of the vector head.
1846      */
1847     GlyphType GetGlyphType();
1848
1849     /*!
1850      * This enumeration contains a set of elements defining the position of the vector head.
1851      */
1852     enum GlyphPos{ CENTER, /*!<In the center of the vector.*/
1853                    TAIL,   /*!<In the tail of the vector.*/
1854                    HEAD  /*!<In the head of the vector.*/
1855                  };
1856
1857     /*!
1858      * Sets the position of the vector head.
1859      * \param thePos This parameter defines the position of the vector head.
1860      * This value is taken from the <VAR>GlyphPos</VAR> enumeration.
1861      */
1862     void SetGlyphPos(in GlyphPos thePos);
1863
1864     /*!
1865      * Gets the position of the vector head.
1866      */
1867     GlyphPos GetGlyphPos();
1868   };
1869
1870   //-------------------------------------------------------
1871   /*! \brief %Animation class
1872    *
1873    * This class provides a set of methods used for:<br>
1874    * <ul>
1875    *     <li> generating different animations on the basis of a field,
1876    *     <li> setting the parameters of the animations,
1877    *     <li> playing these animations in the %VISU module.
1878    * </ul>
1879    * \note
1880    * <BR><B>Field</B> represents the results of calculations
1881    * (it can be scalar or vector values), grouped together under one physical concept.
1882    * <BR><B>Time stamp</B> represents a subfield: the results
1883    * of calculations are taken in one definite moment.
1884    */
1885   interface Animation : Base
1886   {
1887     /*!
1888    * This enumeration contains a set of available animation modes.
1889    */
1890     enum AnimationMode{ PARALLEL, /*!< parallel mode of animation. */
1891                         SUCCESSIVE /*!< succcessive mode of animation. */
1892     };
1893
1894     /*! Defines the field which will be used as a base for generation of the animation.
1895      * \param theObject The %SObject corresponding to the field.
1896      */
1897     boolean addField(in SALOMEDS::SObject theObject);
1898
1899     /*! Remove all fields from Animation object.
1900      */
1901     void clearFields();
1902
1903     /*! Generates presentations on the basis of the field.
1904      * \param theFieldNum The number of the field, which will be used
1905      *                    as the basis for construction of the presentation.
1906      */
1907     void generatePresentations(in long theFieldNum);
1908
1909     /*! Generates a set of frames from the created by the method
1910      *  <VAR>generatePresentations</VAR>3D presentations. A sequence of
1911      *  these frames will be transformed into an animation.
1912      *  \return  True, if the frames have been successfully generated.
1913      */
1914     boolean generateFrames();
1915
1916     /*! Clears the view before starting an animation.
1917      */
1918     void clearView();
1919
1920     /*! \name Playback of an animation:
1921      */
1922 /*@{*/
1923
1924     /*! Starts an animation.
1925      */
1926     void startAnimation();
1927
1928     /*! Stops an animation.
1929      */
1930     void stopAnimation();
1931
1932     /*! Forwards to the next frame.
1933      */
1934     void nextFrame();
1935
1936     /*! Returns to the previous frame.
1937      */
1938     void prevFrame();
1939
1940     /*! Returns to the first frame of the animation.
1941      */
1942     void firstFrame();
1943
1944     /*! Forwards to the last frame of the animation.
1945      */
1946     void lastFrame();
1947
1948     /*!  Passes to a definite frame of the animation.
1949      * \param theFrame A long value defining the number of the frame.
1950      */
1951     void gotoFrame(in long theFrame);
1952 /*@}*/
1953
1954     /*! Gets the number of time stamps (subfields) contained in the given field.
1955      */
1956     long getNbFields();
1957
1958     /*! Gets the number of generated frames
1959      */
1960     long getNbFrames();
1961
1962     /*! Returns True, if the animation is currently running.
1963      */
1964     boolean isRunning();
1965
1966     /*! Returns the number of the current frame.
1967      */
1968     long getCurrentFrame();
1969
1970     /*!
1971      */
1972     ColoredPrs3d getPresentation(in long theField, in long theFrame);
1973
1974     /*! Sets the type of presentation (vectors, deformed shape etc.)
1975      *  which will be generated by the method <VAR>generatePresentations</VAR>.
1976      *  \note \c addField() method should be called before in order to add field
1977      *  with number theFieldNum.
1978      */
1979     void setPresentationType(in long theFieldNum, in VISUType theType);
1980
1981     /*! Gets the type of presentation (vectors, deformed shape etc.) which will
1982      *  be generated by the method <VAR>generatePresentations</VAR>.
1983      *  \note \c addField() method should be called before in order to add field
1984      *  with number theFieldNum.
1985      */
1986     VISUType getPresentationType(in long theFieldNum);
1987
1988     /*! Sets the speed of the animation.
1989      * \param theSpeed The speed of the animation. The value varies from 1 to 99.
1990      */
1991     void setSpeed(in long theSpeed);
1992
1993     /*!  Gets the speed of the animation.
1994      */
1995     long getSpeed();
1996
1997     /*! Ruturns True, if playback of the animation is proportional.
1998      * This option allows to render your animation with proportional periods
1999      * of time between every frame (not depending on the time stamps).
2000      */
2001     boolean isProportional();
2002
2003     /*! Sets the range of the animation. The range is defined on the basis of
2004      *  the time stamps of the field which have been used for generation of the animation.
2005      *  This method allows to bound the range of generated frames.
2006      *  If this method is not used, the animation will be generated
2007      *  on the basis of all time stamps contained in the field.
2008      *  \param theMin The value of the first time stamp which will be used for generation of the animation.
2009      *  \param theMax The value of the last time stamp which will be used for generation of the animation.
2010      */
2011     void setAnimationRange(in double theMin, in double theMax);
2012
2013     /*! Gets the number of the first time stamp which will be used for generation of the animation.
2014      */
2015     double getMinRange();
2016
2017     /*! Gets the number of the last time stamp which will be used for generation of the animation.
2018      */
2019     double getMaxRange();
2020
2021     /*! Returns True if the range of the animation has been defined
2022      *  by the method <VAR>setAnimationRange</VAR>. Otherwise
2023      *  the animation will be generated on the basis of all time stamps contained in the field.
2024      */
2025     boolean isRangeDefined();
2026
2027     /*! Sets the sequence of the animation. The sequence is defined on the basis of
2028      *  the time stamps of the field which have been used for generation of the animation.
2029      *  This method allows to set the sequence of generated frames.
2030      *  If this method is not used, the animation will be generated
2031      *  on the basis of all time stamps contained in the field.
2032      *  Format of the sequence: '1,9,2-5,7-8'
2033      *  \param theSequence The sequence of time stamps indices which will be used for generation of the animation.
2034      */
2035     void setAnimationSequence(in string theSequence);
2036
2037     /*! Gets the animation sequence.
2038      */
2039     string getAnimationSequence();
2040
2041     /*! Returns True if the sequence of the animation has been defined
2042      *  by the method <VAR>setAnimationSequence</VAR>. Otherwise
2043      *  the animation will be generated on the basis of all time stamps contained in the field.
2044      */
2045     boolean isSequenceDefined();
2046
2047     /*! Saves all the frames composing the animation into a definite directory.
2048      *  Pictures format is set with method <VAR>setDumpFormat()</VAR>.
2049      *  \param thePath The directory where all the frames will be saved.
2050      */
2051     void dumpTo(in string thePath);
2052
2053     /*! Set format for saving all the frames composing the animation.
2054      *  \param theFormat The format for saving pictures.
2055      *                   For available formats see QImageIO documentation (Qt).
2056      *                   If specified format is not available, default format will be used.
2057      *                   Default format is JPEG or first of supported, if JPEG is not available.
2058      *  \return Really set format. Differ from \a theFormat if \a theFormat is not available.
2059      */
2060     string setDumpFormat(in string theFormat);
2061
2062     /*! Set frequency of timestamps used to generate AVI file.
2063      *  \param theFrequency The frequency of timestamps to use.
2064      */
2065     void setTimeStampFrequency(in long theFrequency);
2066
2067     /*! Get frequency of timestamps used to generate AVI file.
2068      *  \return The frequency of timestamps to use.
2069      */
2070     long getTimeStampFrequency();
2071
2072     /*! Returns True, if the playback of the animation is cycling.
2073      */
2074     boolean isCycling();
2075
2076     /*! Gets the first time stamp of the field defined at the input of the animation.
2077      * \note This method is used if animation range is <b>NOT</b> defined.
2078      */
2079     double getMinTime();
2080
2081     /*! Gets the last time stamp of the field defined at the input of the animation.
2082      * \note This method is used if animation range is <b>NOT</b> defined.
2083      */
2084     double getMaxTime();
2085
2086     /*! Sets proprtional playback of the animation. This option allows to render your animation
2087      *  with proportional periods of time between every frame (not depending on the time stamps).
2088      *  \param theProp If this boolean parameter is True, playback
2089      *                 of your animation will be set as proportional.
2090      */
2091     void setProportional(in boolean theProp);
2092
2093     /*! Sets cycling playback of the animation. The number of cycles
2094      *  can be infinite, untill you use <VAR>startAnimation</VAR> method.
2095      *  \param theCycle If this boolean parameter is True, playback
2096      *                  of your animation will be set as cycling.
2097      */
2098     void setCycling(in boolean theCycle);
2099
2100     boolean isCleaningMemoryAtEachFrame();
2101     void setCleaningMemoryAtEachFrame(in boolean theCycle);
2102
2103     SALOMEDS::SObject publishInStudy();
2104
2105     void saveAnimation();
2106
2107     void restoreFromStudy(in SALOMEDS::SObject theSObj);
2108
2109     boolean isSavedInStudy();
2110
2111     /*!
2112      * Sets the animation mode.
2113      * \param theMode The value of this parameter is taken from the <VAR>AnimationMode</VAR> enumeration.
2114      */
2115     void setAnimationMode(in AnimationMode theMode);
2116
2117     /*!
2118      * Gets the animation mode.
2119      */
2120     AnimationMode getAnimationMode();
2121
2122     /*!
2123      * Apply the presentation properties to all fields. The exception is raised in the following cases:
2124      * 1) presentations for the given field is not yet created;
2125      * 2) invalid dynamic cast of the given presentation to VISU::ColoredPrs3d_i;
2126      * 3) the MED file is not the same;
2127      * 4) the mesh name is not the same;
2128      * 5) the field name is not the same;
2129      * 6) the entity is not the same.
2130      */
2131     void ApplyProperties(in long theFieldNum, in ColoredPrs3d thePrs)
2132       raises (SALOME::SALOME_Exception);
2133   };
2134
2135
2136   //-------------------------------------------------------
2137   interface XYPlot;
2138
2139   //-------------------------------------------------------
2140   /*! \brief Interface %Evolution
2141    *
2142    */
2143   interface Evolution : Base
2144   {
2145     /*!
2146      * Defines the field which will be used as a base for generation of the evolution.
2147      * \param theObject The %SObject corresponding to the field.
2148      */
2149     boolean setField(in SALOMEDS::SObject theObject);
2150
2151     /*!
2152      * Sets id of the point for which the evolution will be generated.
2153      * \param thePointId id of the point.
2154      */
2155     void setPointId(in long thePointId);
2156
2157     /*!
2158      * Sets id of the component for which the evolution will be generated.
2159      * \param thePointId id of the component.
2160      */
2161     void setComponentId(in long theComponentId);
2162
2163     /*!
2164      * Shows the evolution.
2165      */
2166     boolean showEvolution();
2167
2168     /*!
2169      * Restores the evolution from study.
2170      * \param theSObj the study object from which the evolution should be restored.
2171      */
2172     void restoreFromStudy(in SALOMEDS::SObject theSObj);
2173   };
2174
2175
2176   /*! \brief Interface %Result
2177    *
2178    * This interface serves for inner representation of data generated
2179    * in other sources (MED object or file). This data is needed
2180    * for further construction of graphical presentations.
2181    */
2182   interface Result : RemovableObject, SALOME::GenericObj
2183   {
2184     /*! Reads all data from the corresponding sources. By default the data is loaded on demand.
2185      */
2186     boolean BuildAll();
2187
2188     /*! Start to parse the source MED file and publish all its entities into the study*/
2189     boolean Build(in boolean theIsBuildAll, in boolean theIsAtOnce);
2190
2191     /*! Allow to check is all requested MED entites already loaded or not */
2192     boolean IsDone();
2193
2194     /*! Allow to check is corresponding MED entites already loaded or not */
2195     boolean IsEntitiesDone();
2196
2197     /*! Choose to parse MED fields and perform global min / max on the MED timestamps.*/
2198     void SetBuildFields(in boolean theIsBuildFields, in boolean theIsCalculateMinMax);
2199
2200     /*! Allow to check is corresponding MED fields already loaded or not */
2201     boolean IsFieldsDone();
2202
2203     /*! Choose to parse MED groups.*/
2204     void SetBuildGroups(in boolean theIsBuildGroups);
2205
2206     /*! Allow to check is corresponding MED groups and families already loaded or not */
2207     boolean IsGroupsDone();
2208
2209     /*! Allow to check is min / max calculation over field's components already perfrormed or not */
2210     boolean IsMinMaxDone();
2211
2212     /*! Allow to check is corresponding multi resolution structure already loaded or not */
2213     boolean IsPartsDone();
2214
2215     typedef sequence<Entity> Entities;
2216
2217     typedef string EntityName;
2218
2219     typedef sequence<EntityName> EntityNames;
2220
2221     typedef long TimeStampNumber;
2222
2223     typedef sequence<TimeStampNumber> TimeStampNumbers;
2224
2225     enum Resolution {
2226       FULL,
2227       MEDIUM,
2228       LOW,
2229       HIDDEN
2230     };
2231
2232     typedef sequence<Resolution> Resolutions;
2233
2234     /*! Gets existing mesh names */
2235     EntityNames GetMeshNames();
2236
2237     /*! Gets existing mesh entites for the given mesh name */
2238     Entities GetEntities(in EntityName theMeshName);
2239
2240     /*! Gets existing families for the given mesh name and entity */
2241     EntityNames GetFamilies(in EntityName theMeshName, in Entity theEntity);
2242
2243     /*! Gets existing families for the given mesh name */
2244     EntityNames GetGroups(in EntityName theMeshName);
2245
2246     /*! Gets existing fields for the given mesh name and entity */
2247     EntityNames GetFields(in EntityName theMeshName, in Entity theEntity);
2248
2249     /*! Gets number of components for the given mesh name, entity and name of field */
2250     long GetNumberOfComponents(in EntityName theMeshName, in Entity theEntity, in EntityName theFieldName);
2251
2252     /*! Gets existing numbers of time stamps for the given mesh name, entity and name of field */
2253     TimeStampNumbers GetTimeStampNumbers(in EntityName theMeshName, in Entity theEntity,
2254                                          in EntityName theFieldName);
2255
2256     /*! Gets time values of time stamps for the given mesh name, entity and name of field */
2257     double_array GetTimeStampValues(in EntityName theMeshName, in Entity theEntity, in EntityName theFieldName);
2258
2259     /*! Gets existing parts of multi resolution structure for the given mesh name */
2260     EntityNames GetPartNames(in EntityName theMeshName);
2261
2262     /*! Gets available resolutions of multi resolution structure for the given mesh and part names */
2263     Resolutions GetResolutions(in EntityName theMeshName, in EntityName thePartName);
2264
2265     /*! Gets current resolution of multi resolution structure for the given mesh and part names */
2266     Resolution GetResolution(in EntityName theMeshName, in EntityName thePartName);
2267
2268     /*! Gets current resolution of multi resolution structure for the given mesh and part names */
2269     void SetResolution(in EntityName theMeshName, in EntityName thePartName, in Resolution theResolution);
2270
2271     /*! Gets information about imported MED file */
2272     SALOME_MED::MedFileInfo GetMEDFileInfo();
2273
2274     /*! Export MED file from temp object.  */
2275     boolean ExportMED(in string theFileName);
2276   };
2277
2278   //-------------------------------------------------------
2279   interface ViewManager;
2280
2281   /*! \brief %VISU_Gen interface
2282    *
2283    * This is the main interface of %VISU component. It is necessary for creation of
2284    * post-processing presentations from given %Result and %Table object reference,
2285    * using the views provided by %ViewManager.
2286    */
2287   interface VISU_Gen : Engines::EngineComponent, SALOMEDS::Driver, Base
2288   {
2289     /*! Sets a definite study to be current.
2290      */
2291     void SetCurrentStudy(in SALOMEDS::Study theStudy);
2292
2293     /*! Gets the current study.
2294      */
2295     SALOMEDS::Study GetCurrentStudy();
2296
2297     /*!
2298      * Gets the %View Manager which is used for creation of
2299      * post-processing presentations.
2300      */
2301     ViewManager GetViewManager();
2302
2303     /*!
2304      * Imports tables from a file and create TableAttribute in Study
2305      */
2306     SALOMEDS::SObject ImportTables(in string theFileName,
2307                                    in boolean theFirstStrAsTitle);
2308
2309     /*!
2310      * Export table to a file
2311      */
2312     boolean ExportTableToFile(in SALOMEDS::SObject theTable, in string theFileName);
2313
2314     /*!
2315      * Imports data from a file. The access to this file will be conserved outside of the application.
2316      * \param theFileName String parameter defining the name of the file
2317      *                    from which the data will be imported.
2318      */
2319     Result ImportFile(in string theFileName);
2320
2321     /*!
2322      * Create result and initialize its with the file. The access to this file will be conserved outside of the application.
2323      * \param theFileName String parameter defining the name of the file
2324      *                    from which the data will be imported.
2325      */
2326     Result CreateResult(in string theFileName);
2327
2328     /*!
2329      * Imports data from a file. The access to this file will closed.
2330      * \param theFileName String parameter defining the name of the file
2331      *                    from which the data will be imported.
2332      */
2333     Result CopyAndImportFile(in string theFileName);
2334
2335     /*!
2336      * Imports data from a %MED object.
2337      */
2338     Result ImportMed(in SALOMEDS::SObject theMedSObject);
2339
2340     /*!
2341      * Imports data from a %MED field.
2342      */
2343     Result ImportMedField(in SALOME_MED::FIELD theField);
2344
2345     /*!
2346      * Rename a study object, representing a mesh, specified by given values.
2347      * \param theResult   Data generated in other sources (MED object or file).
2348      * \param theMeshName One of the meshes presented in MED file.
2349      * \param theEntity   Type of entity where the field is defined.
2350      * \param theSubMeshName Name of sub-mesh (group or family).
2351      * \param theNewName  Name to be given to the study object.
2352      */
2353     void RenameEntityInStudy(in Result theResult,
2354                              in string theMeshName,
2355                              in Entity theEntity,
2356                              in string theNewName);
2357     void RenameFamilyInStudy(in Result theResult,
2358                              in string theMeshName,
2359                              in Entity theEntity,
2360                              in string theSubMeshName,
2361                              in string theNewName);
2362     void RenameGroupInStudy(in Result theResult,
2363                             in string theMeshName,
2364                             in string theSubMeshName,
2365                             in string theNewName);
2366
2367     /*!
2368      * Creates a mesh on the basis of the data generated in other sources (MED object or file).
2369      * \param theResult   Data generated in other sources. (MED object or file)
2370      * \param theMeshName  One of the meshes presented in MED file
2371      * \param theEntity Type of entity where the field is defined
2372      */
2373     Mesh MeshOnEntity(in Result theResult, in string theMeshName, in Entity theEntity);
2374
2375     /*!
2376      * Creates on the basis of a family a mesh  which will be composed of geometrical
2377      * elements, corresponding to the type of cells (node, edge, face or cell) of this family.
2378      * \param theResult   Data generated in other sources. (MED object or file)
2379      * \param theMeshName  One of the meshes presented in MED file
2380      * \param theEntity Type of entity where the field is defined.
2381      */
2382     Mesh FamilyMeshOnEntity(in Result theResult, in string theMeshName,
2383                             in Entity theEntity, in string theFamilyName);
2384
2385     /*!
2386      * Creates a mesh on the basis of a group of families.
2387      * \param theResult   Data generated in other sources. (MED object or file)
2388      * \param theMeshName  One of the meshes presented in MED file
2389      * \param theGroupName Name of the group.
2390      */
2391     Mesh GroupMesh(in Result theResult, in string theMeshName, in string theGroupName);
2392
2393     /*!
2394      * Creates a scalar map presentation.
2395      * \param theResult    Data generated in other sources. (MED object or file)
2396      * \param theMeshName  One of the meshes presented in MED file
2397      * \param theEntity    Type of entity where the field is defined
2398      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2399      * \param theTimeStampNumber Number of iteration on the field
2400      */
2401     ScalarMap ScalarMapOnField(in Result theResult, in string theMeshName,
2402                                in Entity theEntity, in string theFieldName,
2403                                in long theTimeStampNumber);
2404
2405     /*!
2406      * Creates a Gauss Points presentation.
2407      * \param theResult    Data generated in other sources. (MED object or file)
2408      * \param theMeshName  One of the meshes presented in MED file
2409      * \param theEntity    Type of entity where the field is defined
2410      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2411      * \param theTimeStampNumber Number of iteration on the field
2412      */
2413     GaussPoints GaussPointsOnField(in Result theResult, in string theMeshName,
2414                                    in Entity theEntity, in string theFieldName,
2415                                    in long theTimeStampNumber);
2416
2417     /*!
2418      * Creates a deformed shape presentation.
2419      * \param theResult    Data generated in other sources. (MED object or file)
2420      * \param theMeshName  One of the meshes presented in MED file
2421      * \param theEntity    Type of entity where the field is defined
2422      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2423      * \param theTimeStampNumber Number of iteration on the field
2424      */
2425     DeformedShape DeformedShapeOnField(in Result theResult, in string theMeshName,
2426                                        in Entity theEntity, in string theFieldName,
2427                                        in long theTimeStampNumber);
2428
2429     /*!
2430      * Creates a deformed shape presentation. This function is obsolete. Use DeformedShapeAndScalarMapOnField instead.
2431      * \param theResult    Data generated in other sources. (MED object or file)
2432      * \param theMeshName  One of the meshes presented in MED file
2433      * \param theEntity    Type of entity where the field is defined
2434      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2435      * \param theTimeStampNumber Number of iteration on the field
2436      */
2437     DeformedShapeAndScalarMap ScalarMapOnDeformedShapeOnField(in Result theResult, in string theMeshName,
2438                                                               in Entity theEntity, in string theFieldName,
2439                                                               in long theTimeStampNumber);
2440
2441     /*!
2442      * Creates a deformed shape presentation.
2443      * \param theResult    Data generated in other sources. (MED object or file)
2444      * \param theMeshName  One of the meshes presented in MED file
2445      * \param theEntity    Type of entity where the field is defined
2446      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2447      * \param theTimeStampNumber Number of iteration on the field
2448      */
2449     DeformedShapeAndScalarMap DeformedShapeAndScalarMapOnField(in Result theResult, in string theMeshName,
2450                                                                in Entity theEntity, in string theFieldName,
2451                                                                in long theTimeStampNumber);
2452
2453     /*!
2454      * Creates a vector presentation.
2455      * \param theResult    Data generated in other sources. (MED object or file)
2456      * \param theMeshName  One of the meshes presented in MED file
2457      * \param theEntity    Type of entity where the field is defined
2458      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2459      * \param theTimeStampNumber Number of iteration on the field
2460      */
2461     Vectors VectorsOnField(in Result theResult, in string theMeshName,
2462                            in Entity theEntity, in string theFieldName,
2463                            in long theTimeStampNumber);
2464
2465     /*!
2466      * Creates an iso surface presentation.
2467      * \param theResult    Data generated in other sources. (MED object or file)
2468      * \param theMeshName  One of the meshes presented in MED file
2469      * \param theEntity    Type of entity where the field is defined
2470      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2471      * \param theTimeStampNumber Number of iteration on the field
2472      */
2473     IsoSurfaces IsoSurfacesOnField(in Result theResult, in string theMeshName,
2474                                    in Entity theEntity, in string theFieldName,
2475                                    in long theTimeStampNumber);
2476
2477     /*!
2478      * Creates an stream lines presentation.
2479      * \param theResult    Data generated in other sources. (MED object or file)
2480      * \param theMeshName  One of the meshes presented in MED file
2481      * \param theEntity    Type of entity where the field is defined
2482      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2483      * \param theTimeStampNumber Number of iteration on the field
2484      */
2485     StreamLines StreamLinesOnField(in Result theResult, in string theMeshName,
2486                                    in Entity theEntity, in string theFieldName,
2487                                    in long theTimeStampNumber);
2488
2489     /*!
2490      * Creates a presentation of cut planes.
2491      * \param theResult    Data generated in other sources. (MED object or file)
2492      * \param theMeshName  One of the meshes presented in MED file
2493      * \param theEntity    Type of entity where the field is defined
2494      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2495      * \param theTimeStampNumber Number of iteration on the field
2496      */
2497     CutPlanes CutPlanesOnField(in Result theResult, in string theMeshName,
2498                                in Entity theEntity, in string theFieldName,
2499                                in long theTimeStampNumber);
2500
2501     /*!
2502      * Creates a presentation of cut lines.
2503      * \param theResult    Data generated in other sources. (MED object or file)
2504      * \param theMeshName  One of the meshes presented in MED file
2505      * \param theEntity    Type of entity where the field is defined
2506      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2507      * \param theTimeStampNumber Number of iteration on the field
2508      */
2509     CutLines CutLinesOnField(in Result theResult, in string theMeshName,
2510                              in Entity theEntity, in string theFieldName,
2511                              in long theTimeStampNumber);
2512
2513     /*!
2514      * Creates a presentation of cut segment.
2515      * \param theResult    Data generated in other sources. (MED object or file)
2516      * \param theMeshName  One of the meshes presented in MED file
2517      * \param theEntity    Type of entity where the field is defined
2518      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2519      * \param theTimeStampNumber Number of iteration on the field
2520      */
2521     CutSegment CutSegmentOnField(in Result theResult, in string theMeshName,
2522                                  in Entity theEntity, in string theFieldName,
2523                                  in long theTimeStampNumber);
2524
2525     /*!
2526      * Creates a Plot3D presentation.
2527      * \param theResult    Data generated in other sources. (MED object or file)
2528      * \param theMeshName  One of the meshes presented in MED file
2529      * \param theEntity    Type of entity where the field is defined
2530      * \param theFieldName Group of data attributed to the %MESH. The data can be scalar or vector.
2531      * \param theTimeStampNumber Number of iteration on the field
2532      */
2533     Plot3D Plot3DOnField(in Result theResult, in string theMeshName,
2534                          in Entity theEntity, in string theFieldName,
2535                          in long theTimeStampNumber);
2536
2537     /*!
2538      * Creates a table presentation.
2539      * \param theTableEntry The entry of the table which will be displayed.
2540      */
2541     Table CreateTable(in string theTableEntry);
2542
2543     /*!
2544      * Creates a curve on the basis of points, whose values are taken from the table.
2545      * \param theTable  Table containing the data for construction of curves.
2546      * \param theHRow   Index of the row in the table: abscissa of the point.
2547      * \param theVRow   Index of the row in the table: ordinate of the point.
2548      */
2549     Curve CreateCurve(in Table theTable, in long theHRow, in long theVRow);
2550
2551     /*!
2552      * Creates a curve on the basis of points, whose values are taken from the table.
2553      * Each point has also assigned value, that will be shown as tooltip in Plot2d
2554      * \param theTable  Table containing the data for construction of curves.
2555      * \param theHRow   Index of the row in the table: abscissa of the point.
2556      * \param theVRow   Index of the row in the table: ordinate of the point.
2557      * \param theZRow   Index of the row in the table: assigned value (so-called as Z).
2558      */
2559     Curve CreateCurveWithZ( in Table theTable, in long theHRow, in long theVRow, in long theZRow );
2560
2561     /*!
2562      * Creates a curve on the basis of points, whose values are taken from the table.
2563      * Each point has also assigned value, that will be shown as tooltip in Plot2d.
2564      * The curve can be displayed using right axis of Plot2d view.
2565      * \param theTable  Table containing the data for construction of curves.
2566      * \param theHRow   Index of the row in the table: abscissa of the point.
2567      * \param theVRow   Index of the row in the table: ordinate of the point.
2568      * \param theZRow   Index of the row in the table: assigned value (so-called as Z).
2569      * \param theIsV2   Flag allowed to display the curve using right axis of Plot2d view.
2570      */
2571     Curve CreateCurveWithZExt( in Table theTable, in long theHRow, in long theVRow, in long theZRow,
2572                                in boolean theIsV2 );
2573
2574     /*!
2575      * Creates a presentation form containing an array of references to the curves.
2576      */
2577     Container CreateContainer();
2578
2579     /*! Creates an animation in the 3D view.
2580      * \param theView3d The 3D view, where the animation will be rendered.
2581      */
2582     Animation CreateAnimation(in View3D theView3d);
2583
2584     /*! Creates an evolution in the XY plot.
2585      * \param theXYPlot The XY plot, where the evolution will be rendered.
2586      */
2587     Evolution CreateEvolution(in XYPlot theXYPlot);
2588
2589     void DeleteResult(in Result theResult);
2590
2591     void DeletePrs3d(in Prs3d thePrs3d);
2592
2593     /*!
2594      * Get or create %ColoredPrs3dCache object.
2595      */
2596     ColoredPrs3dCache GetColoredPrs3dCache(in SALOMEDS::Study theStudy);
2597
2598
2599     /* Clipping planes management */
2600
2601     /*Create a clipping plane and return its ID (position in corresponded array)
2602       Id of clipping plane could be changed after deletion of other clipping plane
2603     */
2604     long CreateClippingPlane(in double X, in double Y, in double Z,
2605                              in double dX, in double dY, in double dZ,
2606                              in boolean auto, in string name);
2607
2608     void EditClippingPlane(in long id, in double X, in double Y, in double Z,
2609                              in double dX, in double dY, in double dZ,
2610                              in boolean auto, in string name);
2611
2612     /* Returns clipping plane by its Id */
2613     ClippingPlane GetClippingPlane(in long id);
2614
2615     /* Deletes clipping plane by its Id */
2616     boolean DeleteClippingPlane(in long id);
2617
2618     /* Applyes a clipping plane with Id to presentation thePrs */
2619     boolean ApplyClippingPlane(in Prs3d thePrs, in long id);
2620
2621     /* Detaches a clipping plane with Id from presentation thePrs */
2622     boolean DetachClippingPlane(in Prs3d thePrs, in long id);
2623
2624
2625     /* Get number of clipping planes */
2626     long GetClippingPlanesNb();
2627
2628     /*! Converts set of VTK files to the one MED-file
2629      * \param theVTKFiles sequence of VTK files
2630      * \param out MED-file
2631      * \param theMeshName mesh name. This parameter can be empty. In this case name
2632               of mesh is equal vtk2med
2633      * \param theTSNames values of time stamps. This array can be empty, in
2634               this case values of time stamps will be generated automatically ( 0, 1, 2 ... )
2635      * \return TRUE if operation has been completed successfully, FALSE otherwise
2636      */
2637     boolean VTK2MED( in string_array theVTKFiles,
2638                      in string theMEDFile,
2639                      in string theMeshName,
2640                      in double_array theTStamps );
2641
2642     /*!
2643      * Load texture from file
2644      * \param theTextureFile texture file name
2645      * \return unique texture identifier
2646      */
2647     long LoadTexture(in string theTextureFile);
2648   };
2649
2650   /*! \brief %View interface
2651    *
2652    * Contains a set of methods used by the %View frame, which can be one of
2653    * the following types: 3d, Table, XY plot.
2654    * %View interface is a base for all types of %view interfaces.
2655    */
2656   interface View: Base, SALOME::GenericObj
2657   {
2658     /*! \brief %ViewRepresentation enumeration
2659      *
2660      * displaying part ("ALL" isn't setable)
2661      */
2662     enum ViewRepresentation {
2663       OBJECTBROWSER,
2664       VIEWER,
2665       PYTHON,
2666       MESSAGES
2667     };
2668
2669     void ShowPart (in ViewRepresentation ViewRepr, in boolean state );
2670
2671     boolean IsPartShown( in ViewRepresentation ViewRepr );
2672
2673     /*!
2674      *  New methods for view parameters management.
2675      */
2676
2677     /*! \brief Split workarea of this view.
2678      *
2679      *  Horizontally split workarea of this view.
2680      *  This view is moved in a new right area.
2681      */
2682     void SplitRight();
2683
2684     /*! \brief Split workarea of this view.
2685      *
2686      *  Horizontally split workarea of this view.
2687      *  This view stays in an old left area, others are moved in a new right area.
2688      */
2689     void SplitLeft();
2690
2691     /*! \brief Split workarea of this view.
2692      *
2693      *  Vertically split workarea of this view.
2694      *  This view is moved in a new bottom area.
2695      */
2696     void SplitBottom();
2697
2698     /*! \brief Split workarea of this view.
2699      *
2700      *  Vertically split workarea of this view.
2701      *  This view stays in an old top area, others are moved in a new bottom area.
2702      */
2703     void SplitTop();
2704
2705     /*!
2706      *  Put this view window on top of its work area.
2707      */
2708     void OnTop();
2709
2710     /*!
2711      *  Put \a theView in workarea of this view right after it.
2712      *  If \a theView was alone in its workarea, workarea of \a theView will be destroyed.
2713      *  If \a theView was in the same workarea with this view, simple reordering will take place.
2714      *  \param theView A view window to be attracted to this one.
2715      */
2716     void Attract (in View theView);
2717
2718     /*!
2719      *  Put all the view windows from workarea of \a theView in workarea of this view right after it.
2720      *  Workarea of \a theView will be destroyed.
2721      *  If \a theView was in the same workarea with this view, simple reordering will take place.
2722      *  \param theView A view window to be attracted to this one together with all its workarea.
2723      */
2724     void AttractAll (in View theView);
2725
2726     /*!
2727      *  Set position of this view window relatively its splitter.
2728      *  \param thePosition Desired position of this view window relatively
2729      *         its splitter. Meaningfull values lays in range [0..1].
2730      *
2731      *  Direction of positioning is defined by the splitter orientation.
2732      */
2733     void SetRelativePositionInSplitter (in double thePosition);
2734
2735     /*!
2736      *  Set size of this view window relatively its splitter.
2737      *  \param theSize Desired size of this view window relatively
2738      *         its splitter. Meaningfull values lays in range [0..1].
2739      *
2740      *  Direction of resizing is defined by the splitter orientation.
2741      */
2742     void SetRelativeSizeInSplitter (in double theSize);
2743
2744     /*!
2745      *  Set horizontal position of this view window relatively its workstack.
2746      *  \param thePosition Desired horizontal position of this view window
2747      *         relatively its workstack. Meaningfull values lays in range [0..1].
2748      */
2749     void SetRelativePositionX (in double thePosition);
2750
2751     /*!
2752      *  Set vertical position of this view window relatively its workstack.
2753      *  \param thePosition Desired vertical position of this view window
2754      *         relatively its workstack. Meaningfull values lays in range [0..1].
2755      */
2756     void SetRelativePositionY (in double thePosition);
2757
2758     /*!
2759      *  Set horizontal size of this view window relatively its workstack.
2760      *  \param theSize Desired horizontal size of this view window relatively
2761      *         its workstack. Meaningfull values lays in range [0..1].
2762      */
2763     void SetRelativeSizeX (in double theSize);
2764
2765     /*!
2766      *  Set vertical size of this view window relatively its workstack.
2767      *  \param theSize Desired vertical size of this view window relatively
2768      *         its workstack. Meaningfull values lays in range [0..1].
2769      */
2770     void SetRelativeSizeY (in double theSize);
2771
2772     /*!
2773      *  Old methods for view parameters management, they don't work now
2774      */
2775     void SetViewWidth (in long Width); //setting width of view
2776     void SetViewHeight (in long Height); //setting height of view
2777     long GetViewWidth(); //getting view width
2778     long GetViewHeight(); //getting view height
2779     enum ViewPosition {TOP, CENTER, BOTTOM, RIGHT, LEFT}; //position of the study frame
2780     void SetViewPositionHorizontal (in ViewPosition ViewPosHor); //setting of the horizontal view position
2781     void SetViewPositionVertical (in ViewPosition ViewPosVer); //setting of the vertical view position
2782     void SetRelativePosition( in double x, in double y );
2783     void SetRelativeSize( in double x, in double y );
2784     void Minimize(); // Minimizes to the task bar or to the bottom of the Desktop the %View frame.
2785     void Restore(); // Restores the %View frame.
2786     void Maximize(); // Maximizes the %View frame.
2787
2788     /*!
2789      * Sets the title of the %View frame.
2790      * \param theTitle String parameter defining the title of the %View frame.
2791      */
2792     void SetTitle(in string theTitle);
2793
2794     /*!
2795      * Gets the title of the %View frame.
2796      */
2797     string GetTitle();
2798
2799     /*!
2800      * Sets background color of the %View frame.
2801      * \param theColor Background color defined in <VAR>SALOMEDS::Color</VAR> enumeration.
2802      */
2803     void SetBackground(in SALOMEDS::Color theColor);
2804
2805     /*!
2806      * Gets background color of the %View frame.
2807      */
2808     SALOMEDS::Color GetBackground();
2809
2810     /*!
2811      * Removes all presentations (presentable objects) from the %view.
2812      */
2813     void EraseAll();
2814
2815     /*!
2816      * Displays all presentations (presentable objects) in the %view.
2817      */
2818     void DisplayAll();
2819
2820     /*!
2821      * Removes a definite presentation (presentable object) from the %view.
2822      * \param thePrsObj The presentation (presentable object) which should be deleted.
2823      */
2824     void Erase(in PrsObject thePrsObj);
2825
2826     /*!
2827      * Displays a definite presentation (presentable object) in the %view.
2828      * \param thePrsObj The presentation (presentable object) which should be displayed.
2829      */
2830     void Display(in PrsObject thePrsObj);
2831
2832     /*!
2833      * Allows to display only a definite presentation (presentable object) in the %view.
2834      * All other presentations are removed from the %view.
2835      * \param thePrsObj The presentation (presentable object) which should be displayed.
2836      */
2837     void DisplayOnly(in PrsObject thePrsObj);
2838
2839     /*!
2840      * Updates the view.
2841      */
2842     void Update();
2843
2844     /*!
2845      * Saves the view.
2846      * \param theFileName The name of the file where the view will be saved.
2847      * \return True, if the view have been saved successfully.
2848      */
2849     boolean SavePicture(in string theFileName);
2850   };
2851
2852   //-------------------------------------------------------
2853   /*! \brief 3D view interface
2854    *
2855    *  This interface contains a set of methods necessary for representation of objects in 3D space.
2856    */
2857   interface View3D : View {
2858     /*!
2859      * This enumeration contains a set of elements determining a predefined point of view
2860      *  (position of the camera in 3D space relative to the presentable object).
2861      */
2862     enum ViewType{ FRONT, BACK, LEFT, RIGHT, TOP, BOTTOM};
2863
2864     /*!
2865      * This enumeration contains a set of elements determining the axis
2866      */
2867     enum Axis{ XAxis, YAxis, ZAxis};
2868
2869     /*!
2870      * Data type defining coordinates in 3D space.
2871      */
2872     typedef double XYZ[3];
2873
2874     /*!
2875      * Makes all presentations, which are currently present in the %view, completely visible.
2876      */
2877     void FitAll();
2878
2879     /*!
2880      * Sets a predefined point of view (FRONT, BACK, LEFT, RIGHT, TOP, BOTTOM). (In other words it means
2881      * a predefined position of the camera in 3D space with respect to the object which is represented.)
2882      */
2883     void SetView(in ViewType theType);
2884
2885     /*!
2886      * Sets the position of the camera in 3D space.
2887      * This point is used as the first point of the vector
2888      * defining the view direction of the camera.
2889      */
2890     void SetPointOfView(in XYZ theCoord);
2891
2892     /*!
2893      * Gets the position of the camera in 3D space.
2894      * This point is used as the first point of the vector
2895      * defining the view direction of the camera.
2896      */
2897     XYZ GetPointOfView();
2898
2899     /*!
2900      * Sets the vertical line of the camera in 3D space.
2901      */
2902     void SetViewUp(in XYZ theDir);
2903
2904     /*!
2905      * Gets the vertical line of the camera in 3D space.
2906      */
2907     XYZ GetViewUp();
2908
2909     /*!
2910      * Sets the point of sight of the camera. This point is used as the
2911      * second point of the vector defining the view direction of the camera.
2912      */
2913     void SetFocalPoint(in XYZ theDir);
2914
2915     /*!
2916      * Gets the point of sight of the camera. This point is used as the
2917      * second point of the vector defining the view direction of the camera.
2918      */
2919     XYZ GetFocalPoint();
2920
2921     /*!
2922      * Zooming of the presentable object. Sets the scale.
2923      */
2924     void SetParallelScale(in double theScale);
2925
2926     /*!
2927      * Zooming of the presentable object. Gets the scale.
2928      */
2929     double GetParallelScale();
2930
2931     /*!
2932      * Scaling of the view along a definite axis.
2933      * \param theAxis The axis of the scaling
2934      * \param theParam The coefficient of the scaling
2935      */
2936     void ScaleView(in Axis theAxis, in double theParam);
2937
2938     /*!
2939      * Removes the scaling of the view.
2940      */
2941     void RemoveScale();
2942
2943     /*!
2944      * Saves view parameters.
2945      * \return True if the view parameters have been created, False if the parameters have been modified.
2946      * \param theName The name under which the view parameters will be saved.
2947      */
2948     boolean SaveViewParams(in string theName);
2949
2950     /*! Restores view parameters.
2951      * \return True if the view parameters have been found and applied to the view,
2952      * False if the parameters with this name don't exist.
2953      * \param theName The name of the view parameters which will be restored.
2954      */
2955     boolean RestoreViewParams(in string theName);
2956
2957
2958     /*! Get representation type of the given presentation in this view.
2959      *  \param thePrs Object to get a representation type of.
2960      *  \return <VAR>PresentationType</VAR> Representation type of object in this view.
2961      */
2962     PresentationType GetPresentationType(in ScalarMap thePrs);
2963
2964     /*! Set representation type of the given presentation in this view.
2965      *  \param thePrs Object to set a representation type of.
2966      *  \param thePrsType Representation type to be set to the given object.
2967      *  \return Empty string in case of success, error description in case of failure.
2968      */
2969     string SetPresentationType(in ScalarMap thePrs, in PresentationType thePrsType);
2970
2971
2972     /*! Set representation type of 2D quadratic elements
2973      *  of the given presentation in this view.
2974      *  \param thePrs Object to set a representation type of 2D quadratic elements.
2975      *  \param theType Representation type of 2D quadratic elements to be set to the given object.
2976      *  \return Empty string in case of success, error description in case of failure.
2977      */
2978     string SetQuadratic2DPresentationType(in ScalarMap thePrs,in Quadratic2DPresentationType theType);
2979
2980
2981     /*! Get representation type of the 2D quadratic mesh elements of given presentation in this view.
2982      *  \param thePrs Object to get a representation type of 2D quadratic mesh elements.
2983      *  \return <VAR>Quadratic2DPresentationType</VAR> Representation type of 2D quadratic mesh elements
2984      *          in this view.
2985      */
2986     Quadratic2DPresentationType GetQuadratic2DPresentationType(in ScalarMap thePrs);
2987
2988
2989     /*! Get shrink state of the given presentation in this view.
2990      *  \param thePrs Object to get a shrink state of.
2991      *  \return TRUE if \a thePrs is shrinked in this view, FALSE overwise.
2992      */
2993     boolean IsShrinked(in ScalarMap thePrs);
2994
2995     /*! Make the given presentation shrinked or not shrinked in this view.
2996      *  \param thePrs Object to change a shrink state of.
2997      *  \param isShrinked Pass TRUE to make \a thePrs shrinked, FALSE overwise.
2998      *  \return Empty string in case of success, error description in case of failure.
2999      */
3000     string SetShrinked(in ScalarMap thePrs, in boolean isShrinked);
3001
3002     /*! Get shading state of the given presentation in this view.
3003      *  \param thePrs Object to get a shading state of.
3004      *  \return TRUE if \a thePrs is shaded in this view, FALSE overwise.
3005      */
3006     boolean IsShaded(in ScalarMap thePrs);
3007
3008     /*! Make the given presentation shaded or not shaded in this view.
3009      *  \param thePrs Object to set a shading state of.
3010      *  \param isShaded Pass TRUE to make \a thePrs shaded, FALSE overwise.
3011      *  \return Empty string in case of success, error description in case of failure.
3012      */
3013     string SetShaded(in ScalarMap thePrs, in boolean isShaded);
3014
3015     /*! Get opacity of the given presentation in this view.
3016      *  \param thePrs Object to get an opacity of.
3017      *  \return Opacity value in range [0, 1], 0 - transparent, 1 - opaque.
3018      */
3019     double GetOpacity(in ScalarMap thePrs);
3020
3021     /*! Set opacity of the given presentation in this view.
3022      *  \param thePrs Object to set an opacity of.
3023      *  \param theOpacity Opacity value [0, 1]. 0 - transparent, 1 - opaque.
3024      *  \return Empty string in case of success, error description in case of failure.
3025      */
3026     string SetOpacity(in ScalarMap thePrs, in double theOpacity);
3027
3028     /*! Get line width of the given presentation in this view.
3029      *  \param thePrs Object to get a line width of.
3030      *  \return Line width of \a thePrs in this view.
3031      */
3032     double GetLineWidth(in ScalarMap thePrs);
3033
3034     /*! Set line width of the given presentation in this view.
3035      *  \param thePrs Object to set a line width of.
3036      *  \param theLineWidth Line width value. Recommended values are in range [1, 10].
3037      *  \return Empty string in case of success, error description in case of failure.
3038      */
3039     string SetLineWidth(in ScalarMap thePrs, in double theLineWidth);
3040   };
3041
3042   //-------------------------------------------------------
3043   /*! \brief Interface of the Table view
3044    *
3045    * This interface is used for creation of a view necessary for presentation of a table.
3046    */
3047   interface TableView : View {
3048   };
3049
3050   //-------------------------------------------------------
3051   /*! \brief Interface of the 2D plot view
3052    *
3053    * This interface is used for creation of a view necessary for presentation
3054    * of a XY plot generated on the basis of one or several curve lines.
3055    */
3056   interface XYPlot : View {
3057     /*! Sets the title of the XY plot
3058      * \param theTitle  The title of the XY plot
3059      */
3060     void SetSubTitle(in string theTitle);
3061
3062     /*! Gets the title of the XY plot
3063      */
3064     string GetSubTitle();
3065
3066     /*!
3067      * This enumeration contains a set of elements determining the type
3068      * of the curve lines, which will be displayed in your XY plot.
3069      */
3070     enum CurveType { POINTS, MULTYLINE, SPLINE};
3071
3072     /*! Sets the type of the curve lines.
3073      * \param theType The type of the curve lines taken from <VAR>CurveType</VAR> enumeration.
3074      */
3075     void SetCurveType(in CurveType theType);
3076
3077     /*! Gets the type of the curve lines.
3078      */
3079     CurveType GetCurveType();
3080
3081     /*! Sets the size of the markers (data points) with help of
3082      * which the curve is constructed on the graphics.
3083      * \param theSize Long value defining the size of the markers.
3084      */
3085     void SetMarkerSize(in long theSize);
3086
3087     /*! Gets the size of the markers (data points) with help of
3088      * which the curve is constructed on the graphics.
3089      */
3090     long GetMarkerSize();
3091
3092     /*! Enable/disables X-axis grid of the 2D plot.
3093      */
3094     void EnableXGrid(in boolean theMajor, in long theNumMajor, in boolean theMinor, in long theNumMinor);
3095
3096     /*! Enable/disables Y-axis grid of the 2D plot.
3097      */
3098     void EnableYGrid(in boolean theMajor, in long theNumMajor, in boolean theMinor, in long theNumMinor);
3099
3100     /*! Sets horizontal scaling of the 2D plot.
3101      * \param theScaling Type of scaling taken from <VAR>Scaling</VAR> enumeration.
3102      */
3103     void SetHorScaling(in Scaling theScaling);
3104
3105     /*! Gets the type horizontal scaling of the 2D plot.
3106      */
3107     Scaling GetHorScaling();
3108
3109     /*! Sets vertical scaling of the 2D plot.
3110      * \param theScaling Type of scaling taken from <VAR>Scaling</VAR> enumeration.
3111      */
3112     void SetVerScaling(in Scaling theScaling);
3113
3114     /*! Gets the type vertical scaling of the 2D plot.
3115      */
3116     Scaling GetVerScaling();
3117
3118     /*! Sets the title of the X-axis of the plot.
3119      * \param theTitle String value defining the title of the X-axis of the plot.
3120      */
3121     void SetXTitle(in string theTitle);
3122
3123     /*! Gets the title of the X-axis of the plot.
3124      */
3125     string GetXTitle();
3126
3127     /*! Sets the title of the Y-axis of the plot.
3128      * \param theTitle String value defining the title of the X-axis of the plot.
3129      */
3130     void SetYTitle(in string theTitle);
3131
3132     /*! Gets the title of the Y-axis of the plot.
3133      */
3134     string GetYTitle();
3135
3136     /*! Shows/hides the legend (description) of the 2D plot.
3137      */
3138     void ShowLegend(in boolean theShowing);
3139
3140     /*! Shrinks and enlarges the 2D plot to fit the 2D viewer.
3141      */
3142     void FitAll();
3143
3144     /*! Set range of the 2D plot to X axis of the 2D viewer.
3145      */
3146     void FitXRange(in double xMin, in double xMax);
3147
3148     /*! Set range of the 2D plot to Y axis of the 2D viewer.
3149      */
3150     void FitYRange(in double yMin, in double yMax);
3151
3152     /*! Set range of the 2D plot to XY axis of the 2D viewer.
3153      */
3154     void FitRange(in double xMin, in double xMax,
3155                   in double yMin, in double yMax);
3156
3157     void GetFitRanges(out double xMin,out double xMax,
3158                       out double yMin,out double yMax);
3159   };
3160
3161   //-------------------------------------------------------
3162   /*! \brief Interface of the %ViewManager
3163    *
3164    * The ViewManager is necessary for work with view windows (creation and deletion).
3165    */
3166   interface ViewManager: Base {
3167     /*! \brief Getting an active %View Frame
3168      *
3169      * Returns an object reference to the active %View Frame.
3170      * Type of the %View must be checked.
3171      * \note <BR>Returns nil if there are no views currently opened.
3172      */
3173     View GetCurrentView();
3174
3175     /*! \brief Creation of a 3d %View.
3176      *
3177      * Returns an object reference to the newly created 3D %View.
3178      */
3179     View3D Create3DView();
3180
3181     /*! \brief Creation of a Table %View.
3182      *
3183      * Returns an object reference to the newly created Table %View.
3184      */
3185     TableView CreateTableView(in Table theTable);
3186
3187     /*! \brief Creation of a 2D plot %View.
3188      *
3189      * Returns an object reference to the newly created 2D plot %View.
3190      */
3191     XYPlot CreateXYPlot();
3192
3193     /*! Deletes a definite view.
3194      * \param theView The view which should be deleted.
3195      */
3196     void Destroy(in View theView);
3197   };
3198
3199
3200 };
3201
3202 #endif