Since we're dealing with two very different sensors here we're going to show you a few 100% crops and compare them. We have a full set of full resolution images waiting as well and we've taken them on the HTC One (M8) at the maximum 4 MP resolution as well as 8 MP in Superior Auto and 20.7 MP in Manual mode from the Sony Xperia Z2.
First we upsized the HTC One (M8) 4 MP samples to 8 MP and 20.7 MP as that would allow us to compare the resolved detail to those of the Xperia Z2. Downsizing the Xperia Z2 samples would have been unfair as it would have resulted in loss of detail.
We've also included a couple of crops showing the detail from both phones at their natural resolution - 4 MP vs 8 MP and 20.7 MP.
You'd expect to see the best of both performers in good light where the sensor can gulp up as much detail as possible. The Sony Xperia Z2 does a fine job of detailing the scene and doesn't struggle with small, low-contrast objects like the fence or the edges of the walls. It even manages to show the wall texture. The HTC One (M8) is a different story - it can't even come closer to the amount of detail its rival resolves. The processing isn't quite ideal on either contender - there are obvious traces of oversharpening on the (M8), while the Xperia Z2 suffers from overly aggressive noise reduction.
When shooting objects that are further away, such as landscape or cityscape, the HTC One (M8)'s lower resolution becomes a bigger liability as there are simply not enough pixels to describe the different objects. The Sony cameraphone manages to pull out much more detail and everything looks crisper and sharper.
Color balance is another area where the Xperia Z2 seems to have an advantage - while neither phone is spot on, we find its warmer colors better than the colder ones on the HTC One (M8).
And now the crops from the native resolutions. As you can see the HTC One (M8) can barely match the Sony Xperia Z2 at per-pixel level - hardly ideal when you have 2 times fewer pixels as is the case when you use the Superior Auto mode on the Xperia Z2.
When we view the 20.7 MP vs the 4 MP samples, the difference in total resolved detail is even more dramatic, even if the Sony Xperia Z2 no longer leads in the per-pixel battle.
As usual if you want to do some extensive pixel peeping yourselves we've secured the full resolution shots. As follows those are of the Sony Xperia Z2 in Superior Auto mode at 8 MP in 16:9, the 4 MP 16:9 HTC One (M8) ones and finally full resolution Sony Xperia Z2 20.7 MP Manual mode images.
Here goes out photo quality comparison tool if you want to check out resolution, sharpness, noise and color performance under lab conditions.
Winner: Sony Xperia Z2. The larger pixels of the HTC One (M8) camera should give it an edge in low-light conditions (though we are yet to see if they will be able to make up for the smaller sensor), but the low-res camera simply can't compete when the lighting conditions are good.
Moving on to low light, we've prepped a comparison between the HTC One (M8) and Sony Xperia Z2 with and without their flashes enabled. We've tested the One (M8) at its native resolution at 4 MP compared to the Xperia Z2 at both 8 MP and 20.7 MP resolutions.
Here the bigger pixels of the HTC One (M8) should play a huge role of allowing more light in. The two cameras do produce equally exposed images, but they have a different approach towards achieving it.
While the Sony Xperia Z2 chose to up the ISO to 400 and give a 1/32s shutter speed, the HTC smartphone took images at a maximum of 200 ISO going for a shutter speed of 1/17s. This means that the One (M8) should produce cleaner images with less noise, but at least half of those are expected to have hand-shake induced blur.
Looking at the pictures we see the larger pixels and the lower ISO helping the HTC One (M8) actually produce a cleaner image, but one with slightly less detail than on the Sony Xperia Z2.
Looking at the Sony Xperia Z2's 20.7 MP images reveals that there's hardly anything to be gained by switching to that mode - it doesn't bring extra detail over the 8MP Superior Auto and it certainly results in noisier images as it doesn't have the benefit of oversampling.
Neither smartphone has impressively-powerful flash. We'd say the two are about even despite the HTC One (M8) having an extra LED to throw into the action.
Once again here are the full resolution images.
Winner: Tie. We do prefer the Sony Xperia Z2 approach of going for faster shooting speeds, but the HTC One (M8) does produce less noisy images, which are only slightly behind in terms of detail
In this chapter we'll be looking at HDR and defocus images. HDR stands for high dynamic range and is done by snapping a couple of images with different exposures and then combining them for an image with equally-well exposed scene.
The two phones have different approaches to HDR with the one chosen by the HTC One (M8) particularly puzzling. The phone goes for a slightly over-exaggerated effect boosting the shadows to the point where the image starts to appear very unrealistic. Worse still, it actually pushes the highlights higher, which means that you lose more detail there than in the regular non-HDR shots.
Enabling the mode does produce some rather interesting images on occasion, but we'd suggest you keep it off whenever the image quality is crucial to you.
The Sony Xperia Z2 goes for a far more moderate application of the effect, bringing back some lost detail in both the highlights and the shadows without going overboard.
We'll also take a look at HTC's UFocus and Sony's Background Defocus effects. Both modes will create a faux bokeh (out of focus, blurred, area) behind the subject of the image. Sony's flagship relies on a few photos it captures in a quick sequence, while the HTC flagship has the second depth-analyzing sensor, which should give it an edge in calculation at least.
However, we weren't very impressed with the performance of either phone as they both have plenty of problems separating the subject from the background. It's more visible on the HTC shot as the blur applied is more intensive and so the defects are more visible, but the Xperia Z2 is not doing too hot either. It turns out that the second camera gamble didn't pay off for HTC as it can't even provide an advantage in the one mode it was designed for.
Here go the full resolution samples for your viewing pleasure.
Winner: Sony Xperia Z2. The Xperia Z2 has the better HDR, while the second camera didn't really help the One (M8) win the background defocus competition.