0

When I'm trying to open a tif file with typical image editors I get a message that the tif is corrupt, but it is not.

When I do in bash : hexdump -c file.tif | head

I get :

0000000 S F S 0 1 e - � � � z � e 3 � 216 0000010 � S j � W o 205 021 215 006 � 024 E � - S 0000020 X � \0 036 022 � 022 � k n 221 � O 235 031 4 0000030 M � � \0 h � � j � J � 232 � � � ^ 0000040 232 > � g 031 � 232 , W 206 u z @ � 6 210 0000050 � � k � 022 220 b � 026 } 202 � � & m
0000060 � � 001 T ` 034 215 i 215 031 � \n 222 � 0 � 0000070 202 � 215 � � t � � B 210 � W � � 236 221 0000080 / � 237 b O 213 a � \t d 231 ; ~ > � 023 0000090 � � N 030 � . ! 033 026 � C E ; \b 231 ;

What does this mean? How to interpret this?

1 Answers1

1

All TIFF files begin with "II" or "MM" to indicate byte order as Intel or Motorola... yours looks kind of wrong...

If you are on Linux or OSX, try "file file.tif" to see what your system makes of it.

Here is a TIF file from my Mac using "od -xc file.tif"...

0000000      4949    002a    0008    0000    0015    00fe    0004    0001
           I   I   *  \0  \b  \0  \0  \0 025  \0 376  \0 004  \0 001  \0

Is it abandonwarering?

Extract resources from a SFS file

Mmmm... ok it is not a straightforward TIF and not a standard SFS file. I would try running:

od -x  yourfile   | egrep "4949|4d4d"

to see if you find the start of a TIFF file with Intel or Motorola byte ordering. If you do, calculate the offset from the first column, and use that as an offset into "dd". So, if the offset is 512 bytes, I would do

dd if=yourfile of=test.tif bs=512 iseek=1
Community
  • 1
  • 1
Mark Setchell
  • 191,897
  • 31
  • 273
  • 432
  • Thanks for the reply, bash gives me back : 2007_4_10.tif: data . – shooting-squirrel Dec 02 '13 at 16:31
  • Well, it would give TIF file if it thought it was a TIF... so I am saying it agrees that your file is corrupted. – Mark Setchell Dec 02 '13 at 16:33
  • I could guarantee it's not, it's used by a game to handle graphics for a character. – shooting-squirrel Dec 02 '13 at 16:34
  • I understand that it might not be a tif file, but I can guarantee that this file is being used by a program to display graphics. – shooting-squirrel Dec 02 '13 at 16:39
  • It's not abandonwavering, it's a small game I bought a while ago http://www.gazetamatematica.net/. I've also tryed using sfs extractors but it did not work. – shooting-squirrel Dec 02 '13 at 16:42
  • Thanks for the replies, I would vote your answer but I don't have enough reputation. – shooting-squirrel Dec 02 '13 at 16:47
  • After doing od -x yourfile | egrep "4949|4d4d" I get 0000560 8489 1b0f 3738 4d4d c985 cd2e bc20 6a7d . How could I calculate the offset byte in this case? Still not sure what od -x does even tough i got it's man page. – shooting-squirrel Dec 02 '13 at 17:00
  • It's on 24th line, 5th collumn. How does one define the offset ? – shooting-squirrel Dec 02 '13 at 17:14
  • @shooting-squirrel, you start with the address at the beginning of the line, 0000560. It's an octal number. Now you count out to the start of the found pattern, in this case it starts at 566. Now convert from octal to decimal to get 374. (Hope you didn't read this when I showed hex instead of octal). – Mark Ransom Dec 02 '13 at 17:20
  • Sorry that didn't work out - I have used the technique with great success to recover a friend's wedding photos from a corrupt memory card. You could try posting the file somewhere online and give us access to it - I may be able to read it for you. Else, you may just have to screen capture whatever the picture is while the game is running... – Mark Setchell Dec 03 '13 at 08:50