Scale touch inputs based on the ratio of the stream size to the screen size

This commit is contained in:
Cameron Gutman
2014-11-19 23:26:50 -08:00
parent 307e807c8f
commit 848ed1ad72
2 changed files with 15 additions and 4 deletions

View File

@@ -186,7 +186,9 @@ public class Game extends Activity implements SurfaceHolder.Callback,
// Initialize touch contexts
for (int i = 0; i < touchContextMap.length; i++) {
touchContextMap[i] = new TouchContext(conn, i);
touchContextMap[i] = new TouchContext(conn, i,
((double)prefConfig.width / (double)screenSize.x),
((double)prefConfig.height / (double)screenSize.y));
}
if (LimelightBuildProps.ROOT_BUILD) {