Skip to content

Commit

Permalink
Fix #281: Sequel: pan with the right button as in eqPly
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Eilemann authored and Stefan Eilemann committed Aug 15, 2014
1 parent a5a1f64 commit f4b5d5e
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions seq/viewData.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

/* Copyright (c) 2011-2012, Stefan Eilemann <[email protected]>
/* Copyright (c) 2011-2014, Stefan Eilemann <[email protected]>
* 2012, Daniel Nachbaur <[email protected]>
*
* This library is free software; you can redistribute it and/or modify it under
Expand Down Expand Up @@ -178,12 +178,8 @@ void ViewData::moveModel( const float x, const float y, const float z )
if( x == 0.f && y == 0.f && z == 0.f )
return;

Vector3f translation;
_modelMatrix.get_translation( translation );
if( translation.squared_length() < 0.01f )
_modelMatrix.set_translation( translation + Vector3f( x, y, z ));
else
_modelMatrix.scale_translation( Vector3f( 1.f + x, 1.f + y, 1.f + z ));
_modelMatrix.set_translation( _modelMatrix.get_translation() +
Vector3f( x, y, z ));
setDirty( DIRTY_MODELMATRIX );
}

Expand Down

0 comments on commit f4b5d5e

Please sign in to comment.