LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-09-2009, 02:12 AM   #1
w1k0
Senior Member
 
Registered: May 2008
Location: Poland
Distribution: Slackware, Mint
Posts: 1,252

Rep: Reputation: 205Reputation: 205Reputation: 205
Mencoder with -ss and -endpos switches problem


Iím trying to encode my DVD recording to AVI file using mencoder but Iím unable.

That command:

Code:
mencoder -oac copy -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=$bitrate:vhq:vqmin=2:vqmax=31 -vf scale -zoom -xy 640 -vf pp=lb -dvd-speed 2 dvd://1 -o video.avi
works perfect.

That command:

Code:
mencoder -oac copy -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=$bitrate:vhq:vqmin=2:vqmax=31 -vf scale -zoom -xy 640 -vf pp=lb -dvd-speed 2 -ss 0:7:12 -endpos 0:43:57 dvd://1 -o video.avi
gives empty video.avi file and catches TERM signal so to kill it I have to use KILL (9) signal.

The only difference between above commands are switches -ss 0:7:12 and -endpos 0:43:57 determining the beginning and the end of the movie.

Both these commands start in the same way.

At the beginning they display such messages:

Code:
MEncoder r29390-4.3.3 (C) 2000-2009 MPlayer Team
Limiting DVD speed to 2700KB/s... successful
libdvdread: Using libdvdcss version 1.2.10 for DVD access
*** Zero check failed in libdvdread4/ifo_read.c:518
    for vmgi_mat->zero_3 = 0x00000000010000000000000000000000000000
There are 4 titles on this DVD.
There are 1 angles in this DVD title.
Then there is a lot of such messages:

Code:
*** libdvdread: CHECK_VALUE failed in libdvdread4/ifo_read.c:1602 ***
*** for c_adt->cell_adr_table[i].start_sector < c_adt->cell_adr_table[i].last_sector ***
Next such messages:

Code:
libdvdread: Attempting to retrieve all CSS keys
libdvdread: This can take a _long_ time, please be patient

libdvdread: Get key for /VIDEO_TS/VIDEO_TS.VOB at 0x00001100
libdvdread: Elapsed time 0
libdvdread: Get key for /VIDEO_TS/VTS_01_1.VOB at 0x00004000
libdvdread: Elapsed time 0
libdvdread: Found 1 VTS's
libdvdread: Elapsed time 0
audio stream: 0 format: ac3 (stereo) language: unknown aid: 128.
number of audio channels on disk: 1.
subtitle ( sid ): 0 language: unknown
number of subtitles on disk: 1
success: format: 2  data: 0x0 - 0xabc86800

*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***


*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***

MPEG-PS file format detected.
VIDEO:  MPEG2  720x576  (aspect 2)  25.000 fps  8000.0 kbps (1000.0 kbyte/s)
[V] filefmt:2  fourcc:0x10000002  size:720x576  fps:25.000  ftime:=0.0400
==========================================================================
Opening audio decoder: [liba52] AC3 decoding with liba52
Using SSE optimized IMDCT transform
Using MMX optimized resampler
AUDIO: 48000 Hz, 2 ch, s16le, 256.0 kbit/16.67% (ratio: 32000->192000)
Selected audio codec: [a52] afm: liba52 (AC3-liba52)
==========================================================================
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1, osd: 1, aspect: 0.000000, round: 1
Opening video filter: [pp=lb]
==========================================================================
Opening video decoder: [mpegpes] MPEG 1/2 Video passthrough
VDec: vo config request - 720 x 576 (preferred colorspace: Mpeg PES)
[PP] Using external postprocessing filter, max q = 6.
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
VDecoder init failed :(
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Unsupported PixelFormat -1
Selected video codec: [ffmpeg2] vfm: ffmpeg (FFmpeg MPEG-2)
==========================================================================
audiocodec: framecopy (format=2000 chans=2 rate=48000 bits=16 B/s=32000 sample-1)

*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***
At this point there is the first difference between the output of these commands.

The first command displays such messages:

Code:
VDec: vo config request - 720 x 576 (preferred colorspace: Planar YV12)
[PP] Using external postprocessing filter, max q = 6.
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
videocodec: libavcodec (720x576 fourcc=34504d46 [FMP4])
[VE_LAVC] High quality encoding selected (non-realtime)!
[mpeg2video @ 0x8e3b820]ac-tex damaged at 15 1
[mpeg2video @ 0x8e3b820]Warning MVs not available
[mpeg2video @ 0x8e3b820]concealing 1575 DC, 1575 AC, 1575 MV errors
Writing header...1f ( 0%)  0.00fps Trem:   0min   0mb  A-V:0.000 [0:0]
ODML: Aspect information not (yet?) available or unspecified, not writing vprp header.
Writing header...
ODML: Aspect information not (yet?) available or unspecified, not writing vprp header.
and then starts to encode the movie:

Code:
Pos:   0.0s      2f ( 0%)  0.00fps Trem:   0min   0mb  A-V:-0.003 [0:0]
*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***

Pos:   0.5s     14f ( 0%)  0.00fps Trem:   0min   0mb  A-V:0.045 [0:0]
*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***

Pos:   1.0s     26f ( 0%) 25.67fps Trem:   0min   0mb  A-V:0.081 [0:256]
Skipping frame!
Pos:   1.0s     28f ( 0%) 27.29fps Trem:   0min   0mb  A-V:0.044 [1671:256]
*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***

The second command displays infinitely such messages:

Code:
*** libdvdread: CHECK_VALUE failed in libdvdread4/nav_read.c:264 ***
*** for dsi->dsi_gi.zero1 == 0 ***
and doesnít start to encode the movie.

What can I do to be able to encode selected fragments of recorded programs? Every help will be welcomed.
 
Old 12-09-2009, 02:30 AM   #2
__PJ
LQ Newbie
 
Registered: Dec 2009
Posts: 10

Rep: Reputation: 0
Is the blank AVI of the correct length?

It shouldn't make any difference, but try specifying the time in seconds. IE: -ss 432 -endpos 2637
 
Old 12-09-2009, 11:34 AM   #3
w1k0
Senior Member
 
Registered: May 2008
Location: Poland
Distribution: Slackware, Mint
Posts: 1,252

Original Poster
Rep: Reputation: 205Reputation: 205Reputation: 205
In my case menconder used with -ss and -endpos switches gives zero size file not blank one. Above I referred to it using less precise term ``empty file'' and I caused misunderstanding.

I tested it once again and I stated the error is caused by -ss switch. I can determine the end of the sample with -endpos but I can't determine the beginning with -ss.

Using seconds instead of hours:minutes:seconds gives the same result.
 
Old 12-09-2009, 12:56 PM   #4
w1k0
Senior Member
 
Registered: May 2008
Location: Poland
Distribution: Slackware, Mint
Posts: 1,252

Original Poster
Rep: Reputation: 205Reputation: 205Reputation: 205
It seems mencoder is unable to use -ss option when ripping DVD but is able to use it during encoding AVI file. So after ripping I can use such command to cut AVI file:

Code:
mencoder -ovc copy -oac copy -ss 0:7:12 -endpos 0:43:57 -o video-short.avi video.avi
Both -ss and -endpos switches aren't accurate so to determine the optimal values of these options I have to use a process of trials and errors.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Ethernet problem with some cards and 3Com switches (3C16471) matiasar Linux - Networking 7 11-24-2009 04:00 PM
Problem with mencoder me4linux Linux - Software 6 08-29-2007 01:56 PM
mencoder problem masand Linux - Software 1 10-29-2005 03:39 PM
X.org problem: switches back to cli. Please help. neocookie Linux - Software 2 07-05-2004 11:46 AM
8-port Switches problem hiteshmaisheri Linux - Networking 3 03-13-2004 12:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration