mirror of
https://github.com/mpv-player/mpv
synced 2024-12-17 20:34:58 +00:00
afe36fd0a5
For the moment up to 16 cards are supported. More can be added easily by changing 2 defines. This makes 90% of the patch (mostly stupid s/$var/card->$var/) The different devices can be accessed by different minor numbers (0-15): mknod /dev/mga_vid0 c 178 0 mknod /dev/mga_vid1 c 178 1 mknod /dev/mga_vid2 c 178 2 mknod /dev/mga_vid3 c 178 3 ... ln -s mga_vid /dev/mga_vid * Change the devfs code to let the kernel assign us a major and a minor number (what is the sense behind using devfs anyways if we dont do that ?) Subdevices for the different cards are created. mga_vid uses the first card (for compatibility) * Fix a possible error when mmap() is called before the card is configured by a ioctl(). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@10744 b3059339-0415-0410-9bf9-f77b7e298cf2 |
||
---|---|---|
.. | ||
radeon | ||
.cvsignore | ||
3dfx.h | ||
Makefile | ||
mga_vid_test.c | ||
mga_vid.c | ||
mga_vid.h | ||
README | ||
tdfx_vid_tst.c | ||
tdfx_vid.c | ||
tdfx_vid.h |
mga_vid - MGA G200/G400 YUV Overlay kernel module Author: Aaron Holtzman <aholtzma@ess.engr.uvic.ca>, Oct 1999 Contributions by: Fredrik Vraalsen <vraalsen@cs.uiuc.edu> Alan Cox <alan@lxorguk.ukuu.org.uk> WARNING ----- WARNING This code messes with your video card and your xserver. It will probably lock up your box, format your hard drive, and cause your brand new g400 MAX to spout 6 inch flames. You have been warned. WARNING ----- WARNING What does this code do? mga_vid is a kernel module that utilitizes the Matrox g200/g400 video scaler/overlay unit to perform YUV->RGB colorspace conversion and arbitrary video scaling. mga_vid is also a monster hack. How does mga_vid work? This kernel module sets up the BES (backend scaler) with approriate values based on parameters supplied via ioctl. It also maps a chunk of video memory into userspace via mmap. This memory is stolen from X (which may decide to write to it later). The application can then write image data directly to the frame buffer (if it knows the right padding, etc). How do I know if mga_vid works on my system? There are test applications called mga_vid_test_g400 and mga_vid_test_g200. Use the appropriate one for your card. This test code should draw some nice 256x256 images for you if all is working well.