]> git.mxchange.org Git - simgear.git/commitdiff
This class is for plib only
authorfredb <fredb>
Tue, 7 Nov 2006 07:22:48 +0000 (07:22 +0000)
committerfredb <fredb>
Tue, 7 Nov 2006 07:22:48 +0000 (07:22 +0000)
simgear/scene/model/custtrans.cxx [deleted file]
simgear/scene/model/custtrans.hxx [deleted file]

diff --git a/simgear/scene/model/custtrans.cxx b/simgear/scene/model/custtrans.cxx
deleted file mode 100755 (executable)
index 7957a61..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
-     $Id$
-*/
-
-#include "custtrans.hxx"
-void _ssgPushMatrix ( sgMat4 m );
-void _ssgPopMatrix  ();
-
-void SGCustomTransform::copy_from( SGCustomTransform *src, int clone_flags )
-{
-  ssgBranch::copy_from( src, clone_flags );
-  _callback = src->_callback;
-  _data = src->_data;
-}
-
-ssgBase *SGCustomTransform::clone( int clone_flags )
-{
-  SGCustomTransform *b = new SGCustomTransform;
-  b -> copy_from( this, clone_flags );
-  return b;
-}
-
-
-SGCustomTransform::SGCustomTransform()
- : _callback(0),_data(0)
-{
-  type = ssgTypeBranch();
-}
-
-SGCustomTransform::~SGCustomTransform()
-{
-}
-
-void SGCustomTransform::cull( sgFrustum *f, sgMat4 m, int test_needed )
-{
-  if ( ! preTravTests( &test_needed, SSGTRAV_CULL ) )
-    return;
-
-  if ( _callback ) {
-    sgMat4 tmp;
-    _callback( tmp, f, m, _data );
-
-    _ssgPushMatrix( tmp );
-    glPushMatrix();
-    glLoadMatrixf( (float *) tmp );
-
-    for ( ssgEntity *e = getKid ( 0 ); e != NULL; e = getNextKid() )
-      e -> cull( f, tmp, test_needed );
-
-    glPopMatrix();
-    _ssgPopMatrix();
-  }
-  postTravTests( SSGTRAV_CULL );
-}
-
-
-const char *SGCustomTransform::getTypeName (void) { return "SGCustomTransform"; }
diff --git a/simgear/scene/model/custtrans.hxx b/simgear/scene/model/custtrans.hxx
deleted file mode 100755 (executable)
index 2b0da4a..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-/**
- * $Id$
- */
-
-#ifndef _SG_CUSTOM_TRANSFORM_HXX
-#define _SG_CUSTOM_TRANSFORM_HXX 1
-
-class SGCustomTransform : public ssgBranch
-{
-public:
-    typedef void (*TransCallback)( sgMat4 r, sgFrustum *f, sgMat4 m, void *d );
-    virtual ssgBase *clone( int clone_flags = 0 );
-    SGCustomTransform();
-    virtual ~SGCustomTransform(void);
-
-    void setTransCallback( TransCallback c, void *d ) {
-        _callback = c;
-        _data = d;
-    }
-
-    virtual const char *getTypeName(void);
-    virtual void cull( sgFrustum *f, sgMat4 m, int test_needed );
-
-protected:
-    virtual void copy_from( SGCustomTransform *src, int clone_flags );
-
-private:
-    TransCallback _callback;
-    void *_data;
-};
-
-#endif // _SG_CUSTOM_TRANSFORM_HXX