Update of /cvsroot/artoolkit/artoolkit/lib/SRC/VideoLinux1394Cam
In directory sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv8979
Modified Files:
video.c
Log Message:
Make default behaviour consistent across Linux video libs.
Index: video.c
===================================================================
RCS file: /cvsroot/artoolkit/artoolkit/lib/SRC/VideoLinux1394Cam/video.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** video.c 15 Sep 2006 04:44:21 -0000 1.12
--- video.c 18 Sep 2006 23:31:01 -0000 1.13
***************
*** 282,286 ****
}
! AR2VideoParamT *ar2VideoOpen( char *config )
{
char video1394devname [128];
--- 282,286 ----
}
! AR2VideoParamT *ar2VideoOpen( char *config_in )
{
char video1394devname [128];
***************
*** 288,292 ****
ARUint32 p1,p2;
quadlet_t value;
! char *a, line[256];
int i;
--- 288,292 ----
ARUint32 p1,p2;
quadlet_t value;
! char *config *a, line[256];
int i;
***************
*** 311,333 ****
vid->status = 0;
! /* If no config string is supplied, we should use the environment variable otherwise set a sane default */
! if (!strcmp (config, ""))
! {
! /* None suppplied, lets see if the user supplied one from the shell */
! char *envconf = getenv ("ARTOOLKIT_CONFIG");
! if ((envconf != NULL) && (strcmp (envconf, "")))
! {
! config = envconf;
! printf ("Using config string from environment [%s]\n", config);
! }
! else
! {
! printf ("No config string supplied, assuming 640x480 with YUV411 encoding\n");
! }
! }
! else
! printf ("Using supplied config string [%s]\n", config);
!
! a = config;
if( a != NULL) {
for(;;) {
--- 311,331 ----
vid->status = 0;
! /* If no config string is supplied, we should use the environment variable, otherwise set a sane default */
! if (!config_in || !(config_in[0])) {
! /* None suppplied, lets see if the user supplied one from the shell */
! char *envconf = getenv ("ARTOOLKIT_CONFIG");
! if (envconf) {
! config = envconf;
! printf ("Using config string from environment [%s].\n", envconf);
! } else {
! config = NULL;
! printf ("No video config string supplied, using defaults.\n");
! }
! } else {
! config = config_in;
! printf ("Using supplied video config string [%s].\n", config_in);
! }
!
! a = config;
if( a != NULL) {
for(;;) {
|