The Haiku/BeOS Tip Server
Tips and tricks for Haiku/BeOS users

Maximize audio and video performance

Contributed by: Scot Hacker
This tip is valid for: Both BeOS and Haiku

If you experience glitchy audio or video recording or playback on your BeOS machine, you can probably get better media performance by launching the Media preferences panel and check the Enable Real-Time Audio and/or Enable Real-Time Video options and clicking “Restart Media Services.”

When either real-time audio or video are enabled, buffers are locked into memory and are guaranteed not to be swapped out to disk. This way audio and video signal will flow smoothly even if the machine is thrashing virtual memory.

If you’re experimenting with digital video capture (via dvg or personalStudio) and find that your high-bandwidth captured video is dropping frames, make sure “Enable Real-Time Video” is checked in the Media Preferences panel. Next, take a look under MediaPlayer’s Settings menu for the option “Preserve Video Timing” and turn this off. Counterintuitive though it may be, disabling this option can greatly improve your framerate.

For digital video, you’ll also want to make sure you’re getting the most possible performance from your hard drive. Go SCSI if you can afford it. If you can’t, get a UDMA-capable drive, and make sure it’s recognized by your motherboard BIOS. You’ll see it reported at boot time if it is. Also, try running /boot/optional/experimental/diagnostics/ideinfo in conjunction with the raw device path of the drive. To get the raw device path, open a Terminal and type df. So, for example:

waxwing:501 home>df
Mount            Type     Total    Free     Flags   Device
---------------- -------- -------- -------- ------- --------------------------
/                rootfs          0        0 ------W
/dev             devfs           0        0 ------W
/pipe            pipefs          0        0 ------W
/boot            bfs       2811375  1151251 QAM-P-W
/tink            bfs      35673088 15616390 QAM-P-W
/wensleydale     bfs      30006144  2805957 QAM-P-W
/ethyl           bfs      40009882  4951067 QAM-P-W

waxwing:502 home>ideinfo /dev/disk/ide/ata/1/master/0/0_0

Look for the Ultra DMA section. It should say this:

Supported modes:  0 1 2
Selected mode:    2

If the selected mode section is blank, you’re not getting UDMA support and you should upgrade your motherboard’s BIOS. For added performance, consider getting an inexpensive Promise FastTrack Ultra66 card. These are supported in BeOS, and will make sure you get every drop of performance from your ATA66 drive.

If you’re not sure whether you’re dropping frames, play 30 or so seconds of video in MediaPlayer, then pull down File | File Info. In the Info panel, click “More” for details on framerate, codec, and other interesting stuff.


Posted in Audio & Video

(comments are closed).