This seems not not be working on my nexus4.  There is a range of zoom values where nothing changes on the screen, so I assumed that the computed maxHardwareZoom is too low in that case.  Then, when it says I'm zoomed in 4x, the camera takes photos that are much more zoomed in than what is shown on the viewfinder.