1 ///////////////////////////////////////////////////////////
2 // File : SIERPINSKY_Gen_i.hxx
3 // Author : Vadim SANDLER (OCN)
5 // Copyright (C) 2005 Open CASCADE
6 ///////////////////////////////////////////////////////////
8 #ifndef __SIERPINSKY_GEN_I_HXX
9 #define __SIERPINSKY_GEN_I_HXX
11 #include "SALOME_Component_i.hxx"
13 #include <SALOMEconfig.h>
14 #include CORBA_SERVER_HEADER(Sierpinsky)
15 #include CORBA_CLIENT_HEADER(SALOMEDS)
23 MyPoint( const double x = 0., const double y = 0. ) : myX( x ), myY( y ) {}
26 class SIERPINSKY_Gen_i: public virtual POA_SIERPINSKY_ORB::SIERPINSKY,
27 public virtual Engines_Component_i
30 // Default constructor
33 SIERPINSKY_Gen_i( CORBA::ORB_ptr orb,
34 PortableServer::POA_ptr poa,
35 PortableServer::ObjectId* contId,
36 const char* instanceName,
37 const char* interfaceName );
41 // Initializes engine with three reference points
42 void Init( CORBA::Double theX1, CORBA::Double theY1,
43 CORBA::Double theX2, CORBA::Double theY2,
44 CORBA::Double theX3, CORBA::Double theY3 );
46 // Initializes engine with three default reference points: (0.5, 1), (0, 0), (1, 0)
49 // Generates next iteration point
50 void NextPoint( CORBA::Double theX, CORBA::Double theY,
52 CORBA::Double& theNextX, CORBA::Double& theNextY );
54 // Exports data to the JPEG image
55 CORBA::Boolean ExportToJPEG( const char* theFileName, CORBA::Long theSize );
57 // Exports data to the MED file
58 CORBA::Boolean ExportToMED( const char* theFileName, CORBA::Double theSize );
61 std::list<MyPoint> myPoints;
62 MyPoint myRefPoints[3];
65 #endif // __SIERPINSKY_GEN_I_HXX