You are not logged in.

#1 2012-10-27 09:46:04

sant527
Member
Registered: 2009-06-21
Posts: 273

3gp video - moov atom not found

I have downloaded a video partillay. When i try to play with mplayer it doesnt play. I tried to reencode it with ffmpeg - it says move atom not found.

I have googled a lot and found some information using http://stackoverflow.com/questions/1213 … d-mp4-file

As per this site it says copy the esds line from good file to corrupted file

I tried to use hex editor, Atomicparsley. I got some idea how to copy, paste and insert hex data from partially downloaded 3gp file to good 3gp file.

Once I was succefull, that too the not so clear. But later whenever i try its not working.


I also tried another method http://blog.alwayshere.info/2011/01/ffm … found.html

Here it says copy the mdat from the corrupted file to the good file

I tried this , Once it showed very unclear video. BUt later whenever i  try its not working.


I also tried another method http://vcg.isti.cnr.it/~ponchio/untrunc.php

when i tried to compile the source code using make it gives me some errors which i cant figure out

the following is the output:



$ make
g++ -c -pipe -march=i686 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt/mkspecs/linux-g++ -I. -I/usr/include/QtCore -I/usr/include/QtGui -I/usr/include -I. -I. -o main.o main.cpp
main.cpp: In member function ‘bool Atom::parse(QFile&)’:
main.cpp:129:26: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
main.cpp: In member function ‘Atom* Mp4::readTruncated(const QString&)’:
main.cpp:208:52: warning: converting ‘false’ to pointer type ‘Atom*’ [-Wconversion-null]
main.cpp: In function ‘bool rebuildIndex(QByteArray&, Index&, Index&, AVCodecContext*, AVCodecContext*)’:
main.cpp:331:8: warning: ‘int avcodec_open(AVCodecContext*, AVCodec*)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3380) [-Wdeprecated-declarations]
main.cpp:331:41: warning: ‘int avcodec_open(AVCodecContext*, AVCodec*)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3380) [-Wdeprecated-declarations]
main.cpp:340:12: warning: ‘int avcodec_open(AVCodecContext*, AVCodec*)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3380) [-Wdeprecated-declarations]
main.cpp:340:45: warning: ‘int avcodec_open(AVCodecContext*, AVCodec*)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3380) [-Wdeprecated-declarations]
main.cpp: In function ‘void writeIndex(Atom*, Index&, unsigned int)’:
main.cpp:446:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
main.cpp:434:11: warning: unused variable ‘stsc’ [-Wunused-variable]
main.cpp: In function ‘int main(int, char**)’:
main.cpp:462:18: error: ‘avcodec_init’ was not declared in this scope
main.cpp:468:68: error: ‘av_open_input_file’ was not declared in this scope
main.cpp:475:8: warning: ‘int av_find_stream_info(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:1357) [-Wdeprecated-declarations]
main.cpp:475:35: warning: ‘int av_find_stream_info(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:1357) [-Wdeprecated-declarations]
main.cpp:481:39: error: ‘dump_format’ was not declared in this scope
main.cpp:535:9: warning: unused variable ‘video_framerate’ [-Wunused-variable]
main.cpp:536:9: warning: unused variable ‘audio_framerate’ [-Wunused-variable]
make: *** [main.o] Error 1
$

Some one help me to view the partially downloaded video files

Offline

#2 2012-11-19 11:11:17

pfeyz
Member
Registered: 2012-11-19
Posts: 1

Re: 3gp video - moov atom not found

I'm dealing with the same issue right now. The untrunc code is using deprecated functions from libavcodec and libavformat (and I have no idea where dump_format is supposed to live). This patch updates it so the code compiles.

http://pfeyz.com/tmp/untrunc.patch

You can apply it with

 $ patch < untrunc.patch

Assuming main.cpp is in your current dir. Unfortunately I'm still not sure exactly how to use untrunc, but hopefully this helps.

Offline

Board footer

Powered by FluxBB