For JPX decoding only read next packet after checking for byte aligning.

This patch makes the image from #5349 appear correctly, however artefacts
for the last packet seem to still be there.
This patch also optimizes some "in-checks" and adds a few header parsings.
Furthermore, I noticed that the some resulting images (the dropcam on page 3 of http://www.eclipse-worldwide.com/jq1/media/Eclipse_Client_Deck.pdf) almost look correct if the `continue` statement is removed. (According to jj2000, the dropcam image does not have any empty packets). Maybe this little insight helps for debugging.