rotation - Recalculate the rotating angle in android -


i rotate , scale image view . after took matrix valve image using method getimagematrix()

in order apply same scaling , rotation image view recalculated rotating angle using expression

float[] v = new float[9]; matrix.getvalues(v); float rangle = math.round(math.atan2(v[matrix.mskew_x], v[matrix.mscale_x]) * (180 / math.pi)); 

but gives -ve of original rotation. example if original rotation +90 recalculated angle -90, why happing ?


Comments

Popular posts from this blog

account - Script error login visual studio DefaultLogin_PCore.js -

xcode - CocoaPod Storyboard error: -