Author Topic: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread  (Read 916135 times)

Offline mvpel

  • Full Member
  • ****
  • Posts: 1124
  • New Hampshire
  • Liked: 1295
  • Likes Given: 1686
Here's the collected mmb's for frame 92 from the above posts:

0:0:550,14:0:-1,25:10:17410,26:10:31150,
17:11:33650,17:12:37648,25:12:39009,
29:12:-1,32:12:-1,17:13:42121,18:13:42526,
10:14:-1,17:14:52765,18:14:-1,24:14:-1,
21:15:-1,22:15:-1,34:15:56061,24:16:-1,
27:16:61466,42:19:-1,43:19:83153,43:20:-1,
1:21:90585,11:22:-1,12:22:99201,26:22:-1,
17:23:105394,22:24:-1,23:24:111581,0:27:-1,
16:27:124815,24:27:-1,25:27:125621,28:28:-1,
3:29:140154
« Last Edit: 05/18/2014 02:22 AM by mvpel »
"Ugly programs are like ugly suspension bridges: they're much more liable to collapse than pretty ones, because the way humans (especially engineer-humans) perceive beauty is intimately related to our ability to process and understand complexity. A language that makes it hard to write elegant code makes it hard to write good code." - Eric S. Raymond

Offline Untribium

  • Member
  • Posts: 32
  • Switzerland
  • Liked: 32
  • Likes Given: 78
Some progress on the top half of the frame and the left leg. Also removed some duplicate -1s
0:0:550,14:0:-2:0:0:0:0:12:-6,7:5:14749,12:5:15312,39:7:-1,18:9:27558,
25:10:17410,26:10:31150,17:11:33650,17:12:37648,25:12:39009,29:12:-1,
32:12:-1,17:13:42121,18:13:42526,10:14:-1,18:14:47626,26:14:-1,34:15:56061,
24:16:-1,27:16:61466,42:19:-1,43:19:83153,43:20:-1,1:21:90585,11:22:-1,
12:22:99201,26:22:-1,17:23:105394,22:24:-1,23:24:111581,0:27:-1,
16:27:124815,24:27:-1,25:27:125621,28:28:-1,3:29:140154
I think 23:14 needs some bits flipped...the part of the right leg is one block (half a macro block) off, which is pretty bad...
« Last Edit: 05/18/2014 03:22 AM by Untribium »

Offline Asmegin

  • Member
  • Posts: 35
  • Canada
  • Liked: 21
  • Likes Given: 3
Some progress on the top half of the frame and the left leg. Also removed some duplicate -1s
0:0:550,14:0:-2:0:0:0:0:12:-6,7:5:14749,12:5:15312,39:7:-1,18:9:27558,
25:10:17410,26:10:31150,17:11:33650,17:12:37648,25:12:39009,29:12:-1,
32:12:-1,17:13:42121,18:13:42526,10:14:-1,18:14:47626,26:14:-1,34:15:56061,
24:16:-1,27:16:61466,42:19:-1,43:19:83153,43:20:-1,1:21:90585,11:22:-1,
12:22:99201,26:22:-1,17:23:105394,22:24:-1,23:24:111581,0:27:-1,
16:27:124815,24:27:-1,25:27:125621,28:28:-1,3:29:140154
I think 23:14 needs some bits flipped...the part of the right leg is one block (half a macro block) off, which is pretty bad...

Nice job on the ocean! Before I had to step out I got a bit at the top but I didn't save it! Ahh, will keep trying. Also gonna try and work on the base of the legs. Dunno about that block on the right leg, I'm not knowledgeable enough to figure out what's happening there  ;D

Offline Untribium

  • Member
  • Posts: 32
  • Switzerland
  • Liked: 32
  • Likes Given: 78
Some progress on the top half of the frame and the left leg. Also removed some duplicate -1s
-snip-
I think 23:14 needs some bits flipped...the part of the right leg is one block (half a macro block) off, which is pretty bad...

Nice job on the ocean! Before I had to step out I got a bit at the top but I didn't save it! Ahh, will keep trying. Also gonna try and work on the base of the legs. Dunno about that block on the right leg, I'm not knowledgeable enough to figure out what's happening there  ;D

Happened to me with frame 52, closed the tab by accident :'( :) The ocean seems to be pretty much intact, it's just really time consuming to find the address of the next block after a bad one...brute force ftw! :D

Offline Asmegin

  • Member
  • Posts: 35
  • Canada
  • Liked: 21
  • Likes Given: 3
Frame 92:

23:14:49203 gives you a piece of the circle between the legs. Only the left blocks are correct though... Doesn't help the right side of the right leg either :p

Also there is something at 54419. I thought it was the edge of the rocket base but it doesn't fit anywhere. Might be a wave...
« Last Edit: 05/18/2014 04:06 AM by Asmegin »

Offline wronkiew

  • Full Member
  • *
  • Posts: 186
  • 34.502327, -116.971697
  • Liked: 105
  • Likes Given: 121
Interpolated descent between frames 150 and 168.

Many thanks to SwissCheese for demonstrating how to apply p-frames.

It looks good! How did you do the interpolation? Did you use information from the P-frames? I was thinking about interpolating the moving vector fields for the non-usable P-frames, or somehow better using them, but I'm stuck...

I used the ocean blobs from the i-frames at each end and p-frames 153, 159, and 166 as control points, then I interpolated each transformation variable with a spline. I scripted Hugin to do the transformations. P-frame 159 was applied directly, except for a bit of shifting and masking to get the timestamp in the right place. P-frames 151 and 154 were also applied but only half of the ocean for each was useable. Basically I took the previous frame, pretended it was an i-frame, created a movie with just that and one p-frame, and then broke it up into images again.

Bits and pieces of other p-frames were pasted in, but I did not attempt to apply the mpg4-img in those cases.


Offline Asmegin

  • Member
  • Posts: 35
  • Canada
  • Liked: 21
  • Likes Given: 3
Frame 229

0:0:-1,4:13:63400,20:15:74510,2:16:77453

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
Hi!

You guys are amazing! I really thought the legs were a goner on that frame. But oooh no! :)

Here is my version of 229 with edit8. It was still missing from the video.

0:0:-1,
9:12:59273:25:1:1:1:1:1,
0:21:99181,0:25:-1,
1:25:113405,7:29:-1

It needs some love though. ;)

I am going to make a new video again with these new frames.

Regards,

arnezami

PS. The 1:1:1:1:1 is in these because the online editor removes the 0:0:0:0:0. Maybe somebody can take a look at that...

Offline Asmegin

  • Member
  • Posts: 35
  • Canada
  • Liked: 21
  • Likes Given: 3
Looks like we had the same idea. Yours looks a bit cleaner though :)

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
Hmmm. I've got some issues. I don't understand whats causing them. Looks like ffmpeg is not cooperating...

For some reason when I use this command frames 189, 229 and 268 are missing. (these are frames 197, 237 and 276 according to ffmpeg btw).

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8.ts -f image2 img-%03d.png 2> debug.log

See attached mmb.txt (you will have to remove the newlines before using it).

If you look at the pictures it generated (careful the frame number in the filename is 1 higher then the frame number according to ffmpeg) you see all the i-frames except the above mentioned.

When I run the same command with the three i-frame commands removed then 189 appears again (in its original form) while 229 and 268 are still missing.

Why is ffmpeg not adding these frames to the output?? I can't see anything in the log either. Can we force it somehow? But I'm no expert at using ffmpeg. Hopefully somebody else can help here.

Regards,

arnezami

Offline SwissCheese

  • Full Member
  • *
  • Posts: 164
  • Liked: 249
  • Likes Given: 90
Hmmm. I've got some issues. I don't understand whats causing them. Looks like ffmpeg is not cooperating...

For some reason when I use this command frames 189, 229 and 268 are missing. (these are frames 197, 237 and 276 according to ffmpeg btw).

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8.ts -f image2 img-%03d.png 2> debug.log

See attached mmb.txt (you will have to remove the newlines before using it).

If you look at the pictures it generated (careful the frame number in the filename is 1 higher then the frame number according to ffmpeg) you see all the i-frames except the above mentioned.

When I run the same command with the three i-frame commands removed then 189 appears again (in its original form) while 229 and 268 are still missing.

Why is ffmpeg not adding these frames to the output?? I can't see anything in the log either. Can we force it somehow? But I'm no expert at using ffmpeg. Hopefully somebody else can help here.

Regards,

arnezami

For me the mmb for multiple frames does only work for the first one... (FRAME0) after that it does not work at all, somehow it uses some of the mmb of the first frame for the next one. No idea why.

Hi!

You guys are amazing! I really thought the legs were a goner on that frame. But oooh no! :)

Here is my version of 229 with edit8. It was still missing from the video.

0:0:-1,
9:12:59273:25:1:1:1:1:1,
0:21:99181,0:25:-1,
1:25:113405,7:29:-1

It needs some love though. ;)

I am going to make a new video again with these new frames.

Regards,

arnezami

PS. The 1:1:1:1:1 is in these because the online editor removes the 0:0:0:0:0. Maybe somebody can take a look at that...

This is fixed.

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
Hi guys,

Ok. I think it's time to really start going into the P-frames.  :)

Individual P-frames:

Attached is a zip with all the .mpg4-img files of all the 270 frames. These we will need to do check the P-frames individually. P-frames are "delta" frames so they will look a little weird. For now the most important thing to do with these P-frames is aligning the MBs to the bitpositions. Luminosity and chrominance (the DC-values) will come later. Also: focus first on the P-frames right after the I-frames, since all other P-frames after that will look better if they get better.

Here are the most common things to do (taken from here).

1. To check individual P-frames (original):

Quote
./ffmpeg -debug mb_pos_size -err_detect ignore_err -s:0 704:480 -i frame192.mpg4-img -f image2 frame_192.png

2. To check individual P-frames (original, with arrows indicating movement):

Quote
./ffmpeg -debug mb_pos_size -err_detect ignore_err -vismv 7 -s:0 704:480 -i frame192.mpg4-img -f image2 frame_192_mv.png

3. To check individual P-frames (modified by mmb):

Quote
./ffmpeg -mmb 2:0:-1,19:0:1092 -debug mb_pos_size -err_detect ignore_err -s:0 704:480 -i frame192.mpg4-img -f image2 frame_192_mod.png

4. To check individual P-frames (modified by mmb, and with arrows indicating movement):

Quote
./ffmpeg -mmb 2:0:-1,19:0:1092 -debug mb_pos_size -err_detect ignore_err -vismv 7 -s:0 704:480 -i frame192.mpg4-img -f image2 frame_192_mv_mod.png

We will still have to learn how to modify the P-frames effectively. But you can already experiment with them. This way we may get some basic mmb's for certain P-frames.

Using multiple frames mmb's: making pngs and video

In order for all this to be somewhat doable/managable I've split the fixed_edit8.ts into 15 parts, each starting with an I-frame. These 15 .ts files are attached. They have the i-frame number in their file name for good reference. I propose that we make a wiki page for each of these video parts (each containing about 20 frames: 1 I-frame and the rest P-frames). And on the wiki page where all I-frames (of edit8) are shown we put a link to each of these wiki pages.

We can use multiple mmb's together now, thereby creating a "fixed" part-video or series of pngs. So instead of decoding the whole video we decode only a part.

Each part starts with an I-frame.

Here are the steps to take:

1. Create mmb file for a part. For example:

Quote
vi mmb_starting_from_169.txt

In it you put the mmb's you have made yourself or have gotten from somebody else. Make sure it always starts with FRAME0 (even though it is a higher frame number in the original fixed_edit8.ts). Frame 0 is always the I-frame.

Like so:

Quote
FRAME0:0:0:-1,9:12:59273:25:1:1:1:1:1,0:21:99181=FRAME1:0:25:-1,1:25:113405,7:29:-1

So you make this by adding FRAMExxx: to each mmb you want to add (where xxx is the frame number in this part-file (so if the part starts with frame 169 which would be FRAME0 then frame 171 would be FRAME2). After that you concatenate/put them together with '=' in between.

2. To make pngs:

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb_starting_from_169.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8_part_169.ts -f image2 fixed_edit8_part_169_%03d.png

3. To make video:

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb_starting_from_169.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8_part_169.ts -c:v mpeg4 -q:v 3 -tag:v xvid fixed_edit8_part_169.avi

Here is an example of the video part 169:



I used the current mmb for I-frame 169 and the mmb for P-frame 171 from SwissCheese.

** currently I am still looking into an issue with using multiple-mmbs, but I hope to figure out soon why this doesn't always work as expected. It *should* work, right ;)


Regards,

arnezami

PS. In the attached splitting_into_ts_parts.zip I explain how I split the video into 15 parts. The make_ts_part.c is also in that zip.
PPs. I've also attached a slightly altered h263dec.c which now logs the frame number too.


For me the mmb for multiple frames does only work for the first one... (FRAME0) after that it does not work at all, somehow it uses some of the mmb of the first frame for the next one. No idea why.

Ok. Thanks. I will look into this. It maybe caused by the mmb-reading/interpretation.

« Last Edit: 05/18/2014 03:40 PM by arnezami »

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
For me the mmb for multiple frames does only work for the first one... (FRAME0) after that it does not work at all, somehow it uses some of the mmb of the first frame for the next one. No idea why.
Hi SwissCheese,

I've been trying to find the cause of the multi-mmb's not always working on the P-frames. I'm pretty convinced the mmb-interpretation code is ok and no positions of mb's are changed that shouldn't be changed (I logged a lot to see if all is ok).

I've disabled large parts of the added features (such as X, -1, -2, dc, direction) and just kept the "move mb to bitpos".

In this simplified mode: when I use your mmb from frame 172 in run_sequence.txt and add it to that of 169 it seems to work. Also when I combine the mmb's from 169 and 171. No problem. Only when I combine all three then things go wrong: 172 seems to "freeze" (that is: it doesn't change anything). Like the P-frame is empty. Ok there is a little motion and softening of sharp lines but that's it. Almost if 172 has halted all P-frame activity. Because everything from there stays basicly the same.

But if I set the mmb from 172 to 173 (which is a bit silly of course) everything works just fine. So it seems that the mmb from 171 and 172 are somehow conflicting (or better: the effect of those mmb's).

Do you have simpler example where only a combination of 2 doesn't work? Because I think it's related to what the mmb's are doing to the frames.

I think though that it is something in ffmpeg: some kind of reaction without logging about it. I could sure use some help in this department.

Regards,

arnezami

[edit] I noticed that setting frame 170 to 0:0:-1 (basicly turning it off) it works again! Maybe it's wise to disable unfixed P-frames prior to the one that you are trying to fix?

Basicly you get this: (without the newlines)

FRAME0:08:14:-1:15:-15:1:14:-2:1,
09:14:56683,
05:21:-1:0:-20:-5:2,
06:21:-1:-20:-20:6:5,
07:21:-1:0:0:3:5,
08:21:-1:0:0:0:0,
09:21:-1:10:15:0:0,
10:21:-1:15:15:0:0,
11:21:-1:5:10,
12:21:-1:5:3:0:0:-2,
13:21:-1:4:4,
14:21:-1,
28:21:108878,
X:126932:80,
04:27:-1:0:-4:13:7,
05:27:135412,
X:143273:80,
X:143386:80,
06:28:144012
=FRAME1:0:0:-1
=FRAME2:0:0:-1,31:0:4850,13:2:-1,14:2:12422,2:3:-1,3:3:13866,32:8:50739
=FRAME3:6:20:-1,7:20:84967

I use this command:

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb_starting_from_169.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8_part_169.ts -f image2 fixed_edit8_part_169_%03d.png
« Last Edit: 05/18/2014 01:39 PM by arnezami »

Offline Untribium

  • Member
  • Posts: 32
  • Switzerland
  • Liked: 32
  • Likes Given: 78
Nice work on the P-frames guys! The bits (literally :) ) and pieces are finally coming together!
Can someone more knowledgeable than me and has looked into the bitstream have a look at this and tell me whether it's accurate?
http://www.cmlab.csie.ntu.edu.tw/cml/dsp/training/coding/h263/format_p.html
Could be really helpful for bit flipping :)

edit: Also, is it possible to add the bitstream to the online editor?
« Last Edit: 05/18/2014 01:21 PM by Untribium »

Online Shanuson

  • Full Member
  • **
  • Posts: 272
  • Liked: 184
  • Likes Given: 467
Great work guys. I am happy that my work help many.

The following is important for all of us that are working on the raw video stream file. I will attach 15 parts of raw_edit8.ts each containing a I-Frame and the following P-frames too a follow on post.
 
Some things that should still be done to raw_edit8.ts that again may(!) change the size of the I-Frames, and the numbering for sure.
When you look at the current numbering of the frames you will see that most I-Frames are 20 Frames apart. So there are 19 P-Frames between each I-Frame. There was made no effort at all to find all those in the code and repair the headers.
There should be 14*20+3+(how many P-Frames there are before the first I-Frame) Frames in raw.ts. The 3 is because the last I-frame is followed only by 2 P-frames.
A few days ago I had a discussion with  theshadow27 about that. I think i should summarize it here for everyone:

Like i said before, There are 4 PIDs used, with one 3E8 marking all real data,
With PID 3E8 are 3 kind of headers marked:
4743E83X:
This marks the start of a Frame, Both I-Frame and P-Frame, More to this later.

4703E83X: This should mark the END of a Frame. It is a fill packet, containing the last part if data and the rest of the Packet consists more or less of only FF. I have only checked a few but all those looked like: 4703E8X YY 00 FF FF FF ... Dont know if the YY contains any important information. YY was only one byte, but AFAIUI YY could also be many bytes.

4703E81X: All the rest of the data packets are headed by these 4 bytes.

X incrementing throughout the video stream over all those 3 Headers. It tells how many data packets there should be modulo 16. This helps to identify in messed up parts if there are some data packets missing or if some null packets are interpreted as data.

There are 3 more continuity counters used in the Video, each one for the other 3 PIDs used (000 020 and 1FF, the latter one being a bit tricked, see the end of this post)

I fixed the header of the I-Frames, both the first counter (Green below), and the PTS (time stamp, blue below). The first counter is increasing by 60060(dez) and the PTS is increasing by 120120(dez) between each I-Frame.
The header of P-frame also has both of those in it (the first part is similar to I-Frames):
Here is one P-Frame Header:
47 43 E8 3X 07 10 00 33 59 ED 7E 00 00 00 01 E0 00 00 81 80 07 21 01 9B 19 95 FF FF 00 00 01 B6 5*

So all P-frames should start like that. 00 00 01 B6 5 marking the following data as a P-Frame. (I-Frames have more header data before the 00 00 01 B1 1*)


The other most common PID is 1FFF marking the packet as a null packet, full of FFs and not containing any data.
The CC for those packets is also continuous throughout the file, also from one block of multiple null packets to the next. Yet there is one exception. single null packets entered during the streaming of one frame have a CC of 0. 

So the order of Headers is:

47 43 E8 3X I-Frame header packet
47 03 E8 1X Data packets
47 03 E8 3X Last Data packet partly filled with FFs
maybe one packet with 000 or 020 as PID
47 1F FF 1X Null packets

Followed by 19 times:

47 43 E8 3X P-Frame header packet
47 03 E8 1X Data packets
47 03 E8 3X Last Data packet partly filled with FFs
maybe one packet with 000 or 020 as PID
47 1F FF 1X Null packets

It can be that the Null packets are skipped between frames.
Also single null packets can be added throughout the 47 03 E8 1X data part. Check the CC to see if there could be one.

Lastly, there are still large part of the raw_edit8.ts part where there are no 47 marks to indicate the start of a TS-packet. the largest one is 20*188 byte large.

Cheers Shanuson

(edit: added the link the to follow on post)
« Last Edit: 05/18/2014 11:53 PM by Shanuson »

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
Nice work on the P-frames guys! The bits (literally :) ) and pieces are finally coming together!
Can someone more knowledgeable than me and has looked into the bitstream have a look at this and tell me whether it's accurate?
http://www.cmlab.csie.ntu.edu.tw/cml/dsp/training/coding/h263/format_p.html
Could be really helpful for bit flipping :)

edit: Also, is it possible to add the bitstream to the online editor?

It seems that that is describing the "6.2.5.2  Video Plane with Short Header" from ISO-IEC-14496-2_2001_MPEG4_Visual.pdf. Also see: "6.3.5.2  Video Plane with Short Header". Not entirely sure.

I'm actually not sure our video uses the "short header". I have mostly been focused on the macroblock/variable stuff. But it would be good to confirm, because there could definitely be problems in these headers.

This is also a little interesting:

Quote
short_video_header:  The short_video_header is an internal flag which is set to 1 when an abbreviated header
format is used for video content. This indicates video data which begins with a short_video_start_marker rather
than a longer start code such as visual_object_ start_code.  The short header format is included herein to provide
forward compatibility with video codecs designed using the earlier video coding specification ITU-T
Recommendation H.263.  All decoders which support video objects shall support both header formats
(short_video_header equal to 0 or 1) for the subset of video tools that is expressible in either form.

Offline arnezami

  • Full Member
  • **
  • Posts: 282
  • Liked: 262
  • Likes Given: 345
This is fixed.
Great! Works well now :)

I've been thinking about the P-frames for the online editor. I think what would be useful and fairly easy to add is a third dropdown. What you get is first the option of the ts file (raw_edit8 for example). Then you select the "base I-frame" in the second dropdown. And then you can choose the actual frame (which would default to the first frame (=I-frame)) in the third dropdown.

In the case of edit8 the third drowdown not only contains the I-frame but also the P-frames within the chosen base I-frame. And you keep using the framexxx.mpg4-img files as your input to ffmpeg. That way more ppl can start working on the P-frames. In the case of try1 and coerced you only get one option in the third dropdown, which is always chosen.

Of course this will only show the P-frame individually (not fed by I-frame data). And we should also make sure we can run it though the multi-mmb call to ffmpeg, but thats for later I guess.

Regards,

arnezami
« Last Edit: 05/18/2014 03:18 PM by arnezami »

Offline SwissCheese

  • Full Member
  • *
  • Posts: 164
  • Liked: 249
  • Likes Given: 90
[edit] I noticed that setting frame 170 to 0:0:-1 (basicly turning it off) it works again! Maybe it's wise to disable unfixed P-frames prior to the one that you are trying to fix?

Basicly you get this: (without the newlines)

FRAME0:08:14:-1:15:-15:1:14:-2:1,
09:14:56683,
05:21:-1:0:-20:-5:2,
06:21:-1:-20:-20:6:5,
07:21:-1:0:0:3:5,
08:21:-1:0:0:0:0,
09:21:-1:10:15:0:0,
10:21:-1:15:15:0:0,
11:21:-1:5:10,
12:21:-1:5:3:0:0:-2,
13:21:-1:4:4,
14:21:-1,
28:21:108878,
X:126932:80,
04:27:-1:0:-4:13:7,
05:27:135412,
X:143273:80,
X:143386:80,
06:28:144012
=FRAME1:0:0:-1
=FRAME2:0:0:-1,31:0:4850,13:2:-1,14:2:12422,2:3:-1,3:3:13866,32:8:50739
=FRAME3:6:20:-1,7:20:84967

I use this command:

Quote
./ffmpeg -r 44999/3003 -mmb `cat mmb_starting_from_169.txt` -debug mb_pos_size -err_detect ignore_err  -i fixed_edit8_part_169.ts -f image2 fixed_edit8_part_169_%03d.png

Do you get "nice images"? For me it corrects the first image but does nothing to the next ones...

I checked the code to understand a bit better, and put a printf there:

// if framenumber is in the mmb, check if it is the current one
if ((frame_number_mmb < 0) || (frame_number_mmb == s->avctx->frame_number)) {
   if (frame_number_mmb == s->avctx->frame_number)
      printf("\nframe number ffmpeg: %d\nframe number mmb: %d\ntoken_frame = %s\n\n",s->avctx->frame_number,frame_number_mmb,token_frame);

   while (bitpos == INT_MIN && token_frame && *token_frame) {
      char *token = av_get_token(&token_frame, ",");
      char *token_orig;
      token_orig = token;
      if (*token_frame)
         token_frame++;
      bitpos = get_bitpos_from_mmb_part(s, gb, gb_blank, mb_x, mb_y, token, do_reverse, nr_of_hits_to_ignore);
      av_free(token_orig);
   }
}
av_free(token_frame_orig);

it gives me for example this:
frame number ffmpeg: 3
frame number mmb: 3
token_frame = 6:20:-1,7:20:84967

it reads correctly all mmb sequences, and works as expected for the frame 0, but after that the frame numbers jump between frames 1,2 and 3 quite randomly. Is it the normal behavior? At this point I'm really lost... Maybe it's something related to windows?

Having this in the web app would for sure help a lot, we would have a reference program and only one set of data ;)

I also have mmbs for several P-frames, but can only use them on stand-alone *.mpg4-img frames

Offline Untribium

  • Member
  • Posts: 32
  • Switzerland
  • Liked: 32
  • Likes Given: 78
More progress on #52. Found 3 more rows worth of actual data (including dirt spot #3!), which brings us down to 3 rows of -1 blocks :)
lum/chroma correction is a nightmare though, particularly row 10 (dirt spot)...the luminance error doesn't seem to be a propagation problem, i.e. it occurs in several blocks (which is odd...)
X:76768:80,X:22120:80,40:3:-1,42:3:9061,0:7:-2:-10:-10:-10:-10:8:-5,29:9:21074,34:9:-1,39:9:21626,0:29:81738

edit: also found a bit of the left leg on #150, pretty messed up though...17:12:46027
« Last Edit: 05/18/2014 06:38 PM by Untribium »

Tags: