You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(47) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(140) |
Feb
(98) |
Mar
(152) |
Apr
(104) |
May
(71) |
Jun
(94) |
Jul
(169) |
Aug
(83) |
Sep
(47) |
Oct
(134) |
Nov
(7) |
Dec
(20) |
2004 |
Jan
(41) |
Feb
(14) |
Mar
(42) |
Apr
(47) |
May
(68) |
Jun
(143) |
Jul
(65) |
Aug
(29) |
Sep
(40) |
Oct
(34) |
Nov
(33) |
Dec
(97) |
2005 |
Jan
(29) |
Feb
(30) |
Mar
(9) |
Apr
(37) |
May
(13) |
Jun
(31) |
Jul
(22) |
Aug
(23) |
Sep
|
Oct
(37) |
Nov
(34) |
Dec
(117) |
2006 |
Jan
(48) |
Feb
(6) |
Mar
(2) |
Apr
(71) |
May
(10) |
Jun
(16) |
Jul
(7) |
Aug
(1) |
Sep
(14) |
Oct
(17) |
Nov
(25) |
Dec
(26) |
2007 |
Jan
(8) |
Feb
(2) |
Mar
(7) |
Apr
(26) |
May
|
Jun
(12) |
Jul
(30) |
Aug
(14) |
Sep
(9) |
Oct
(4) |
Nov
(7) |
Dec
(6) |
2008 |
Jan
(10) |
Feb
(10) |
Mar
(6) |
Apr
(8) |
May
|
Jun
(10) |
Jul
(18) |
Aug
(15) |
Sep
(16) |
Oct
(5) |
Nov
(3) |
Dec
(10) |
2009 |
Jan
(11) |
Feb
(2) |
Mar
|
Apr
(15) |
May
(31) |
Jun
(18) |
Jul
(11) |
Aug
(26) |
Sep
(52) |
Oct
(17) |
Nov
(4) |
Dec
|
2010 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <de...@us...> - 2004-04-03 22:32:03
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Include In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24302 Added Files: VectorField.h Vector.h Log Message: see CHANGES.current --- NEW FILE: VectorField.h --- // Combat Simulator Project - CSPSim // Copyright (C) 2003, 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file VectorField.h * **/ #ifndef __VECTORFIELD_H__ #define __VECTORFIELD_H__ #include "Vector.h" class NumericalMethod; /** * A simple class to represent a multidimensional vector * field describing the kinetic parameters of a dynamical * system. */ class VectorField { protected: typedef size_t size_type; size_type const m_Dimension; Vector::Vectord m_dy; ///< contains the current value of the vector field at (t,y_1,...,y_d) public: /** * Construct a new vector field of the specified dimension. */ VectorField(size_type dimension): m_Dimension(dimension), m_dy(m_Dimension) { } virtual ~VectorField(){} /** * @return the dimension of the vector field. */ size_type getDimension() const { return m_Dimension; } /** * @return the vector field at the specified point. */ virtual Vector::Vectord const &f(double t, Vector::Vectord &y) = 0; /** * @return the numerical method, if any, used to solve * y' = f(t,y) */ virtual NumericalMethod *const getNumericalMethod() const { return 0; } }; #endif // __VECTORFIELD_H__ --- NEW FILE: Vector.h --- // Combat Simulator Project - CSPSim // Copyright (C) 2003, 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file Vector.h * **/ #ifndef __VECTOR_H__ #define __VECTOR_H__ #if !defined(NOT_USE_VALARRAY) && defined(_MSC_VER) && !defined(_STLP_WIN32) #define NOT_USE_VALARRAY #endif #include <cmath> #include <functional> #ifdef NOT_USE_VALARRAY #include <algorithm> #include <numeric> #include <vector> namespace Vector { template<typename T,class A> class Expr { A m_Iter; typedef typename std::vector<T>::size_type size_type; size_type m_Size; public: Expr(const A& a): m_Iter(a) { } Expr(const A& a, size_type s): m_Iter(a), m_Size(s) { } T const operator*() const { return m_Iter(); } Expr& operator++() { ++m_Iter; return *this; } const A& begin() const { return m_Iter; } const size_type& size() const { return m_Size; } }; template<typename T, class A, class B, class Op> class BinExprOp { A m_A; B m_B; public: BinExprOp(const A& a,const B& b): m_A(a), m_B(b) { } T const operator()() const { return Op()(*m_A,*m_B); } BinExprOp& operator++() { ++m_A; ++m_B; return *this; } }; template<typename T,class A, class Op> class UnaExprOp { T m_T; A m_A; public: UnaExprOp(const T& t,const A& a): m_T(t), m_A(a) { } T const operator()() const { return Op()(m_T, *m_A); } UnaExprOp& operator++() { ++m_A; return *this; } }; /* template<typename T,class A, class Op> class UnaExprOp { A m_A; public: UnaExprOp(const A& a): m_A(a) { } T const operator()() const { return Op()(*m_A); } UnaExprOp& operator++() { ++m_A; return *this; } }; */ /** * @warning This class is a first attempt to use a vector arithmetic; in no way, it * pretends to be optimized, nor fully complete. * @warning Don t inheritate from this class. * To be safe, this class should aggregate a std::vector<T> (or better a ref_count<T*>) * member and owns usefull std::vector<> methods. */ template<typename T> struct Vector: public std::vector<T> { typedef typename std::vector<T>::iterator vi; typedef typename std::vector<T>::const_iterator cvi; typedef typename std::vector<T>::size_type size_type; Vector() { } Vector(size_type n):std::vector<T>(n){ } Vector(T value,size_type n):std::vector<T>(n,value){ } template<class A> Vector(const Expr<T,A>& rhs):std::vector<T>(rhs.size()){ *this = rhs; } template <class A> Vector& operator=(Expr<T,A> rhs) { cvi iEnd = end(); for (vi i = begin();i != iEnd;++i,++rhs) *i = *rhs; return *this; } Expr<T,BinExprOp<T,cvi,cvi,std::plus<T> > > operator+(const Vector& rhs) const { typedef BinExprOp<T,cvi,cvi, std::plus<T> > ExprT; return Expr<T,ExprT>(ExprT(begin(),rhs.begin()),size()); } template<class A> Expr<T,BinExprOp<T,cvi,Expr<T,A>,std::plus<T> > > operator+(const Expr<T,A>& rhs) const { typedef BinExprOp<T,cvi,Expr<T,A>,std::plus<T> > ExprT; return Expr<T,ExprT>(ExprT(begin(),rhs.begin()),size()); } Vector operator-() const { Vector opp(size()); std::transform(begin(),end(),opp.begin(),std::negate<T>()); return opp; } Expr<T,BinExprOp<T,cvi,cvi,std::minus<T> > > operator-(const Vector& rhs) const { typedef BinExprOp<T,cvi,cvi,std::minus<T> > ExprT; return Expr<T,ExprT>(ExprT(begin(),rhs.begin()),size()); } template<class A> Expr<T,BinExprOp<T,cvi,A,std::minus<T> > > operator-(const A& rhs) const { typedef BinExprOp<T,cvi,A,std::minus<T> > ExprT; return Expr<T,ExprT>(ExprT(begin(), rhs.begin()),size()); } T operator*(const Vector& rhs) const { return std::inner_product(begin(),end(),rhs.begin(),0.0); } }; template<typename T,class A> inline Expr<T,BinExprOp<T,A,typename Vector<T>::cvi,std::plus<T> > > operator+(const A& lhs, const Vector<T>& rhs) { typedef BinExprOp<T,A,typename Vector<T>::cvi,std::plus<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs.begin(),rhs.begin()),lhs.size()); } template<typename T,class A,class B> inline Expr<T,BinExprOp<T,Expr<T,A>,Expr<T,B>,std::plus<T> > > operator+(const Expr<T,A>& lhs,const Expr<T,B>& rhs) { typedef BinExprOp<T,Expr<T,A>,Expr<T,B>,std::plus<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs.begin(),rhs.begin()),lhs.size()); } template<typename T,class A> inline Expr<T,BinExprOp<T,A,typename Vector<T>::cvi,std::minus<T> > > operator-(const A& lhs,const Vector<T>& rhs) { typedef BinExprOp<T,A,typename Vector<T>::cvi,std::minus<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs.begin(),rhs.begin()),lhs.size()); } template<typename T,class A, class B> inline Expr<T,BinExprOp<T,Expr<T,A>,Expr<T,B>,std::minus<T> > > operator-(const Expr<T,A>& lhs, const Expr<T,B>& rhs) { typedef BinExprOp<T,Expr<T,A>,Expr<T,B>,std::minus<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs.begin(),rhs.begin()),lhs.size()); } template<typename T> inline Expr<T,UnaExprOp<T,typename Vector<T>::cvi,std::multiplies<T> > > operator*(T lhs,const Vector<T>& rhs) { typedef UnaExprOp<T,typename Vector<T>::cvi,std::multiplies<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs,rhs.begin()),rhs.size()); } /* template<typename T> inline Expr<T,UnaExprOp<T,typename Vector<T>::cvi,std::binder1st<std::multiplies<T> > > > operator*(T lhs,const Vector<T>& rhs) { typedef UnaExprOp<T,typename Vector<T>::cvi,std::bind1st<std::multiplies<T>,T>(std::multiplies<T>,lhs)> ExprT; return Expr<T,ExprT>(ExprT(lhs,rhs.begin()),rhs.size()); } */ template<typename T,class A> inline Expr<T,UnaExprOp<T,A,std::multiplies<T> > > operator*(T lhs, const A& rhs) { typedef UnaExprOp<T,A,std::multiplies<T> > ExprT; return Expr<T,ExprT>(ExprT(lhs,rhs.begin()),rhs.size()); } template<typename T> class PrintElement { std::ostream& m_Ostream; public: PrintElement(std::ostream& lhs):m_Ostream(lhs) {} void operator ()(T lhs){ m_Ostream << "," << lhs; } }; template<typename T> std::ostream &operator<<(std::ostream& lhs, const Vector<T>& rhs) { if (!rhs.empty()) { typename Vector<T>::cvi iBegin = rhs.begin(); lhs << "(" << *iBegin; std::for_each(iBegin+1,rhs.end(),PrintElement<T>(lhs)); lhs << ") "; } return lhs; } template<typename T> struct Abs { inline T operator()(T lhs,T rhs) const { return lhs + fabs(rhs); } }; template<typename T> inline T norm_1(const Vector<T>& lhs) { return std::accumulate(lhs.begin(),lhs.end(),0.0,Abs<T>()); } template<typename T, class A> inline T norm_1(const Expr<T,A>& lhs) { return norm_1(Vector<T>(lhs)); } template<typename T, class A> inline T norm_2(const Expr<T,A>& lhs) { return norm_2(Vector<T>(lhs)); } template<typename T> inline T norm_2(const Vector<T>& lhs) { return sqrt(lhs*lhs); } typedef Vector<double> Vectord; } #else #include <valarray> template<typename T> T norm_2(const std::valarray<T>& lhs) { return sqrt((lhs*lhs).sum()); } template<typename T> T norm_1(const std::valarray<T>& lhs) { return abs(lhs).sum(); } template<typename T> std::ostream &operator<<(std::ostream& lhs, const std::valarray<T>& rhs) { size_t n = rhs.size(); if (n>0) { lhs << "(" << rhs[0]; for(size_t i = 1;i<n;++i) lhs << "," << rhs[i]; lhs << ")"; } return lhs; } namespace Vector { typedef std::valarray<double> Vectord; } #endif #endif //__VECTOR_H__ |
From: <de...@us...> - 2004-04-03 22:31:23
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Include/Views In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24179 Added Files: View.h CameraKinematics.h CameraCommand.h CameraAgent.h Log Message: see CHANGES.current --- NEW FILE: View.h --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file View.h * **/ #ifndef __VIEW_H__ #define __VIEW_H__ #include <map> #include <SimData/Quat.h> #include <SimData/Ref.h> #include <SimData/Vector3.h> class CameraAgent; class CameraKinematics; class SimObject; class DynamicObject; class View { size_t m_ViewMode; protected: bool m_InternalView; simdata::Ref<DynamicObject> m_ActiveObject; CameraKinematics* m_CameraKinematics; void updateBody(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up); void updateWorld(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up); virtual void constrain(){} public: View(size_t vm); virtual void activate(){} virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up, double dt) = 0; void accept(const simdata::Ref<DynamicObject> object) {m_ActiveObject = object;} void accept(CameraKinematics* ck) {m_CameraKinematics = ck;} virtual void recalculate(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up, double dt){ update(ep,lp,up,dt); } void cull(); virtual ~View(){} }; class InternalView: public View { public: InternalView(size_t vm):View(vm){m_InternalView = true;} virtual void constrain(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up, double dt); virtual void activate(); virtual ~InternalView(){} }; class InternalViewHist: public InternalView { public: InternalViewHist(size_t vm):InternalView(vm){} virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up, double dt); virtual ~InternalViewHist(){} }; class ExternalViewBody: public View { public: ExternalViewBody(size_t vm):View(vm){} virtual void activate(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up, double dt); virtual ~ExternalViewBody(){} }; class ExternalViewWorld: public View { public: ExternalViewWorld(size_t vm):View(vm){} virtual void activate(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); virtual ~ExternalViewWorld(){} }; class FlybyView: public View { simdata::Vector3 m_FixedCameraPosition; void newFixedCamPos(SimObject* target); public: FlybyView(size_t vm):View(vm){} virtual void activate(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); virtual void recalculate(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); virtual ~FlybyView(){} }; class SatelliteView: public View { public: SatelliteView(size_t vm):View(vm){} virtual void activate(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); virtual ~SatelliteView(){} }; class PadlockView: public View { // padlock testing simdata::Ref<DynamicObject> m_Padlock; float m_NeckPhi,m_NeckTheta,m_psi; bool m_NeckLimit; simdata::Quat m_Attitude; void constrain(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); public: PadlockView(size_t vm); virtual void activate(); virtual void update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt); virtual ~PadlockView(){} }; typedef std::map<size_t,View*> ViewList; class ViewFactory { View* createView_1() const; View* createView_2() const; View* createView_3() const; View* createView_4() const; View* createView_7() const; View* createView_8() const; View* createView_9() const; public: void attachAllView(CameraAgent* ca) const; }; #endif //__VIEW_H__ --- NEW FILE: CameraKinematics.h --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file CameraKinematics.h * **/ #ifndef __CAMERAKINEMATICS_H__ #define __CAMERAKINEMATICS_H__ #include <deque> class CameraCommand; class CameraKinematics { typedef std::deque<CameraCommand*> CameraCommandList; CameraCommandList m_CameraCommandList; // XXX: serialize const float m_BaseRate, m_DisplacementCoefficient; const float m_MinimumDistanceOffset, m_AbsoluteMaximumDistance; double m_AngleRotX, m_AngleRotZ; float m_PanRateX, m_PanRateZ, m_ZoomRate; double m_DistanceToObject, m_MinimumDistance; void rotateAboutZ(double dt) {m_AngleRotZ += m_PanRateZ * dt;} void rotateAboutX(double dt) {m_AngleRotX += m_PanRateX * dt;} void scale(double dt); float smooth(double value, float min_value,float max_value) const; public: CameraKinematics(); virtual ~CameraKinematics(){} void clampX(double& value,float min_value,float max_value, bool smooth_on = true); void clampZ(double& value,float min_value,float max_value, bool smooth_on = true); void reset(); void resetDistance(); void update(double dt); void panLeft(); void panRight(); void panLeftRightStop(); void panUp(); void panDown(); void panUpDownStop(); void zoomIn(); void zoomOut(); void zoomStop(); void displacement(int x, int y, int dx, int dy); void setAngleX(double angle_x) {m_AngleRotX = angle_x;} double& getAngleX() {return m_AngleRotX;} void setAngleZ(double angle_z) {m_AngleRotZ = angle_z;} double& getAngleZ() {return m_AngleRotZ;} void setDistance(float d) {m_DistanceToObject = d;} double getDistance() const {return m_DistanceToObject;} void accept(CameraCommand* cm); }; #endif //__CAMERAKINEMATICS_H__ --- NEW FILE: CameraCommand.h --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file CameraCommand.h * **/ #ifndef __CAMERACOMMAND_H__ #define __CAMERACOMMAND_H__ #include "Views/CameraKinematics.h" class Command { public: virtual void execute() = 0; virtual ~Command(){} }; class CameraCommand: public Command { protected: CameraKinematics* m_CameraKinematics; public: CameraCommand(): m_CameraKinematics(0){} void setCameraKinematics(CameraKinematics* cm) { m_CameraKinematics = cm; } virtual ~CameraCommand(){} }; class CameraReset: public CameraCommand { public: virtual void execute() { m_CameraKinematics->reset(); } virtual ~CameraReset(){} }; class PanLeft: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panLeft(); } virtual ~PanLeft(){} }; class PanRight: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panRight(); } virtual ~PanRight(){} }; class PanLeftRightStop: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panLeftRightStop(); } virtual ~PanLeftRightStop(){} }; class PanUp: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panUp(); } virtual ~PanUp(){} }; class PanDown: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panDown(); } virtual ~PanDown(){} }; class PanUpDownStop: public CameraCommand { public: virtual void execute() { m_CameraKinematics->panUpDownStop(); } virtual ~PanUpDownStop(){} }; class ZoomIn: public CameraCommand { public: virtual void execute() { m_CameraKinematics->zoomIn(); } virtual ~ZoomIn(){} }; class ZoomOut: public CameraCommand { public: virtual void execute() { m_CameraKinematics->zoomOut(); } virtual ~ZoomOut(){} }; class ZoomStop: public CameraCommand { public: virtual void execute() { m_CameraKinematics->zoomStop(); } virtual ~ZoomStop(){} }; class MouseCommand: public CameraCommand { int m_x,m_y,m_dx,m_dy; void reset() { m_x = 0; m_y = 0; m_dx = 0; m_dy = 0; } public: MouseCommand() { reset(); } void set(int x,int y, int dx, int dy) { m_x = x; m_y = y; m_dx = dx; m_dy = dy; } virtual void execute() { m_CameraKinematics->displacement(m_x,m_y,m_dx,m_dy); reset(); } virtual ~MouseCommand(){} }; #endif //__CAMERACOMMAND_H__ --- NEW FILE: CameraAgent.h --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file CameraAgent.h * **/ #ifndef __CAMERAAGENT_H__ #define __CAMERAAGENT_H__ #include <SimData/Ref.h> #include <SimData/Vector3.h> #include "Views/CameraKinematics.h" #include "Views/View.h" class CameraCommand; class DynamicObject; class CameraAgent { simdata::Vector3 m_EyePoint,m_LookPoint,m_UpVector; CameraKinematics m_CameraKinematics; size_t m_ViewMode; ViewList m_ViewList; void validate(double dt); void deleteViews(); void notifyCameraKinematicsToViews(); public: CameraAgent(const ViewFactory& vf); ~CameraAgent(); void attach(size_t mode,View* vm); void set(size_t vm, CameraCommand* ck = 0); void notifyObjectToViews(const simdata::Ref<DynamicObject> object); void updateCamera(double dt); const simdata::Vector3& getEyePoint() const {return m_EyePoint;} const simdata::Vector3& getLookPoint() const {return m_LookPoint;} const simdata::Vector3& getUpVector() const {return m_UpVector;} }; #endif //__CAMERAAGENT_H__ |
From: <de...@us...> - 2004-04-03 22:30:48
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Include/Views In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24095/Views Log Message: Directory /cvsroot/csp/APPLICATIONS/CSPSim/Include/Views added to the repository |
From: <de...@us...> - 2004-04-03 22:28:55
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Source/Views In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23816 Added Files: View.cpp CameraKinematics.cpp CameraAgent.cpp Log Message: see CHANGES.current --- NEW FILE: View.cpp --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file View.cpp * **/ #include "Views/View.h" #include "Views/CameraAgent.h" #include "VirtualBattlefield.h" #include "CSPSim.h" #include "DynamicObject.h" void View::updateBody(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up) { simdata::Vector3 object_up = m_ActiveObject->getUpDirection(); simdata::Vector3 object_dir = m_ActiveObject->getDirection(); simdata::Quat q = simdata::Quat(-m_CameraKinematics->getAngleZ(),object_up,-m_CameraKinematics->getAngleX(), object_dir^object_up,0.0,object_dir); simdata::Vector3 object_pos = m_ActiveObject->getGlobalPosition(); ep = object_pos + m_CameraKinematics->getDistance() * q.rotate(-object_dir); lp = object_pos; up = q.rotate(object_up); } void View::updateWorld(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up) { simdata::Quat q = simdata::Quat(-m_CameraKinematics->getAngleZ(),simdata::Vector3::ZAXIS,-m_CameraKinematics->getAngleX(), simdata::Vector3::XAXIS,0.0,simdata::Vector3::YAXIS); simdata::Vector3 object_pos = m_ActiveObject->getGlobalPosition(); ep = object_pos + m_CameraKinematics->getDistance() * q.rotate(-simdata::Vector3::YAXIS); lp = object_pos; up = q.rotate(simdata::Vector3::ZAXIS); } View::View(size_t vm): m_ViewMode(vm), m_InternalView(false), m_ActiveObject(CSPSim::theSim->getActiveObject()){ } void View::cull() { VirtualScene* scene = CSPSim::theSim->getScene(); if (scene && m_ActiveObject.valid()) { bool isNear = m_ActiveObject->getNearFlag(); if (isNear && !m_InternalView) { scene->setNearObject(m_ActiveObject, false); } else if (!isNear && m_InternalView) { scene->setNearObject(m_ActiveObject, true); } } } void InternalView::constrain() { float limit = simdata::PI_2; m_CameraKinematics->clampX(m_CameraKinematics->getAngleX(),-limit,limit); m_CameraKinematics->clampZ(m_CameraKinematics->getAngleZ(),-limit,limit); } void InternalView::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { constrain(); simdata::Vector3 object_up = m_ActiveObject->getUpDirection(); simdata::Vector3 object_dir = m_ActiveObject->getDirection(); simdata::Quat q = simdata::Quat(m_CameraKinematics->getAngleZ(),object_up,m_CameraKinematics->getAngleX(), object_dir^object_up,0.0,object_dir); simdata::Vector3 object_pos = m_ActiveObject->getGlobalPosition(); ep = object_pos + m_ActiveObject->getViewPoint(); lp = ep + m_CameraKinematics->getDistance() * q.rotate(object_dir); up = q.rotate(object_up); } void InternalView::activate() { m_CameraKinematics->reset(); } void InternalViewHist::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { const float c = 0.001; simdata::Vector3 displ = c*dt*m_ActiveObject->getVelocity(); static simdata::Vector3 prev_displ = displ; InternalView::update(ep,lp,up,dt); ep += 0.5*(prev_displ + displ); prev_displ = displ; } void ExternalViewBody::activate() { m_CameraKinematics->resetDistance(); } void ExternalViewBody::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { updateBody(ep,lp,up); } void ExternalViewWorld::activate() { m_CameraKinematics->resetDistance(); } void ExternalViewWorld::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { updateWorld(ep,lp,up); } void FlybyView::newFixedCamPos(SimObject* target) { simdata::Vector3 object_pos = target->getGlobalPosition(); DynamicObject* dynamic = dynamic_cast<DynamicObject*>(target); if (dynamic) { simdata::Vector3 up = dynamic->getUpDirection(); simdata::Vector3 object_dir = dynamic->getDirection(); //double speed_level = dynamic->getSpeed()/50.0; m_FixedCameraPosition = object_pos + 900.0* object_dir + ( 12.0 - (rand() % 5) ) * (object_dir^up) + ( 6.0 + (rand () % 3) ) * up; } else { m_FixedCameraPosition = object_pos + 100.0 * simdata::Vector3::ZAXIS + 100.0 * simdata::Vector3::XAXIS; } } void FlybyView::activate() { newFixedCamPos(m_ActiveObject.get()); } void FlybyView::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { lp = m_ActiveObject->getGlobalPosition(); ep = m_FixedCameraPosition; if ((lp - ep).length() > 900.0) newFixedCamPos(m_ActiveObject.get()); up = simdata::Vector3::ZAXIS; } void FlybyView::recalculate(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { VirtualScene* scene = CSPSim::theSim->getScene(); const simdata::Ref<TerrainObject> terrain = scene->getTerrain(); const float SAFETY = 2.0; TerrainObject::IntersectionHint camera_hint = 0; float h = SAFETY + terrain->getGroundElevation(ep.x(),ep.y(),camera_hint); float d = ep.z() - h; if (d<0) ep.z() -= d; } void SatelliteView::activate() { m_CameraKinematics->setAngleZ(0.0); m_CameraKinematics->setAngleX(0.5*simdata::PI); m_CameraKinematics->setDistance(500.0); } void SatelliteView::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { updateWorld(ep,lp,up); } PadlockView::PadlockView(size_t vm): View(vm), m_Padlock(m_ActiveObject) { m_InternalView = true; } void PadlockView::activate() { m_CameraKinematics->reset(); VirtualBattlefield* battlefield = CSPSim::theSim->getBattlefield(); m_Padlock = battlefield->getNextUnit(m_ActiveObject, -1, -1, -1); if (m_Padlock == m_ActiveObject) { m_Padlock = battlefield->getNextUnit(m_Padlock, -1, -1, -1); } if (m_Padlock != m_ActiveObject) { m_NeckTheta = m_CameraKinematics->getAngleX() - 0.5*simdata::PI; m_NeckPhi = m_CameraKinematics->getAngleZ(); } } void PadlockView::constrain(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { if (m_Padlock.valid()) { ep = m_ActiveObject->getGlobalPosition(); m_Attitude = m_ActiveObject->getAttitude(); ep += m_ActiveObject->getViewPoint(); simdata::Vector3 dir = (m_Padlock->getGlobalPosition() - ep).normalized(); dir = m_Attitude.invrotate(dir); float phi = atan2(-dir.x(), dir.y()); float theta = acos(dir.z()); float phi_max = 2.6 - std::max(0.0, 1.57 - 2.0*theta); if (phi > phi_max) { phi = phi_max; m_NeckLimit = true; } else if (phi < -phi_max) { phi = -phi_max; m_NeckLimit = true; } else { m_NeckLimit = false; } float motion = std::min(3.0*dt, 0.3); phi = m_NeckPhi * (1.0-motion) + phi * motion; m_psi = phi * std::max(0.0, std::min(1.0, 2.0*theta)); m_NeckTheta = theta; m_NeckPhi = phi; } } void PadlockView::update(simdata::Vector3& ep,simdata::Vector3& lp,simdata::Vector3& up,double dt) { if (m_Padlock.valid()) { constrain(ep,lp,up,dt); simdata::Vector3 dir(-sin(m_NeckTheta)*sin(m_NeckPhi), sin(m_NeckTheta)*cos(m_NeckPhi), cos(m_NeckTheta)); simdata::Vector3 d(sin(m_psi), -cos(m_psi), 0.0); up.set(d.x()*cos(m_NeckTheta), d.y()*cos(m_NeckTheta), sin(m_NeckTheta)); up = m_Attitude.rotate(up); float offset = std::max(0.0, std::min(0.4, 0.3*(abs(m_psi) - 1.57))); if (m_psi > 0.0) offset = -offset; ep += m_Attitude.rotate(offset * simdata::Vector3::XAXIS); dir = m_Attitude.rotate(dir); lp = ep + 100.0 * dir; } } View* ViewFactory::createView_1() const { return new InternalView(1); } View* ViewFactory::createView_2() const { return new ExternalViewBody(2); } View* ViewFactory::createView_3() const { return new ExternalViewWorld(3); } View* ViewFactory::createView_4() const { return new InternalViewHist(4); } View* ViewFactory::createView_7() const { return new SatelliteView(7); } View* ViewFactory::createView_8() const { return new FlybyView(8); } View* ViewFactory::createView_9() const { return new PadlockView(9); } void ViewFactory::attachAllView(CameraAgent* ca) const { ca->attach(1,createView_1()); ca->attach(2,createView_2()); ca->attach(3,createView_3()); ca->attach(4,createView_4()); ca->attach(7,createView_7()); ca->attach(8,createView_8()); ca->attach(9,createView_9()); } --- NEW FILE: CameraKinematics.cpp --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file CameraKinematics.cpp * **/ #include <SimData/Math.h> #include "Views/CameraKinematics.h" #include "CSPSim.h" #include "DynamicObject.h" #include "VirtualScene.h" #include "Views/CameraCommand.h" void CameraKinematics::scale(double dt) { float scale_factor = 1.0 + m_ZoomRate * dt; if ((m_DistanceToObject > m_MinimumDistance && scale_factor < 1.0) || (m_DistanceToObject < m_AbsoluteMaximumDistance && scale_factor > 1.0) ) { m_DistanceToObject *= scale_factor; } m_DistanceToObject = simdata::clampTo<double>(m_DistanceToObject,m_MinimumDistance,m_AbsoluteMaximumDistance); } void CameraKinematics::update(double dt) { rotateAboutZ(dt); rotateAboutX(dt); scale(dt); } float CameraKinematics::smooth(double value, float min_value,float max_value) const { float epsilon = 0.1 * abs(max_value - min_value); float damping = std::min(value - min_value, max_value - value)/epsilon; if (damping > 0.0 && damping < 1.0) return damping; else return 1.0; } CameraKinematics::CameraKinematics(): // XXX: serialize those parameters m_BaseRate(simdata::toRadians(30.0)), m_DisplacementCoefficient(0.001), m_MinimumDistanceOffset(10.0), m_AbsoluteMaximumDistance(2000.0) { reset(); } void CameraKinematics::clampX(double& value,float min_value,float max_value, bool smooth_on) { if (smooth_on && m_PanRateX != 0.0) { m_PanRateX = simdata::sign(m_PanRateX)*smooth(value,min_value,max_value)*m_BaseRate; } value = simdata::clampTo<double>(value,min_value,max_value); } void CameraKinematics::clampZ(double& value,float min_value,float max_value, bool smooth_on) { if (smooth_on && m_PanRateZ != 0.0) { m_PanRateZ = simdata::sign(m_PanRateZ)*smooth(value,min_value,max_value)*m_BaseRate; } value = simdata::clampTo<double>(value,min_value,max_value); } void CameraKinematics::reset() { m_AngleRotX = 0.0; m_AngleRotZ = 0.0; m_PanRateX = 0.0; m_PanRateZ = 0.0; m_ZoomRate = 0.0; resetDistance(); } void CameraKinematics::resetDistance() { const simdata::Ref<DynamicObject> active_object = CSPSim::theSim->getActiveObject(); if (active_object.valid()) m_MinimumDistance = active_object->getModel()->getBoundingSphereRadius()+CSPSim::theSim->getScene()->getNearPlane(); else m_MinimumDistance = m_MinimumDistanceOffset; m_DistanceToObject = m_MinimumDistance + m_MinimumDistanceOffset; } void CameraKinematics::panLeft() { m_PanRateZ = m_BaseRate; } void CameraKinematics::panRight() { m_PanRateZ = -m_BaseRate; } void CameraKinematics::panLeftRightStop() { m_PanRateZ = 0.0; } void CameraKinematics::panUp() { m_PanRateX = m_BaseRate; } void CameraKinematics::panDown() { m_PanRateX = -m_BaseRate; } void CameraKinematics::panUpDownStop() { m_PanRateX = 0.0; } void CameraKinematics::zoomIn() { m_ZoomRate = -m_BaseRate; } void CameraKinematics::zoomOut() { m_ZoomRate = m_BaseRate; } void CameraKinematics::zoomStop() { m_ZoomRate = 0.0; } void CameraKinematics::displacement(int x, int y, int dx, int dy) { m_PanRateX = 0.0; m_PanRateZ = 0.0; m_AngleRotZ += dx * m_DisplacementCoefficient; m_AngleRotX += dy * m_DisplacementCoefficient; } void CameraKinematics::accept(CameraCommand* cm) { if (cm) { if (std::find(m_CameraCommandList.begin(),m_CameraCommandList.end(),cm) == m_CameraCommandList.end()) { m_CameraCommandList.push_back(cm); cm->setCameraKinematics(this); } cm->execute(); } } --- NEW FILE: CameraAgent.cpp --- // Combat Simulator Project - FlightSim Demo // Copyright (C) 2004 The Combat Simulator Project // http://csp.sourceforge.net // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** * @file CameraAgent.cpp * **/ #include <SimData/Math.h> #include "Views/CameraAgent.h" #include "CSPSim.h" #include "DynamicObject.h" #include "VirtualScene.h" #include "Views/CameraCommand.h" CameraAgent::CameraAgent(const ViewFactory& vf): m_ViewMode(0) { vf.attachAllView(this); notifyCameraKinematicsToViews(); } void CameraAgent::attach(size_t mode,View* vm){ m_ViewList[mode] = vm; } CameraAgent::~CameraAgent() { deleteViews(); } void CameraAgent::validate(double dt) { VirtualScene* scene = CSPSim::theSim->getScene(); const simdata::Ref<TerrainObject> terrain = scene->getTerrain(); simdata::Vector3 normal; double const SAFETY = 2.0; TerrainObject::IntersectionHint camera_hint = 0; float h = SAFETY + terrain->getGroundElevation(m_EyePoint.x(),m_EyePoint.y(),normal,camera_hint); if (m_EyePoint.z() <= h) { double alpha_2 = simdata::toRadians(scene->getViewAngle()/2.0); double near_dist = scene->getNearPlane(); double aspect = scene->getAspect(); simdata::Vector3 eye_look = m_LookPoint - m_EyePoint; simdata::Vector3 eye_look_unit = eye_look.normalized(); simdata::Vector3 up_vec_unit = m_UpVector.normalized(); double tan_alpha_2 = tan(alpha_2); simdata::Vector3 right_unit = eye_look_unit^up_vec_unit; double min_elev = 0.0; // iterate on the pyramide edges for (double i = -1.0; i <= 1.0; i += 2.0) for (double j = -1.0;j <= 1.0; j += 2.0) { simdata::Vector3 edge_vector = near_dist * (eye_look_unit + tan_alpha_2 * ( i * up_vec_unit + j * aspect * right_unit)); simdata::Vector3 edge = m_EyePoint + edge_vector; double edge_elev = edge.z()-(SAFETY+terrain->getGroundElevation(edge.x(),edge.y(),camera_hint)); if (min_elev > edge_elev) min_elev = edge_elev; } double dh = abs(h - m_LookPoint.z() - min_elev); double angle_x = asin(dh/m_CameraKinematics.getDistance()); if (abs(m_CameraKinematics.getAngleX()) < 0.5*simdata::PI) m_CameraKinematics.setAngleX(angle_x); else m_CameraKinematics.setAngleX(simdata::PI-angle_x); m_CameraKinematics.panUpDownStop(); m_ViewList[m_ViewMode]->recalculate(m_EyePoint,m_LookPoint,m_UpVector,dt); } } void CameraAgent::set(size_t vm,CameraCommand* ck) { if (m_ViewMode != vm) { ViewList::iterator view_it = m_ViewList.find(vm); if (view_it != m_ViewList.end()) { view_it->second->activate(); m_ViewMode = vm; } } m_CameraKinematics.accept(ck); } void CameraAgent::updateCamera(double dt) { ViewList::iterator view = m_ViewList.find(m_ViewMode); if (view != m_ViewList.end()) { m_CameraKinematics.update(dt); view->second->update(m_EyePoint,m_LookPoint,m_UpVector,dt); validate(dt); view->second->cull(); } } struct DestroyView { void operator()(std::pair<const size_t,View*>& vm) { delete vm.second; } }; void CameraAgent::deleteViews() { std::for_each(m_ViewList.begin(),m_ViewList.end(),DestroyView()); } class AcceptObject { simdata::Ref<DynamicObject> m_ActiveObject; public: AcceptObject(const simdata::Ref<DynamicObject> object):m_ActiveObject(object){} void operator()(std::pair<const size_t,View*>& vm) { vm.second->accept(m_ActiveObject); } }; void CameraAgent::notifyObjectToViews(simdata::Ref<DynamicObject> object) { std::for_each(m_ViewList.begin(),m_ViewList.end(),AcceptObject(object)); m_CameraKinematics.reset(); } class AcceptCameraKinematics { CameraKinematics* m_CameraKinematics; public: AcceptCameraKinematics(CameraKinematics* ck):m_CameraKinematics(ck) {} void operator()(std::pair<const size_t,View*>& vm) { vm.second->accept(m_CameraKinematics); } }; void CameraAgent::notifyCameraKinematicsToViews() { std::for_each(m_ViewList.begin(),m_ViewList.end(),AcceptCameraKinematics(&m_CameraKinematics)); } |
From: <de...@us...> - 2004-04-03 22:28:25
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Source/Views In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23771/Views Log Message: Directory /cvsroot/csp/APPLICATIONS/CSPSim/Source/Views added to the repository |
From: <de...@us...> - 2004-03-31 16:05:20
|
Update of /cvsroot/csp/APPLICATIONS/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3957 Modified Files: CHANGES.current Log Message: no message Index: CHANGES.current =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/CHANGES.current,v retrieving revision 1.102 retrieving revision 1.103 diff -C2 -d -r1.102 -r1.103 *** CHANGES.current 31 Mar 2004 07:46:41 -0000 1.102 --- CHANGES.current 31 Mar 2004 15:53:31 -0000 1.103 *************** *** 1,4 **** --- 1,10 ---- Version 0.4.0 (in progress) =========================== + 2004-03-31: delta + * Namespace & SIMDATA_EXPORT symbol hacks cleaned in + SimData/Include/SimData/ExceptionBase.h :-) + + * Minor changes to SimData/VisualStudio2003/SimData.vcproj. + 2004-03-30: onsight * Fixed some indentation issues. Other than that the ExceptionBase *************** *** 18,23 **** SWIG to SWIG_PATH (it doesn't affect GNU/Linux platform). ! * Changed Exception to ExceptionBase in ! APPLICATIONS/SimData/Source/Makefile. * Tweaked scons scripts to reflect the current options in --- 24,28 ---- SWIG to SWIG_PATH (it doesn't affect GNU/Linux platform). ! * Changed Exception to ExceptionBase in SimData/Source/Makefile. * Tweaked scons scripts to reflect the current options in |
From: <de...@us...> - 2004-03-31 16:01:00
|
Update of /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3144 Modified Files: SimData.vcproj Log Message: see CHANGES.current Index: SimData.vcproj =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003/SimData.vcproj,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** SimData.vcproj 30 Mar 2004 13:18:52 -0000 1.10 --- SimData.vcproj 31 Mar 2004 15:49:11 -0000 1.11 *************** *** 341,347 **** </File> <File - RelativePath="..\Include\SimData\ns-simdata.h"> - </File> - <File RelativePath="..\Include\SimData\Object.h"> </File> --- 341,344 ---- *************** *** 379,382 **** --- 376,382 ---- RelativePath="..\Include\SimData\Vector3.inl"> </File> + <File + RelativePath="..\Include\SimData\Version.h"> + </File> </Filter> <Filter *************** *** 400,404 **** CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i " ! Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> </File> --- 400,404 ---- CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i " ! Outputs="..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> </File> |
From: <de...@us...> - 2004-03-31 15:59:30
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2807 Modified Files: ExceptionBase.h Log Message: see CHANGES.current Index: ExceptionBase.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/ExceptionBase.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ExceptionBase.h 30 Mar 2004 10:22:19 -0000 1.1 --- ExceptionBase.h 31 Mar 2004 15:47:41 -0000 1.2 *************** *** 35,49 **** #include <SimData/Namespace.h> - // XXX this is a temporary hack to make - // swig1.3.21 correctly parses this file - #ifndef NAMESPACE_SIMDATA - namespace simdata { - #else NAMESPACE_SIMDATA - #endif - - #ifndef SIMDATA_EXPORT - #define SIMDATA_EXPORT - #endif /** General exception base class with error reporting. --- 35,39 ---- *************** *** 130,138 **** SIMDATA_EXCEPTION(PythonException); - #ifndef NAMESPACE_SIMDATA_END - } - #else NAMESPACE_SIMDATA_END - #endif #endif // __SIMDATA_EXCEPTION_H__ --- 120,124 ---- |
From: <mk...@us...> - 2004-03-31 07:58:26
|
Update of /cvsroot/csp/APPLICATIONS/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5246 Modified Files: CHANGES.current Log Message: Index: CHANGES.current =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/CHANGES.current,v retrieving revision 1.101 retrieving revision 1.102 diff -C2 -d -r1.101 -r1.102 *** CHANGES.current 30 Mar 2004 11:36:25 -0000 1.101 --- CHANGES.current 31 Mar 2004 07:46:41 -0000 1.102 *************** *** 1,4 **** --- 1,9 ---- Version 0.4.0 (in progress) =========================== + 2004-03-30: onsight + * Fixed some indentation issues. Other than that the ExceptionBase + change builds fine under Linux. Some namespace hacks still need + to be cleaned out of ExceptionBase.h though. + 2004-03-30: delta * Changed Exception.* files to ExceptionBase.* to avoid |
From: <mk...@us...> - 2004-03-31 07:22:52
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Source In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30207/Source Modified Files: Makefile Log Message: Fixed tabs that got munged to spaces. Index: Makefile =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Source/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Makefile 30 Mar 2004 10:13:45 -0000 1.15 --- Makefile 31 Mar 2004 07:11:07 -0000 1.16 *************** *** 10,41 **** MODULES = \ ! BaseType \ ! DataArchive \ ! DataManager \ ! Date \ ! Enum \ ! ExceptionBase \ ! External \ ! FileUtility \ ! GeoPos \ ! HashUtility \ ! InterfaceRegistry \ ! Interpolate \ ! Key \ ! Link \ ! List \ ! LogStream \ ! LUT \ ! Math \ ! Matrix3 \ ! Noise \ ! Object \ ! Path \ ! Quat \ ! Random \ ! Real \ ! TypeAdapter \ ! Vector3 \ ! Version SOURCES = $(MODULES:%=%.cpp) --- 10,41 ---- MODULES = \ ! BaseType \ ! DataArchive \ ! DataManager \ ! Date \ ! Enum \ ! ExceptionBase \ ! External \ ! FileUtility \ ! GeoPos \ ! HashUtility \ ! InterfaceRegistry \ ! Interpolate \ ! Key \ ! Link \ ! List \ ! LogStream \ ! LUT \ ! Math \ ! Matrix3 \ ! Noise \ ! Object \ ! Path \ ! Quat \ ! Random \ ! Real \ ! TypeAdapter \ ! Vector3 \ ! Version SOURCES = $(MODULES:%=%.cpp) *************** *** 52,69 **** default: ! @echo "run make from top-level directory only" clean-objects: ! rm -f $(MODULES:%=_%.so) ! rm -f $(MODULES:%=%.o) ! rm -f lib*.a ! rm -f _cSimData.so cSimData_wrap.* ! rm -f $(MODULES:%=%_wrap.o) ! rm -f $(DEPDIR)/*.d ! rm -f $(TOPDIR)/SimData/_cSimData.so ! rm -f $(TOPDIR)/SimData/cSimData.py clean-dependencies: ! @echo $(RM) -r $(RMFLAGS) $(DEPDIR) clean-deps: clean-dependencies --- 52,69 ---- default: ! @echo "run make from top-level directory only" clean-objects: ! rm -f $(MODULES:%=_%.so) ! rm -f $(MODULES:%=%.o) ! rm -f lib*.a ! rm -f _cSimData.so cSimData_wrap.* ! rm -f $(MODULES:%=%_wrap.o) ! rm -f $(DEPDIR)/*.d ! rm -f $(TOPDIR)/SimData/_cSimData.so ! rm -f $(TOPDIR)/SimData/cSimData.py clean-dependencies: ! @echo $(RM) -r $(RMFLAGS) $(DEPDIR) clean-deps: clean-dependencies *************** *** 83,116 **** build-subdirs: ! for dir in $(SUBDIRS); do \ ! $(MAKE) -C $${dir} all; \ ! done $(DEPDIR)/%.d : % ! @echo "Computing dependencies for $<..." ! @$(MKDEP) $< $(DEPFILTER) > $@ $(DEPDIR)/%.swigdep : % ! @echo "Computing dependencies for $<..." ! @$(SWDEP) $(DEPFILTER) -o $(<:.i=_wrap.cpp) $< > $@ libSimData.a: $(OBJECTS) ! ar cru $@ $^ ! ranlib $@ ! cp $@ $(TOPDIR)/SimData _cSimData.so: $(OBJECTS) cSimData_wrap.o ! $(CXX) -Wl,-z,lazyload $(LDOPTS) -o$@ $^ ! cp $@ $(TOPDIR)/SimData cSimData_wrap.cpp: cSimData.i ! $(SWIG) $(SWOPTS) -o $@ $< ! cp cSimData.py $(TOPDIR)/SimData cSimData_wrap.o: cSimData_wrap.cpp ! $(CXX) -c $(SWCXXF) -I$(PYTHON_INCLUDE) $(@:.o=.cpp) %.o: %.cpp ! $(CXX) -c $(CFLAGS) $(@:.o=.cpp) all: _cSimData.so libSimData.a --- 83,116 ---- build-subdirs: ! for dir in $(SUBDIRS); do \ ! $(MAKE) -C $${dir} all; \ ! done $(DEPDIR)/%.d : % ! @echo "Computing dependencies for $<..." ! @$(MKDEP) $< $(DEPFILTER) > $@ $(DEPDIR)/%.swigdep : % ! @echo "Computing dependencies for $<..." ! @$(SWDEP) $(DEPFILTER) -o $(<:.i=_wrap.cpp) $< > $@ libSimData.a: $(OBJECTS) ! ar cru $@ $^ ! ranlib $@ ! cp $@ $(TOPDIR)/SimData _cSimData.so: $(OBJECTS) cSimData_wrap.o ! $(CXX) -Wl,-z,lazyload $(LDOPTS) -o$@ $^ ! cp $@ $(TOPDIR)/SimData cSimData_wrap.cpp: cSimData.i ! $(SWIG) $(SWOPTS) -o $@ $< ! cp cSimData.py $(TOPDIR)/SimData cSimData_wrap.o: cSimData_wrap.cpp ! $(CXX) -c $(SWCXXF) -I$(PYTHON_INCLUDE) $(@:.o=.cpp) %.o: %.cpp ! $(CXX) -c $(CFLAGS) $(@:.o=.cpp) all: _cSimData.so libSimData.a |
From: <de...@us...> - 2004-03-30 13:30:31
|
Update of /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23881 Modified Files: SimData.vcproj Log Message: no message Index: SimData.vcproj =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003/SimData.vcproj,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** SimData.vcproj 30 Mar 2004 11:34:21 -0000 1.9 --- SimData.vcproj 30 Mar 2004 13:18:52 -0000 1.10 *************** *** 4,7 **** --- 4,8 ---- Version="7.10" Name="SimData" + RootNamespace="SimData" SccProjectName="" SccLocalPath=""> *************** *** 389,395 **** <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\..\Source\$(InputName).i " ! Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> <FileConfiguration --- 390,396 ---- <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i " ! Outputs="..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> <FileConfiguration |
From: <de...@us...> - 2004-03-30 11:48:36
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Doc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7021 Modified Files: SConscript Log Message: see CHANGES.current Index: SConscript =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Doc/SConscript,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** SConscript 1 Feb 2004 10:01:03 -0000 1.2 --- SConscript 30 Mar 2004 11:37:00 -0000 1.3 *************** *** 3,19 **** # SimData: Data Infrastructure for Simulations # Copyright (C) 2002, 2003 Mark Rose <tm...@st...> ! # # This file is part of SimData. ! # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. ! # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. ! # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software --- 3,19 ---- # SimData: Data Infrastructure for Simulations # Copyright (C) 2002, 2003 Mark Rose <tm...@st...> ! # # This file is part of SimData. ! # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. ! # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. ! # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software *************** *** 29,36 **** # this target is rebuild everytime it is explicitly ! # called, since there's no simple way to track all # the dependencies ! env.Alias('docs', env.Doxygen('docs', doxyfile)) env.Clean('docs', html) - --- 29,36 ---- # this target is rebuild everytime it is explicitly ! # called, since there's no simple way to track all # the dependencies ! # XXX ! #env.Alias('docs', env.Doxygen('docs', doxyfile)) env.Clean('docs', html) |
From: <de...@us...> - 2004-03-30 11:48:01
|
Update of /cvsroot/csp/APPLICATIONS/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6933 Modified Files: CHANGES.current Log Message: see CHANGES.current Index: CHANGES.current =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/CHANGES.current,v retrieving revision 1.100 retrieving revision 1.101 diff -C2 -d -r1.100 -r1.101 *** CHANGES.current 19 Mar 2004 09:05:50 -0000 1.100 --- CHANGES.current 30 Mar 2004 11:36:25 -0000 1.101 *************** *** 1,4 **** --- 1,25 ---- Version 0.4.0 (in progress) =========================== + 2004-03-30: delta + * Changed Exception.* files to ExceptionBase.* to avoid + swig's conflicts between exception.* and Exception.* + under Windows. This change is pretty invasive and + needs double checking on GNU/Linux. + + * The previous renaming simplifies (and unifies with GNU/Linux) + the swig's command line in the vs.net custom build step. + + * Renamed PYTHONPATH environment variable to PYTHON_PATH and + SWIG to SWIG_PATH (it doesn't affect GNU/Linux platform). + + * Changed Exception to ExceptionBase in + APPLICATIONS/SimData/Source/Makefile. + + * Tweaked scons scripts to reflect the current options in + vs.net 7.1 project file. A lot of scons' features have been + disabled to make it work under Windows. A command to generate + vs.net 7.1's .sln/.vcproj (currently commented out) has been + added to SConstruct. + 2004-03-18: onsight * After some effort debugging the scons scripts under windows |
From: <de...@us...> - 2004-03-30 11:45:57
|
Update of /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6648 Modified Files: SimData.vcproj Log Message: see CHANGES.current Index: SimData.vcproj =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/VisualStudio2003/SimData.vcproj,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** SimData.vcproj 3 Feb 2004 19:44:39 -0000 1.8 --- SimData.vcproj 30 Mar 2004 11:34:21 -0000 1.9 *************** *** 28,32 **** OptimizeForProcessor="0" OptimizeForWindowsApplication="TRUE" ! AdditionalIncludeDirectories="../Include,$(PYTHONPATH)/include" PreprocessorDefinitions="WIN32;NDEBUG;_USRDLL;SIMDATA_EXPORTS" StringPooling="TRUE" --- 28,32 ---- OptimizeForProcessor="0" OptimizeForWindowsApplication="TRUE" ! AdditionalIncludeDirectories="../Include,$(PYTHON_PATH)/include" PreprocessorDefinitions="WIN32;NDEBUG;_USRDLL;SIMDATA_EXPORTS" StringPooling="TRUE" *************** *** 54,58 **** LinkIncremental="1" SuppressStartupBanner="TRUE" ! AdditionalLibraryDirectories="$(PYTHONPATH)/Libs" GenerateDebugInformation="FALSE" AssemblyDebug="0" --- 54,58 ---- LinkIncremental="1" SuppressStartupBanner="TRUE" ! AdditionalLibraryDirectories="$(PYTHON_PATH)/Libs" GenerateDebugInformation="FALSE" AssemblyDebug="0" *************** *** 104,108 **** Name="VCCLCompilerTool" Optimization="0" ! AdditionalIncludeDirectories="../Include,$(PYTHONPATH)/include" PreprocessorDefinitions="WIN32;_DEBUG;_USRDLL;SIMDATA_EXPORTS" BasicRuntimeChecks="3" --- 104,108 ---- Name="VCCLCompilerTool" Optimization="0" ! AdditionalIncludeDirectories="../Include,$(PYTHON_PATH)/include" PreprocessorDefinitions="WIN32;_DEBUG;_USRDLL;SIMDATA_EXPORTS" BasicRuntimeChecks="3" *************** *** 126,130 **** LinkIncremental="2" SuppressStartupBanner="TRUE" ! AdditionalLibraryDirectories="$(PYTHONPATH)/Libs" GenerateDebugInformation="TRUE" ProgramDatabaseFile=".\Debug/_cSimDatad.pdb" --- 126,130 ---- LinkIncremental="2" SuppressStartupBanner="TRUE" ! AdditionalLibraryDirectories="$(PYTHON_PATH)/Libs" GenerateDebugInformation="TRUE" ProgramDatabaseFile=".\Debug/_cSimDatad.pdb" *************** *** 192,196 **** </File> <File ! RelativePath="..\Source\Exception.cpp"> </File> <File --- 192,196 ---- </File> <File ! RelativePath="..\Source\ExceptionBase.cpp"> </File> <File *************** *** 280,284 **** </File> <File ! RelativePath="..\Include\SimData\Exception.h"> </File> <File --- 280,284 ---- </File> <File ! RelativePath="..\Include\SimData\ExceptionBase.h"> </File> <File *************** *** 389,393 **** <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG)\swig -runtime -c++ -python -noexcept -lexception.i -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i" Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> --- 389,394 ---- <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\..\Source\$(InputName).i ! " Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> *************** *** 396,400 **** <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG)\swig -runtime -c++ -python -noexcept -lexception.i -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i" Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> --- 397,402 ---- <Tool Name="VCCustomBuildTool" ! CommandLine="$(SWIG_PATH)\swig -runtime -c++ -python -noexcept -I..\Include -o ..\Source\$(InputName)_wrap.cpp ..\Source\$(InputName).i ! " Outputs="..\..\Source\$(InputName)_wrap.cpp"/> </FileConfiguration> |
From: <de...@us...> - 2004-03-30 11:44:36
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6416 Modified Files: cSimData.i InterfaceRegistry.h LUT.h Ref.h TypeAdapter.h Log Message: see CHANGES.current Index: cSimData.i =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/cSimData.i,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** cSimData.i 30 Mar 2004 10:33:46 -0000 1.15 --- cSimData.i 30 Mar 2004 11:32:57 -0000 1.16 *************** *** 23,27 **** %{ #include <SimData/HashUtility.h> ! #include <SimData/Exception.h> #include <SimData/Types.h> #include <SimData/DataArchive.h> --- 23,27 ---- %{ #include <SimData/HashUtility.h> ! #include <SimData/ExceptionBase.h> #include <SimData/Types.h> #include <SimData/DataArchive.h> Index: InterfaceRegistry.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/InterfaceRegistry.h,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** InterfaceRegistry.h 24 Oct 2003 06:44:13 -0000 1.24 --- InterfaceRegistry.h 30 Mar 2004 11:32:57 -0000 1.25 *************** *** 39,43 **** #include <SimData/Singleton.h> #include <SimData/Namespace.h> ! #include <SimData/Exception.h> --- 39,43 ---- #include <SimData/Singleton.h> #include <SimData/Namespace.h> ! #include <SimData/ExceptionBase.h> Index: LUT.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/LUT.h,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** LUT.h 19 Oct 2003 23:53:56 -0000 1.10 --- LUT.h 30 Mar 2004 11:32:58 -0000 1.11 *************** *** 51,55 **** #include <SimData/Archive.h> ! #include <SimData/Exception.h> #include <SimData/BaseType.h> --- 51,55 ---- #include <SimData/Archive.h> ! #include <SimData/ExceptionBase.h> #include <SimData/BaseType.h> Index: Ref.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Ref.h,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** Ref.h 19 Oct 2003 23:53:56 -0000 1.8 --- Ref.h 30 Mar 2004 11:32:58 -0000 1.9 *************** *** 36,40 **** #include <SimData/Namespace.h> #include <SimData/Export.h> ! #include <SimData/Exception.h> #include <SimData/Log.h> --- 36,40 ---- #include <SimData/Namespace.h> #include <SimData/Export.h> ! #include <SimData/ExceptionBase.h> #include <SimData/Log.h> Index: TypeAdapter.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/TypeAdapter.h,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** TypeAdapter.h 24 Oct 2003 15:45:43 -0000 1.24 --- TypeAdapter.h 30 Mar 2004 11:32:58 -0000 1.25 *************** *** 33,37 **** #include <SimData/Export.h> ! #include <SimData/Exception.h> #include <SimData/Namespace.h> #include <SimData/Enum.h> --- 33,37 ---- #include <SimData/Export.h> ! #include <SimData/ExceptionBase.h> #include <SimData/Namespace.h> #include <SimData/Enum.h> |
From: <de...@us...> - 2004-03-30 11:42:46
|
Update of /cvsroot/csp/APPLICATIONS/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6142 Modified Files: build_config.py Log Message: see CHANGES.current Index: build_config.py =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/build_config.py,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** build_config.py 30 Mar 2004 10:11:18 -0000 1.6 --- build_config.py 30 Mar 2004 11:31:09 -0000 1.7 *************** *** 32,35 **** --- 32,36 ---- self.CPPPATH = ['#/Include', self.PYTHON_INC] self.SHLINKFLAGS = '/MACHINE:I386 /LIBPATH:%s /DLL' % self.PYTHON_LIBS + self.CXXFILESUFFIX = '.cpp' self.ARCHIVE_FORMATS = ['.zip'] |
From: <de...@us...> - 2004-03-30 10:49:38
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30554 Modified Files: Enum.h Log Message: see CHANGES.current Index: Enum.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Enum.h,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** Enum.h 24 Oct 2003 06:44:13 -0000 1.18 --- Enum.h 30 Mar 2004 10:37:59 -0000 1.19 *************** *** 78,82 **** #include <SimData/BaseType.h> #include <SimData/Ref.h> ! #include <SimData/Exception.h> #include <string> --- 78,82 ---- #include <SimData/BaseType.h> #include <SimData/Ref.h> ! #include <SimData/ExceptionBase.h> #include <string> |
From: <de...@us...> - 2004-03-30 10:48:48
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30450 Modified Files: Date.h Log Message: see CHANGES.current Index: Date.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Date.h,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** Date.h 30 Mar 2004 10:35:48 -0000 1.19 --- Date.h 30 Mar 2004 10:37:11 -0000 1.20 *************** *** 57,61 **** #include <SimData/Archive.h> ! #include <SimData/BaseException.h> #include <SimData/BaseType.h> --- 57,61 ---- #include <SimData/Archive.h> ! #include <SimData/ExceptionBase.h> #include <SimData/BaseType.h> |
From: <de...@us...> - 2004-03-30 10:47:24
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30127 Modified Files: Date.h Log Message: see CHANGES.current Index: Date.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Date.h,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** Date.h 24 Oct 2003 06:44:13 -0000 1.18 --- Date.h 30 Mar 2004 10:35:48 -0000 1.19 *************** *** 57,61 **** #include <SimData/Archive.h> ! #include <SimData/Exception.h> #include <SimData/BaseType.h> --- 57,61 ---- #include <SimData/Archive.h> ! #include <SimData/BaseException.h> #include <SimData/BaseType.h> |
From: <de...@us...> - 2004-03-30 10:47:08
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30046 Modified Files: DataManager.i Log Message: see CHANGES.current Index: DataManager.i =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/DataManager.i,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** DataManager.i 1 Feb 2004 12:06:44 -0000 1.3 --- DataManager.i 30 Mar 2004 10:35:21 -0000 1.4 *************** *** 26,50 **** ! %import "SimData/Exception.i" //typedef unsigned long long hasht; /* unsigned 8-byte type */ ! //typedef int int32; %exception SIMDATA(DataManager) { ! try { ! $function ! } catch (SIMDATA(IndexError) e) { ! e.details(); ! SWIG_exception(SWIG_IndexError, "Path not found"); ! } catch (SIMDATA(ObjectMismatch) e) { ! e.details(); ! SWIG_exception(SWIG_TypeError, "Object Mismatch"); ! } catch (SIMDATA(BadMagic) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Bad Magic"); ! } catch (SIMDATA(BadByteOrder) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Incorrect Byte Order"); ! } } --- 26,50 ---- ! %import "SimData/ExceptionBase.i" //typedef unsigned long long hasht; /* unsigned 8-byte type */ ! //typedef int int32; %exception SIMDATA(DataManager) { ! try { ! $function ! } catch (SIMDATA(IndexError) e) { ! e.details(); ! SWIG_exception(SWIG_IndexError, "Path not found"); ! } catch (SIMDATA(ObjectMismatch) e) { ! e.details(); ! SWIG_exception(SWIG_TypeError, "Object Mismatch"); ! } catch (SIMDATA(BadMagic) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Bad Magic"); ! } catch (SIMDATA(BadByteOrder) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Incorrect Byte Order"); ! } } *************** *** 56,58 **** %exception; - --- 56,57 ---- |
From: <de...@us...> - 2004-03-30 10:46:31
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29966 Modified Files: DataArchive.i Log Message: see CHANGES.current Index: DataArchive.i =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/DataArchive.i,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** DataArchive.i 1 Feb 2004 12:06:44 -0000 1.6 --- DataArchive.i 30 Mar 2004 10:34:55 -0000 1.7 *************** *** 26,54 **** ! %import "SimData/Exception.i" //typedef unsigned long long hasht; /* unsigned 8-byte type */ ! //typedef int int32; namespace std { ! %template(vector_hasht) vector<SIMDATA(hasht)>; } %exception SIMDATA(DataArchive) { ! try { ! $function ! } catch (SIMDATA(IndexError) e) { ! e.details(); ! SWIG_exception(SWIG_IndexError, "Path not found"); ! } catch (SIMDATA(ObjectMismatch) e) { ! e.details(); ! SWIG_exception(SWIG_TypeError, "Object Mismatch"); ! } catch (SIMDATA(BadMagic) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Bad Magic"); ! } catch (SIMDATA(BadByteOrder) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Incorrect Byte Order"); ! } } --- 26,54 ---- ! %import "SimData/ExceptionBase.i" //typedef unsigned long long hasht; /* unsigned 8-byte type */ ! //typedef int int32; namespace std { ! %template(vector_hasht) vector<SIMDATA(hasht)>; } %exception SIMDATA(DataArchive) { ! try { ! $function ! } catch (SIMDATA(IndexError) e) { ! e.details(); ! SWIG_exception(SWIG_IndexError, "Path not found"); ! } catch (SIMDATA(ObjectMismatch) e) { ! e.details(); ! SWIG_exception(SWIG_TypeError, "Object Mismatch"); ! } catch (SIMDATA(BadMagic) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Bad Magic"); ! } catch (SIMDATA(BadByteOrder) e) { ! e.details(); ! SWIG_exception(SWIG_IOError, "Incorrect Byte Order"); ! } } *************** *** 57,62 **** %typemap(out) FP { ! $result = PyFile_FromFile($1.f, const_cast<char*>($1.name.c_str()), ! const_cast<char*>($1.mode.c_str()), 0); } --- 57,62 ---- %typemap(out) FP { ! $result = PyFile_FromFile($1.f, const_cast<char*>($1.name.c_str()), ! const_cast<char*>($1.mode.c_str()), 0); } *************** *** 64,66 **** %exception; - --- 64,65 ---- |
From: <de...@us...> - 2004-03-30 10:45:57
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29884 Modified Files: DataArchive.h Log Message: see CHANGES.current Index: DataArchive.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/DataArchive.h,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** DataArchive.h 19 Oct 2003 23:53:56 -0000 1.22 --- DataArchive.h 30 Mar 2004 10:34:17 -0000 1.23 *************** *** 31,35 **** #include <SimData/Uniform.h> #include <SimData/Link.h> ! #include <SimData/Exception.h> #include <SimData/HashUtility.h> #include <SimData/Namespace.h> --- 31,35 ---- #include <SimData/Uniform.h> #include <SimData/Link.h> ! #include <SimData/ExceptionBase.h> #include <SimData/HashUtility.h> #include <SimData/Namespace.h> |
From: <de...@us...> - 2004-03-30 10:45:28
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29740 Modified Files: cSimData.i Log Message: see CHANGES.current Index: cSimData.i =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/cSimData.i,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** cSimData.i 14 Mar 2004 04:19:23 -0000 1.14 --- cSimData.i 30 Mar 2004 10:33:46 -0000 1.15 *************** *** 55,59 **** } ! %include "SimData/Exception.i" %include "SimData/HashUtility.i" %include "SimData/Conversions.i" --- 55,59 ---- } ! %include "SimData/ExceptionBase.i" %include "SimData/HashUtility.i" %include "SimData/Conversions.i" *************** *** 66,82 **** $action } catch (SIMDATA(PythonException) &e) { ! printf("SWIG: passing Python exception back\n"); ! e.details(); ! return NULL; } catch (SIMDATA(Exception) e) { ! printf("SWIG: caught a SimData Exception\n"); ! //e.details(); ! PyErr_SetString(PyExc_RuntimeError, e.getError().c_str()); ! return NULL; } catch (...) { ! printf("SWIG: passing C++ exception back\n"); ! PyErr_SetString(PyExc_RuntimeError, "Unknownn C++ exception"); ! return NULL; ! } } --- 66,82 ---- $action } catch (SIMDATA(PythonException) &e) { ! printf("SWIG: passing Python exception back\n"); ! e.details(); ! return NULL; } catch (SIMDATA(Exception) e) { ! printf("SWIG: caught a SimData Exception\n"); ! //e.details(); ! PyErr_SetString(PyExc_RuntimeError, e.getError().c_str()); ! return NULL; } catch (...) { ! printf("SWIG: passing C++ exception back\n"); ! PyErr_SetString(PyExc_RuntimeError, "Unknownn C++ exception"); ! return NULL; ! } } |
From: <de...@us...> - 2004-03-30 10:44:56
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29650 Modified Files: BaseType.i Log Message: see CHANGES.current Index: BaseType.i =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/BaseType.i,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** BaseType.i 1 Feb 2004 12:06:44 -0000 1.4 --- BaseType.i 30 Mar 2004 10:33:17 -0000 1.5 *************** *** 24,36 **** %} ! %import "SimData/Exception.i" %exception BaseType { ! try { ! $action ! } catch (SIMDATA(ParseException) e) { ! e.details(); ! SWIG_exception(SWIG_RuntimeError, ""); ! } } --- 24,36 ---- %} ! %import "SimData/ExceptionBase.i" %exception BaseType { ! try { ! $action ! } catch (SIMDATA(ParseException) e) { ! e.details(); ! SWIG_exception(SWIG_RuntimeError, ""); ! } } |
From: <de...@us...> - 2004-03-30 10:44:22
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29537 Modified Files: BaseType.h Log Message: see CHANGES.current Index: BaseType.h =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/BaseType.h,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** BaseType.h 19 Oct 2003 23:53:56 -0000 1.12 --- BaseType.h 30 Mar 2004 10:32:45 -0000 1.13 *************** *** 38,42 **** #include <SimData/Export.h> #include <SimData/Namespace.h> ! #include <SimData/Exception.h> --- 38,42 ---- #include <SimData/Export.h> #include <SimData/Namespace.h> ! #include <SimData/ExceptionBase.h> |