Join Us!

Viewer for broken j...
 
Notifications
Clear all

Viewer for broken jpeg images  

  RSS
Aniskin
(@aniskin)
New Member

I have some experience in jpeg internals and I created a simple viewer for broken jpeg files. Maybe it will be interesting for somebody.

For example we have a broken jpeg and any standard viewer shows it partially

But this sample has a thumbnail (or several thumbnails) inside. My viewer knows many ways how thumbnails inside jpeg can be stored (about 20 variants include some proprietary) and my viewer shows the same sample as a mix of the main image and the thumbnail image with max dimension

The max thumbnail image I saw has dimension 1440x960 so sometimes resulting combined image can have a very good quality.

Link.

Quote
Posted : 17/01/2019 1:14 pm
jaclaz
(@jaclaz)
Community Legend

Nice. )

If I may, you could rename the thread to something *like*
New Viewer for broken jpeg images"

I read the current "Broken jpeg viewer" title as "Broken jpeg viewer" in the sense that someone was having a problem with a jpeg viewer that was broken. 😯

jaclaz

ReplyQuote
Posted : 17/01/2019 2:41 pm
watcher
(@watcher)
Member

Very nice!

It even runs under Wine with no issues.

Not to complain about free dessert, but if you wouldn't mind a few observations based upon 5 minutes of testing.

The very first thing I think it needs should be easy, and that is a SAVE AS function for the reconstructed image. Other than screen capture, I didn't see a way to do this.

The other observation would be much harder and probably triple the effort of what you've already done which is very useful already. The reconstruction works great on the "End." That is, if I chop off the end of a jpeg to make it broken, it works great. If I take a chunk out of the middle, the reconstruction appears to be only on the end.

Again, very nicely done!

ReplyQuote
Posted : 17/01/2019 4:26 pm
Aniskin
(@aniskin)
New Member

The very first thing I think it needs should be easy, and that is a SAVE AS function for the reconstructed image.

It is planned but some later. I want to implement lossless Save As operation, but it requests some additional investigations.

The reconstruction works great on the "End." That is, if I chop off the end of a jpeg to make it broken, it works great. If I take a chunk out of the middle, the reconstruction appears to be only on the end.

There is no way to automatically detect you case. IMHO the best solution for this scenario is a special repair tool with which you will be able to do all actions manually. It is requests a LOT of work to create such tool and I don`t have so many free time for free projects.

ReplyQuote
Posted : 17/01/2019 4:40 pm
jaclaz
(@jaclaz)
Community Legend

@Watcher
Side-side note, and don't want to derail the topic, but there is JFYI a mis-known (and actually very primitive) tool that in some cases works (with a lot of tries and providing often not a "proper" reconstruction) even when the corruption is near the beginning (but don't expect miracles)
http//directory.s2services.com/jpg-bmp.htm

Jpeg-repair
by Wim VanMaele

jaclaz

ReplyQuote
Posted : 17/01/2019 7:21 pm
JaredDM
(@jareddm)
Active Member

Our company offers JPEG repair service for files affected by bad sectors after imaging https://www.data-medics.com/jpeg-jpg-repair-service-missing-sectors-data-recovery/

It won't help with an image that's half grey at the bottom (such as that one the OP posted) since that means the lower half of the data is just missing, but it will help where it's a case of only some bad sectors and the image has a lot of discoloration, shifts, etc. We simply remove the bad compressed blocks and fill them in with empty placeholders, then fix the color stream.

For people who just want to see their family photos, we'll then fill in the gaps with approximated data. However, for a forensic case, we'd just leave the empty blocks so you'd see some gray lines of empty picture.

ReplyQuote
Posted : 21/01/2019 6:47 pm
athulin
(@athulin)
Community Legend

The max thumbnail image I saw has dimension 1440x960 so sometimes resulting combined image can have a very good quality.

Nice.

From a forensic perspective, however, I think it need to be clearer that a restoration has taken place, and what part (or parts) have been restored. This would be particularly important for a 'save as' operation.

On the other hand, I don't know that's the direction you want to take it – i.e. forensic tool.

ReplyQuote
Posted : 21/01/2019 7:20 pm
Aniskin
(@aniskin)
New Member

I think it need to be clearer that a restoration has taken place, and what part (or parts) have been restored.

There is already this info in the second screenshot in the caption of the window 49% of the original image and 51% of the restored.

ReplyQuote
Posted : 21/01/2019 8:58 pm
Aniskin
(@aniskin)
New Member

A video of first prototype of my jpeg recovery tool. Tool provides lossless restore, all DC/AC coefficients are stored in output file without any modifications (with the exception of deleted MCUs and MCUs created from thumbnail). All metadatas of original image are stored without any modifications too.

If you have jpg images with damages - I am ready to help to restore them (for free).

ReplyQuote
Posted : 14/02/2019 10:46 am
Aniskin
(@aniskin)
New Member

The very first thing I think it needs should be easy, and that is a SAVE AS function for the reconstructed image. Other than screen capture, I didn't see a way to do this.

New version of my jpeg viewer is ready. Now you can save the resulting image as a new jpeg file. Link.

Another useful feature - the program knows about 20 ways to store and encode thumbnails inside jpeg files and allows you to extract them. In this archive you can find samples of all thumbnail types I know and check your favorites tools how they process them.

ReplyQuote
Posted : 09/12/2019 12:53 am
Share: