In the example I showed above, the bottom value is half of the window (in relations to the screen width zoomed in/out). The number above that is where the mouse is on the scene.
Example 1: if the zoom is 1, the half window will be 320 and the mouse on the screen will also be 320.
Example 2: if the zoom is 0.5, the half window is now 640 because the total window would be 1280 and the mouse will still be 320 because it is in the middle of the screen.
Example 3 (would be off of the screen): If zoom is 2, the half window will be 160 because the total window will be 320. The mouse would always be at 320.
Knowing that information, the camera could shift along the same lines as the zoom.
1: The camera would be at 0,0 for the screen to be centered
2: The camera would be at -320,0 since the screen is 1280 instead of 640, the 320 shift to the left would center it on the x
3: The camera would be at 160,0 since the screen is 320 instead of 640, the 160 to the right would center it for x.