Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-4 AVC / H.264

Reply
 
Thread Tools Search this Thread Display Modes
Old 22nd September 2005, 14:24   #141  |  Link
leowai
Registered User
 
Join Date: May 2005
Posts: 184
Quote:
Originally Posted by bob0r
Now for .mp4, does x264 need to change code, or does gpac need to change code?
Quote:
Originally Posted by Sirber
@Haali

Problem fixed for MKV. Many thanks!!!!!!

Produced MKV is 100% valid.
From my point of view, since x264 raw-> mp4 works using MP4Box, it's more to the bug in porting x264 with gpac's mp4 output support.

Correct me if I'm wrong. Thanks.

Just curious about this: What's the different between x264 encoder and MP4Box when creating a *.mp4 output? If they are same (using same function), does it means that's the problem in x264 using gpac's mp4 output function?
leowai is offline   Reply With Quote
Old 22nd September 2005, 14:36   #142  |  Link
Sirber
retired developer
 
Sirber's Avatar
 
Join Date: Oct 2002
Location: Canada
Posts: 8,978
For (x264 raw-> mp4), you need to know the FPS, which cound have been altered by user avisynth script, and bork the result MP4. It's best to have it handeled by x264 directly.
__________________
Detritus Software
Sirber is offline   Reply With Quote
Old 22nd September 2005, 16:36   #143  |  Link
bob0r
Pain and suffering
 
bob0r's Avatar
 
Join Date: Jul 2002
Posts: 1,337
Quote:
Originally Posted by Sirber
For (x264 raw-> mp4), you need to know the FPS, which cound have been altered by user avisynth script, and bork the result MP4. It's best to have it handeled by x264 directly.
Hmm yes ofcourse.

psp.avs:
Quote:
LoadPlugin("i:\cap\_x264\_dgdecode.dll")
LoadPlugin("i:\cap\_x264\_decomb521.dll")
LoadPlugin("i:\cap\_x264\_mpasource.dll")
v=mpeg2Source("i:\cap\_x264\cap.d2v")
a=mpasource("i:\cap\_x264\cap.mpa")
audiodub(v,a)
fielddeinterlace()
crop(4,2,712,574)
LanczosResize(368,208)
ChangeFPS(29.97)
psp.bat:
Quote:
start /belownormal /b /w x264 --progress --pass 1 --me dia --ref 1 --subme 1 --analyse none --output NUL psp.avs
start /belownormal /b /w x264 --progress --pass 2 --bitrate 512 --ref 1 --subme 6 --analyse all --output video.264 psp.avs
start /belownormal /b /w MP4Box.exe -fps 29.97 -add video.264 output.mp4
start /belownormal /b /w MP4Box.exe -fps 29.97 -add audio.aac output.mp4
start /belownormal /b /w ATOMChanger.exe output.mp4 MAQ00264.MP4 AtomAVC.ini
I'll try setting the FPS in the x264.exe line too; --fps <float|rational> Specify framerate

--fps 29.97, and then maybe it "fixes" the .mp4 file, ill try

Note the _detected_ fps here:
Quote:
start /belownormal /b /w x264 --progress --pass 1 --me dia --ref 1 --subme 1 --analyse none --output NUL psp.avs
avis [info]: 368x208 @ 29.97 fps (9539 frames)

If i remove ChangeFPS(29.97) from the .avs and --fps 29.97 via x264.exe, will x264 then convert the 25FPS PAL to 29.97?
bob0r is offline   Reply With Quote
Old 22nd September 2005, 17:03   #144  |  Link
movax
Member
 
Join Date: Nov 2004
Location: Michigan
Posts: 217
I think both will certainly convert the framerate, but the telecining/assorted processes that have been done to the PAL video can't be easily fixed by a simple framerate change. (e.g., a 24fps source to 25fps PAL is just speeded up, this is common, but then converting that to 29,97 would be akin to telecining 24fps video, I'm kind of sure.)
movax is offline   Reply With Quote
Old 22nd September 2005, 17:18   #145  |  Link
bob0r
Pain and suffering
 
bob0r's Avatar
 
Join Date: Jul 2002
Posts: 1,337
@movax
Ah yes, well the videos are for Sony PSP, and they work fine with MP4Box, its purely about a working .mp4 now, converting the right way may come later (unless it influences the .mp4 output)

I see i have made a small mistake; avis [info]: 368x208 @ 25.00 fps (7957 frames) is just how many FPS the .avs file is outputting.
I am now trying --fps via x264.exe and ill send the files to my friend to test on his PSP.

avs change 29.97 FPS > .mp4 PSP does not work
avs change 29.97 FPS + x264.exe --fps 29.97 = Needs to be tested
avs 25 FPS (original source) + x264.exe --fps 29.97 = Needs to be tested
... will let you know. (If all fails on PSP, ill remux the audio/video with MP4Box)
Thanks.

Edit:
It seems x264.exe --fps 29.97 does NOT change the video fps, i wonder what it does do
Or is it the same as MP4box, just to set the .mp4 FPS?
In that case, .avs changefps 29.97 + x264.exe .mp4 output --fps 29.97, should create a valid file?

Last edited by bob0r; 22nd September 2005 at 17:34.
bob0r is offline   Reply With Quote
Old 22nd September 2005, 17:50   #146  |  Link
Sirber
retired developer
 
Sirber's Avatar
 
Join Date: Oct 2002
Location: Canada
Posts: 8,978
PSP encoding is kinda OT...
__________________
Detritus Software
Sirber is offline   Reply With Quote
Old 22nd September 2005, 18:18   #147  |  Link
bob0r
Pain and suffering
 
bob0r's Avatar
 
Join Date: Jul 2002
Posts: 1,337
Quote:
Originally Posted by Sirber
PSP encoding is kinda OT...
Not really, it can be used perfectly for .mp4 output testing.

I just encoded:
.avs ChangeFPS(29.97) and x264.exe --fps 29.97, and indeed the .mp4 output file is fucked, so adding --fps 29.97 is indeed b0rked.

Atomchanger.exe goes besoik on this output.mp4!
bob0r is offline   Reply With Quote
Old 3rd December 2005, 17:50   #148  |  Link
bond
Registered User
 
Join Date: Nov 2001
Posts: 9,779
seems jeanlf fixed this framerate problem with gpac:
Quote:
I just fixed 64-bit ts support in isomedia and other parts of GPAC. You should now be able to import with pretty much any kind of timescales and dts - just checked it with a file lasting 4 days with only 31 frames.
can sharktooth or celtic_druid plz make a new compile with latest gpac and anyone who had a crashing sample file test whether it is now fixed?
__________________
Between the weak and the strong one it is the freedom which oppresses and the law that liberates (Jean Jacques Rousseau)
I know, that I know nothing (Socrates)

MPEG-4 ASP FAQ | AVC/H.264 FAQ | AAC FAQ | MP4 FAQ | MP4Menu stores DVD Menus in MP4 (guide)
Ogg Theora | Ogg Vorbis
use WM9 today and get Micro$oft controlling the A/V market tomorrow for free

Last edited by bond; 3rd December 2005 at 17:53.
bond is offline   Reply With Quote
Old 3rd December 2005, 20:07   #149  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,182
You can grab my last compile here...
Kurtnoise is offline   Reply With Quote
Old 3rd December 2005, 20:14   #150  |  Link
Sharktooth
Mr. Sandman
 
Sharktooth's Avatar
 
Join Date: Sep 2003
Location: Haddonfield, IL
Posts: 11,768
that should fix the problems in x264 too...

EDIT: i've just updated gpac and i get tons of undefined references... and obviously it doesnt compile.

Last edited by Sharktooth; 3rd December 2005 at 20:51.
Sharktooth is offline   Reply With Quote
Old 3rd December 2005, 21:15   #151  |  Link
bond
Registered User
 
Join Date: Nov 2001
Posts: 9,779
Quote:
Originally Posted by Sharktooth
that should fix the problems in x264 too...

EDIT: i've just updated gpac and i get tons of undefined references... and obviously it doesnt compile.
the last cvs before the change compiles fine?
__________________
Between the weak and the strong one it is the freedom which oppresses and the law that liberates (Jean Jacques Rousseau)
I know, that I know nothing (Socrates)

MPEG-4 ASP FAQ | AVC/H.264 FAQ | AAC FAQ | MP4 FAQ | MP4Menu stores DVD Menus in MP4 (guide)
Ogg Theora | Ogg Vorbis
use WM9 today and get Micro$oft controlling the A/V market tomorrow for free
bond is offline   Reply With Quote
Old 3rd December 2005, 21:16   #152  |  Link
Sharktooth
Mr. Sandman
 
Sharktooth's Avatar
 
Join Date: Sep 2003
Location: Haddonfield, IL
Posts: 11,768
yeah.

EDIT: i checked out the CVS in during a series of updates... i will let you know if there are news.

EDIT2: There are syntax errors during the compilation... the results is undefined references...
For example:
Code:
commands.c: In function `gf_sg_command_apply':
commands.c:432: error: `SVGElement' undeclared (first use in this function)
commands.c:432: error: (Each undeclared identifier is reported only once
commands.c:432: error: for each function it appears in.)
commands.c:432: error: syntax error before ')' token
commands.c:438: error: syntax error before ')' token
commands.c:457: error: syntax error before ')' token
commands.c:465: error: syntax error before ')' token
commands.c:484: warning: implicit declaration of function `svg_attributes_copy'
commands.c:486: warning: implicit declaration of function `svg_attributes_add'
make[2]: *** [commands.o] Error 1

Last edited by Sharktooth; 3rd December 2005 at 21:39.
Sharktooth is offline   Reply With Quote
Old 4th December 2005, 09:12   #153  |  Link
Kurtnoise
Swallowed in the Sea
 
Kurtnoise's Avatar
 
Join Date: Oct 2002
Location: Aix-en-Provence, France
Posts: 5,182
Indeed...nevertheless the static library is built.

http://kurtnoise.free.fr/x264_r381.zip
Kurtnoise is offline   Reply With Quote
Old 4th December 2005, 12:06   #154  |  Link
bond
Registered User
 
Join Date: Nov 2001
Posts: 9,779
Quote:
Originally Posted by Kurtnoise13
Indeed...nevertheless the static library is built.

http://kurtnoise.free.fr/x264_r381.zip
thx kurtnoise

now can anyone reporting problems about this framerate issue check whether its fixed?
__________________
Between the weak and the strong one it is the freedom which oppresses and the law that liberates (Jean Jacques Rousseau)
I know, that I know nothing (Socrates)

MPEG-4 ASP FAQ | AVC/H.264 FAQ | AAC FAQ | MP4 FAQ | MP4Menu stores DVD Menus in MP4 (guide)
Ogg Theora | Ogg Vorbis
use WM9 today and get Micro$oft controlling the A/V market tomorrow for free
bond is offline   Reply With Quote
Old 4th December 2005, 20:15   #155  |  Link
Sirber
retired developer
 
Sirber's Avatar
 
Join Date: Oct 2002
Location: Canada
Posts: 8,978
Code:
C:\Projets\RealAnimeLE\output\bin>xvid_encraw.exe -i test.avs -o test.m4v -type
2
xvid_encraw - raw mpeg4 bitstream encoder written by Christoph Lampert 2002-2003
Avisynth input is based on Avs2YUV by Loren Merritt

test.avs: 640x480, 10000000/417083 fps, 573 frames
converting YUY2 -> YV12

    376 Frames encoded - 65.62%
Isn't it AVISynth giving odd FPS numbers?
__________________
Detritus Software
Sirber is offline   Reply With Quote
Old 5th December 2005, 16:41   #156  |  Link
Sharktooth
Mr. Sandman
 
Sharktooth's Avatar
 
Join Date: Sep 2003
Location: Haddonfield, IL
Posts: 11,768
Ok, my 384/384A builds use the latest gpac.
Sharktooth is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 12:21.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2017, vBulletin Solutions, Inc.