Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

video1394.h

Go to the documentation of this file.
00001 /*
00002  * video1394.h - driver for OHCI 1394 boards
00003  * Copyright (C)1999,2000 Sebastien Rougeaux <sebastien.rougeaux@anu.edu.au>
00004  *                        Peter Schlaile <udbz@rz.uni-karlsruhe.de>
00005  *
00006  * This program is free software; you can redistribute it and/or modify
00007  * it under the terms of the GNU General Public License as published by
00008  * the Free Software Foundation; either version 2 of the License, or
00009  * (at your option) any later version.
00010  *
00011  * This program is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  * GNU General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License
00017  * along with this program; if not, write to the Free Software Foundation,
00018  * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00019  */
00020 
00021 #ifndef _VIDEO_1394_H
00022 #define _VIDEO_1394_H
00023 
00024 #define VIDEO1394_DRIVER_NAME "video1394"
00025 
00026 #define VIDEO1394_MAX_SIZE 0x4000000
00027 
00028 enum {
00029         VIDEO1394_BUFFER_FREE = 0,
00030         VIDEO1394_BUFFER_QUEUED,
00031         VIDEO1394_BUFFER_READY
00032 };
00033 
00034 enum {
00035         VIDEO1394_LISTEN_CHANNEL = 0,
00036         VIDEO1394_UNLISTEN_CHANNEL,
00037         VIDEO1394_LISTEN_QUEUE_BUFFER,
00038         VIDEO1394_LISTEN_WAIT_BUFFER,  // wait until buffer is ready
00039         VIDEO1394_TALK_CHANNEL,
00040         VIDEO1394_UNTALK_CHANNEL,
00041         VIDEO1394_TALK_QUEUE_BUFFER,
00042         VIDEO1394_TALK_WAIT_BUFFER,
00043         VIDEO1394_LISTEN_POLL_BUFFER   // return immediately with -EINTR if not ready
00044 };
00045 
00046 #define VIDEO1394_SYNC_FRAMES          0x00000001
00047 #define VIDEO1394_INCLUDE_ISO_HEADERS  0x00000002
00048 #define VIDEO1394_VARIABLE_PACKET_SIZE 0x00000004
00049 
00050 struct video1394_mmap {
00051         int channel;                    /* -1 to find an open channel in LISTEN/TALK */
00052         unsigned int sync_tag;
00053         unsigned int nb_buffers;
00054         unsigned int buf_size;
00055         unsigned int packet_size; /* For VARIABLE_PACKET_SIZE: 
00056                                      Maximum packet size */
00057         unsigned int fps;
00058         unsigned int syt_offset;
00059         unsigned int flags;
00060 };
00061 
00062 /* For TALK_QUEUE_BUFFER with VIDEO1394_VARIABLE_PACKET_SIZE use */
00063 struct video1394_queue_variable {
00064         unsigned int channel;
00065         unsigned int buffer;
00066         unsigned int* packet_sizes; /* Buffer of size:  
00067                                        buf_size / packet_size  */
00068 };
00069 
00070 struct video1394_wait {
00071         unsigned int channel;
00072         unsigned int buffer;
00073         struct timeval filltime;        /* time of buffer full */
00074 };
00075 
00076 
00077 #endif

Generated on Sun Jan 8 13:39:02 2006 for Cinelerra-svn by  doxygen 1.4.4