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