Opened 20 years ago
Closed 20 years ago
#1822 closed defect (fixed)
XvMC: Initial DVD menu not shown
| Reported by: | skamithi | Owned by: | skamithi |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.21 |
| Component: | mythtv | Version: | head |
| Severity: | medium | Keywords: | |
| Cc: | Ticket locked: | no |
Description
initial still frame containing language menu may be not displayed using the standard decoder. works with libmpeg2. problem is that dvd sends the still frame, then issues a dvd_stop. in the case presented, the initial video width was 640, but wants to change it to 720. during this process, the dvd resolution detection code in AFD drops the frame.. NVP quits because it is still in the process of starting..when this problem occurred.
working with the user who encountered this problem. doesn't affect me i haven't found a ntsc dvd with a language menu yet.. i think its only done in certain regions.
libmpeg2 has built-in resolution detection so it just works.
Attachments (10)
Change History (32)
by , 20 years ago
| Attachment: | lang_menu_v1.patch added |
|---|
comment:1 by , 20 years ago
comment:2 by , 20 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
comment:3 by , 20 years ago
| Component: | mythtv → mythdvd |
|---|---|
| Resolution: | fixed |
| Status: | closed → reopened |
| Version: | → head |
Still fails under XvMC - both nvidia and Via VLD. r10012
Logs (LARGE!) can be found at http://gilks.ath.cx/~g8ecj/Stanley/ as can an ISO image of a DVD that causes the problem. The logs are for Standard (ffmpeg), libmpeg2 and XvMC (nvidia). The extra debug lines in the trace are from the patch Stanley asked me to apply (also available for download).
In addition to the initial menu not displaying correctly, for ffmpeg and libmpeg2 the videos I've replaced with a still image cause the player to lock up completely.
Please only download the ISO image if you REALLY need it - I pay per gig here!!
comment:4 by , 20 years ago
| Component: | mythdvd → mythtv |
|---|
comment:5 by , 20 years ago
| Owner: | changed from to |
|---|---|
| Status: | reopened → new |
Daniel, issue with XvMC remaining with DVD menus & still frames. Stanley's not that familiar with XvMC..
comment:7 by , 20 years ago
| Summary: | initial dvd language menu may not be displayed using standard decoder . dvd playback just quits. → XvMC: Initial DVD menu not shown |
|---|
comment:8 by , 20 years ago
(In [10105]) Refs #1822. Fixes some auxiliary problems around the still frame in XvMC problem.
The reorders the fallback decoders so that XVideo follows XvMC, instead of Xlib. This overrides the resolution for GetBestSupportedCodec() so it is at least 16x16 pixels. This also adds some debugging for UpdatePauseFrame().
comment:9 by , 20 years ago
I'm punting this for now.
It appears the problem is that XvMC pause consumes frames, so we try to get the displayed frame rather than the used frame, so we end up with the still frame previous to the one we really want. If we try to get a used frame instead, then we consume it show it will just flash on screen and then go away.
If I'm right about the problem, there are four ways to go about fixing this:
- Change the avlib decoding so that it redecodes the still frame as if it were a video.
- Implement a pause frame implementation for XvMC which copies the frame. This might be doable by with BLEND_SUBPICTURE compositing, by compositing the frame with a blank OSD, with BACKEND_SUBPICURE I don't know how you would do it.
- Use another decoder to decode still frames, and use the XvImage supported by all XvMC implementations I know of; or simply use X11 paint calls and block XvMC display. This will problably require some additional hacking to get OSD to work.
- Implement some special UpdatePauseFrame for still frames which avoids consuming frames by some kind of VideoBuffers frame accounting trickery.
None of these are very simple. If #2 is possible it is probably the best solution.
There is another possible hack, which is to just disable XvMC for DVDs. If no one else is interested in fixing this, I can apply that hack as the fix...
comment:10 by , 20 years ago
I've not got enough mips in my frontend to play DVDs with anything other than XvMC (Via Epia). I think option 3 (if I understand what you're saying) so that you just turn off XvMC for the menus (a quick flicker as modes change when the main feature is selected works for me) - i.e. switch to Xv during (still) menus only.
comment:11 by , 20 years ago
| Milestone: | 0.20 → 0.21 |
|---|
comment:12 by , 20 years ago
| Owner: | changed from to |
|---|
attaching patch which switches between Xv and XVMC depending on which whether you are in the dvd menu or not.
need testers, as my time on a XVMC capable PC is very limited. Patch is a debug patch with lots of debug messages. If it crashes, or has issues, pls send me the -v playback and backtrace.
by , 20 years ago
| Attachment: | xvmc_dvd_menus_attempt1.diff added |
|---|
attempt to resolve internal dvd player issues with XVmc. use XV when in dvd menu..turn XVMC back on when watching the main title.
by , 20 years ago
| Attachment: | xvmc_dvd_menu_attempt2.diff added |
|---|
thx to robin for testing. another variable in mpeg12 needed to be reinitialized when switching back to XV from Via XVMC.
comment:13 by , 20 years ago
| Status: | new → assigned |
|---|
patch will be cleaned up and committed once robin confirms it works for him.
by , 20 years ago
| Attachment: | xvmc_dvd_menu_attempt3.diff added |
|---|
attempt 3. basically attempt 2 patch, cleaned up... with some changes to dvdringbufferpriv. added seekLock mutex so only on thread can access the seek function at any time. It actually fixed the problem I noted with mergedFB in #2215. It may actually fix the original problem reported in #2215..who knows :)
comment:14 by , 20 years ago
comment:15 by , 20 years ago
robin confirms [11607] doesn't cause a problem and resolves his issue. leaving case open for a couple of weeks to fix any bugs I missed.
comment:16 by , 20 years ago
I tried the xvmc_dvd_menu_attempt2.diff patch against .20-fixes with Roman Holiday and the menus now render correctly. However, if I try to play anything I get an immediate crash. Logs attached for the main and making of titles.
by , 20 years ago
| Attachment: | roman-holiday-main-feature.log.gz added |
|---|
by , 20 years ago
| Attachment: | roman-holiday-making-of.log.gz added |
|---|
by , 20 years ago
| Attachment: | roman-holiday-backtrace.txt.gz added |
|---|
release_avf_buffer_xvmc, hmmm....
comment:19 by , 20 years ago
invalid backtrace. recompile myth with the debug option. also suggest u upgrade to svn and test since the crash appears to be in ffmpeg. there have been ffmpeg updates and a couple of other changes since 0.20 came out.
by , 20 years ago
| Attachment: | roman-holiday-unstripped-backtrace.txt.gz added |
|---|
comment:20 by , 20 years ago
i don't run 0.20 fixes.. so i would suggest that you upgrade to svn to test. i will not port this change to 0.20 fixes because it doesn't work for you.
comment:21 by , 20 years ago
by , 20 years ago
| Attachment: | fix_for_latest_problem.diff added |
|---|
robin reported that initcodec is called too many times on a certain dvd causing blue screen. attaching small rewrite to the patch to prevent this.
by , 20 years ago
| Attachment: | fix_for_latest_problem.2.diff added |
|---|
fix for latest problem doesn't work. made small correction. tested correction.. works for me.
comment:22 by , 20 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |

patch works with Xv. Robin Gilks provided me with an iso of a dvd menu and it had a language menu. Patch doesn't completely resolve his issue. From the debugs he provided, looks like XvMC VideoOutputXv::UpdatePauseFrame drops the frame. It reports the following, then discards the still frame.
i don't use XvMC so can't solve his problem.