Run time type identification
[melted] / mlt++ / src / MltTractor.cpp
index bb6a449..8187a28 100644 (file)
@@ -28,6 +28,16 @@ Tractor::Tractor( ) :
 {
 }
 
+Tractor::Tractor( Service &tractor ) :
+       instance( NULL )
+{
+       if ( tractor.type( ) == tractor_type )
+       {
+               instance = ( mlt_tractor )tractor.get_service( );
+               inc_ref( );
+       }
+}
+
 Tractor::Tractor( mlt_tractor tractor ) :
        instance( tractor )
 {