Created
March 27, 2012 21:38
-
-
Save anonymous/2220577 to your computer and use it in GitHub Desktop.
a guest on Mar 27th, 2012 - pastebin.com/1QSjwaTw
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
my best solution so far: changing the updateTransformation function to take the transformation as an argument and then change the variable... something like updateTransformation({'rotate':-0.05}); | |
$('#rotateLeft').click(function() { | |
rotate -= 0.05; | |
updateTransformation(); | |
}); | |
$('#rotateRight').click(function() { | |
rotate += 0.05; | |
updateTransformation(); | |
}); | |
$('#translateLeft').click(function() { | |
translationX -= 5; | |
updateTransformation(); | |
}); | |
$('#translateRight').click(function() { | |
translationX += 5; | |
updateTransformation(); | |
}); | |
$('#translateUp').click(function() { | |
translationY -= 5; | |
updateTransformation(); | |
}); | |
$('#translateDown').click(function() { | |
translationY += 5; | |
updateTransformation(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment