[mythtv-users] Slow HD playback (unusable)
Rob
myth at eklhq.com
Sat Apr 28 18:08:41 UTC 2007
I have been trying to get HD working with Myth this week. The video is
recorded okay: I can view it with no problems through mythfrontend on my
desktop machine (2GHz Sempron64, GF6800, PC3200 memory = ~1400MB/s,
resolution 1280x1024).
On my Myth machine connected to my TV, the video is slow and audio is
choppy for HD recordings. SD recordings are fine. I'm been through the
wiki many times, and have tried just about every setting and
configuration I can think of. The machine has a SD MPEG2 encoder card
and an HD encoder card, SB Live, and an NVidia MX4000 AGP card. It is
running mythbackend and mythfrontend. mysql is on a different machine
in my network.
CPU is more than 40% idle during HD playback. XvMC is enabled. What is
causing HD video to be slow and audio to be choppy on this machine?
("Video is 3.28844 frames behind audio (too slow), skipping A/V wait")
What can I do to get it usable?
The only things I can come up that could be the problem aren't very
configurable: MX4000 is too slow; interrupt shared by video card and
other devices; or PCI bus saturated by video card, capture cards, and
hard disk. Are any of these things the problem?
CPU: AMD Athlon XP Barton, socketA, 2.0GHz
Motherboard: nVidia NForce2, 200MHz FSB
Memory: 1GB PC3200, dual-channel, ~1400MB/s
Video: GeForce4 MX 4000 AGP, 64MB, VGA output
Video driver: 1.0.8776
Display: HDTV, 1360x768, VGA input
Kernel: gentoo-sources-2.6.20-r6
Compiler: gcc (GCC) 3.4.6 (Gentoo 3.4.6-r2, ssp-3.4.6-1.0, pie-8.7.10)
during playback: vmstat 2
procs -----------memory---------- ---swap-- -----io---- --system--
----cpu----
r b swpd free buff cache si so bi bo in cs us sy
id wa
0 0 624 8876 4804 576456 0 0 519 1179 568 1235 18 3
76 2
2 0 624 9256 4780 575920 0 0 1026 1204 1582 3162 50 4
45 2
2 0 624 8676 4764 576640 0 0 1024 1418 1581 3172 49 5
45 1
10 0 624 9004 4736 576204 0 0 1026 1394 1590 3111 47 6
46 2
5 0 624 8672 4716 576776 0 0 1024 1274 1613 3125 50 5
45 1
lspci -v
02:00.0 VGA compatible controller: nVidia Corporation NV18 [GeForce4 MX
4000] (rev c1) (prog-if 00 [VGA])
Flags: bus master, 66MHz, medium devsel, latency 248, IRQ 17
Memory at ec000000 (32-bit, non-prefetchable) [size=16M]
Memory at e8000000 (32-bit, prefetchable) [size=64M]
[virtual] Expansion ROM at ed000000 [disabled] [size=128K]
Capabilities: [60] Power Management version 2
Capabilities: [44] AGP version 3.0
01:0a.0 Multimedia audio controller: Creative Labs SB Live! EMU10k1 (rev
07)
Subsystem: Creative Labs SBLive! 5.1 Model SB0100
Flags: bus master, medium devsel, latency 64, IRQ 18
I/O ports at d000 [size=32]
Capabilities: [dc] Power Management version 1
00:1e.0 PCI bridge: nVidia Corporation nForce2 AGP (rev c1) (prog-if 00
[Normal decode])
Flags: bus master, 66MHz, medium devsel, latency 64
Bus: primary=00, secondary=02, subordinate=02, sec-latency=32
Memory behind bridge: ec000000-edffffff
Prefetchable memory behind bridge: e8000000-ebffffff
00:09.0 IDE interface: nVidia Corporation nForce2 IDE (rev a2) (prog-if
8a [Master SecP PriP])
Subsystem: Albatron Corp. Unknown device 3401
Flags: bus master, 66MHz, fast devsel, latency 0
[virtual] Memory at 000001f0 (32-bit, non-prefetchable)
[disabled] [size=8]
[virtual] Memory at 000003f0 (type 3, non-prefetchable)
[disabled] [size=1]
[virtual] Memory at 00000170 (32-bit, non-prefetchable)
[disabled] [size=8]
[virtual] Memory at 00000370 (type 3, non-prefetchable)
[disabled] [size=1]
I/O ports at f000 [size=16]
Capabilities: [44] Power Management version 2
hdparm /dev/hda
/dev/hda:
multcount = 16 (on)
IO_support = 1 (32-bit)
unmaskirq = 1 (on)
using_dma = 1 (on)
keepsettings = 0 (off)
readonly = 0 (off)
readahead = 256 (on)
geometry = 36481/255/63, sectors = 586072368, start = 0
hdparm /dev/hdc
/dev/hdc:
multcount = 16 (on)
IO_support = 1 (32-bit)
unmaskirq = 1 (on)
using_dma = 1 (on)
keepsettings = 0 (off)
readonly = 0 (off)
readahead = 256 (on)
geometry = 30401/255/63, sectors = 488397168, start = 0
cat /proc/interrupts
CPU0
0: 420701 IO-APIC-edge timer
1: 629 IO-APIC-edge i8042
4: 0 IO-APIC-edge serial
8: 133698 IO-APIC-edge rtc
9: 1 IO-APIC-fasteoi acpi
14: 5426 IO-APIC-edge ide0
15: 11889 IO-APIC-edge ide1
16: 160776 IO-APIC-fasteoi eth0
17: 167854 IO-APIC-fasteoi saa7133[0], ivtv0, nvidia
18: 1119 IO-APIC-fasteoi EMU10K1
NMI: 0
LOC: 420656
ERR: 0
MIS: 0
cat /proc/driver/nvidia/agp/status
Status: Enabled
Driver: NVIDIA
AGP Rate: 8x
Fast Writes: Enabled
SBA: Enabled
mythfrontend -v playback
...
2007-04-28 10:28:21.621 AFD: Stream #0, has id 0x1984 codec id
MPEG2VIDEO, type Video, bitrate 38810400 at 0x0xa95be80
2007-04-28 10:28:21.623 VideoOutputXv: XvMC version: 1.1
2007-04-28 10:28:21.623 XvMCSurfaceTypes::find(w 1920, h 1080, chroma 1,
vld 0, idct 1, mpeg2, sub-width 0, sub-height 0, disp, p<= 126, 1260
<=p, port, surfNum)
2007-04-28 10:28:21.623 Trying XvMC port 126
2007-04-28 10:28:21.623 Found a suitable XvMC surface 0
2007-04-28 10:28:21.623 VideoOutputXv: @ j=1 Looking for flag[s]:
XvInputMask
2007-04-28 10:28:21.623 VideoOutputXv: Adaptor#0: NV17 Video Overlay has
flag[s]: XvInputMask XvImageMask
2007-04-28 10:28:21.623 XvMCSurfaceTypes::find(w 1920, h 1080, chroma 1,
vld 0, idct 1, mpeg2, sub-width 0, sub-height 0, disp, p<= 126, 1260
<=p, port, surfNum)
2007-04-28 10:28:21.623 Trying XvMC port 126
2007-04-28 10:28:21.623 Found a suitable XvMC surface 0
2007-04-28 10:28:21.624 VideoOutputXv: Grabbed xv port 126
2007-04-28 10:28:21.624 VideoOutputXv: XvMC surface found with IDCT
support on port 126
2007-04-28 10:28:21.631 VideoOutputXv: Closing XVideo port 126
2007-04-28 10:28:21.632 detectInterlace(Detect Scan, Interlaced Scan,
29.97, 1088) ->Interlaced Scan
2007-04-28 10:28:21.632 AFD: Looking for decoder for MPEG2VIDEO_XVMC
2007-04-28 10:28:21.632 AFD: Opened codec 0xa9c0cb0, id(MPEG2VIDEO_XVMC)
type(Video)
2007-04-28 10:28:21.632 AFD: Stream #1, has id 0x1985 codec id AC3, type
Audio, bitrate 384000 at 0x0 xa9a9c00
2007-04-28 10:28:21.632 AFD: Looking for decoder for AC3
2007-04-28 10:28:21.633 AFD: Opened codec 0x8563c80, id(AC3) type(Audio)
2007-04-28 10:28:21.637 Opening ALSA audio device 'iec958:{ AES0 0x02 }'.
2007-04-28 10:28:21.739 AFD: Position map found
2007-04-28 10:28:21.739 AFD: Successfully opened decoder for file:
"/mnt/store//1052_20070428030500.mpg". novideo(0)
2007-04-28 10:28:21.751 VideoOutputXv: ctor
2007-04-28 10:28:21.751 Over/underscan. V: 0, H: 0, XOff: 0, YOff: 0
2007-04-28 10:28:21.752 Display Rect left: 0, top: 96, width: 1360,
height: 576, aspect: 1.33333
2007-04-28 10:28:21.752 Video Rect left: 0, top: 0, width: 1920,
height: 1080, aspect: 1.77778
2007-04-28 10:28:21.752 VideoOutputXv: Pixel dimensions: Screen
1360x768, window 1360x768
2007-04-28 10:28:21.752 VideoOutputXv: Estimated display dimensions:
345x195 mm Aspect: 1.76923
2007-04-28 10:28:21.752 VideoOutputXv: Estimated window dimensions:
345x195 mm Aspect: 1.76923
2007-04-28 10:28:21.752 VideoOutputXv: XvMC version: 1.1
2007-04-28 10:28:21.753 VideoOutputXv: XvMCTex: Init failed
2007-04-28 10:28:21.753 VideoOutputXv: @ j=1 Looking for flag[s]:
XvInputMask
2007-04-28 10:28:21.753 VideoOutputXv: Adaptor#0: NV17 Video Overlay has
flag[s]: XvInputMask XvImageMask
2007-04-28 10:28:21.753 XvMCSurfaceTypes::find(w 1920, h 1088, chroma 1,
vld 0, idct 1, mpeg2, sub-width 0, sub-height 0, disp, p<= 126, 1260
<=p, port, surfNum)
2007-04-28 10:28:21.753 Trying XvMC port 126
2007-04-28 10:28:21.753 Found a suitable XvMC surface 0
2007-04-28 10:28:21.753 VideoOutputXv: Grabbed xv port 126
2007-04-28 10:28:21.753 VideoOutputXv: XvMC surface found with IDCT
support on port 126
2007-04-28 10:28:21.753 VideoOutputXv: XvMC Adaptor Name: 'NV17 Video
Overlay'
2007-04-28 10:28:21.760 Display Rect left: 0, top: 0, width: 1360,
height: 768, aspect: 1.77778
2007-04-28 10:28:21.760 Video Rect left: 0, top: 0, width: 1920,
height: 1080, aspect: 1.77778
2007-04-28 10:28:22.223 nVidiaVideoSync: VBlank ioctl did not work,
unimplemented in this driver?
2007-04-28 10:28:22.224 DRMVideoSync: Could not open device
/dev/dri/card0, No such file or directory
2007-04-28 10:28:22.224 Using audio as timebase
2007-04-28 10:28:22.224 Video timing method: RTC
2007-04-28 10:28:22.224 Refresh rate: 16662, frame interval: 33366
2007-04-28 10:28:22.603 WriteAudio: buffer underrun
2007-04-28 10:28:22.631 NVP: Video is 3.28844 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:22.694 NVP: Video is 3.95735 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:22.757 NVP: Video is 4.48151 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:22.821 NVP: Video is 4.83717 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:22.877 NVP: Video is 4.30969 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:22.941 NVP: Video is 4.07891 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:23.004 NVP: Video is 4.12312 frames behind audio (too
slow), skipping A/V wait.
2007-04-28 10:28:23.043 WriteAudio: buffer underrun
More information about the mythtv-users
mailing list