From owner-freebsd-multimedia@FreeBSD.ORG Wed Oct 10 08:13:56 2007 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ED29816A41A for ; Wed, 10 Oct 2007 08:13:55 +0000 (UTC) (envelope-from heikorecktenwald@gmail.com) Received: from smtp2.netcologne.de (smtp2.netcologne.de [194.8.194.112]) by mx1.freebsd.org (Postfix) with ESMTP id 82F6B13C459 for ; Wed, 10 Oct 2007 08:13:55 +0000 (UTC) (envelope-from heikorecktenwald@gmail.com) Received: from max.bla (xdsl-81-173-169-8.netcologne.de [81.173.169.8]) by smtp2.netcologne.de (Postfix) with ESMTP id AD2C84444; Wed, 10 Oct 2007 09:46:05 +0200 (MEST) Message-ID: <470C82DC.3000807@gmail.com> Date: Wed, 10 Oct 2007 09:44:28 +0200 From: Heiko Recktenwald User-Agent: Thunderbird 2.0.0.6 (X11/20070924) MIME-Version: 1.0 To: freebsd-multimedia@freebsd.org Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: multimedia/gtk-setpwc? X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Oct 2007 08:13:56 -0000 Hi, >> Tried to compile setpwc, dont know which changes to make to which files >> and where, allthough it looked like a good starter to learn C. Something >> was missing, with gmake and make. >> > Please post the error messages. Perhaps someone can help you out. > http://www.vanheusden.com/setpwc/setpwc-1max$ tar -xzvpf set* x setpwc-1.2/ x setpwc-1.2/setpwc.c x setpwc-1.2/pwc-ioctl.h x setpwc-1.2/setpwc.1 x setpwc-1.2/readme.txt x setpwc-1.2/Makefile x setpwc-1.2/license.tx.2.tgz max$ gmake cc -Wall -O2 -DVERSION=\"1.2\" -c -o setpwc.o setpwc.c setpwc.c:26:28: linux/videodev.h: No such file or directory setpwc.c: In function `dump_current_settings': setpwc.c:66: error: storage size of 'vcap' isn't known setpwc.c:67: error: storage size of 'vwin' isn't known setpwc.c:68: error: storage size of 'vpic' isn't known setpwc.c:78: error: `VIDIOCGCAP' undeclared (first use in this function) setpwc.c:78: error: (Each undeclared identifier is reported only once setpwc.c:78: error: for each function it appears in.) setpwc.c:94: error: `VIDIOCGWIN' undeclared (first use in this function) setpwc.c:102: error: `VIDIOCGPICT' undeclared (first use in this function) setpwc.c:111: error: `VIDEO_PALETTE_GREY' undeclared (first use in this function) setpwc.c:114: error: `VIDEO_PALETTE_HI240' undeclared (first use in this function) setpwc.c:117: error: `VIDEO_PALETTE_RGB565' undeclared (first use in this function) setpwc.c:120: error: `VIDEO_PALETTE_RGB555' undeclared (first use in this function) setpwc.c:123: error: `VIDEO_PALETTE_RGB24' undeclared (first use in this function) setpwc.c:126: error: `VIDEO_PALETTE_RGB32' undeclared (first use in this function) setpwc.c:129: error: `VIDEO_PALETTE_YUV422' undeclared (first use in this function) setpwc.c:132: error: `VIDEO_PALETTE_YUYV' undeclared (first use in this function) setpwc.c:135: error: `VIDEO_PALETTE_UYVY' undeclared (first use in this function) setpwc.c:138: error: `VIDEO_PALETTE_YUV420' undeclared (first use in this function) setpwc.c:141: error: `VIDEO_PALETTE_YUV411' undeclared (first use in this function) setpwc.c:144: error: `VIDEO_PALETTE_RAW' undeclared (first use in this function) setpwc.c:147: error: `VIDEO_PALETTE_YUV422P' undeclared (first use in this function) setpwc.c:150: error: `VIDEO_PALETTE_YUV411P' undeclared (first use in this function) setpwc.c:138: error: `VIDEO_PALETTE_YUV420' undeclared (first use in this function) setpwc.c:141: error: `VIDEO_PALETTE_YUV411' undeclared (first use in this function) setpwc.c:144: error: `VIDEO_PALETTE_RAW' undeclared (first use in this function) setpwc.c:147: error: `VIDEO_PALETTE_YUV422P' undeclared (first use in this function) setpwc.c:150: error: `VIDEO_PALETTE_YUV411P' undeclared (first use in this function) setpwc.c:153: error: `VIDEO_PALETTE_YUV420P' undeclared (first use in this function) setpwc.c:156: error: `VIDEO_PALETTE_YUV410P' undeclared (first use in this function) setpwc.c:66: warning: unused variable `vcap' setpwc.c:67: warning: unused variable `vwin' setpwc.c:68: warning: unused variable `vpic' setpwc.c: In function `set_dimensions_and_framerate': setpwc.c:288: error: storage size of 'vwin' isn't known setpwc.c:291: error: `VIDIOCGWIN' undeclared (first use in this function) setpwc.c:306: error: `VIDIOCSWIN' undeclared (first use in this function) setpwc.c:288: warning: unused variable `vwin' gmake: *** [setpwc.o] Error 1 max$ >From the Makefile: VERSION=1.2 CFLAGS+=-Wall -O2 -DVERSION=\"$(VERSION)\" LDFLAGS= OBJS=setpwc.o all: setpwc setpwc: $(OBJS) $(CC) -Wall -W $(OBJS) $(LDFLAGS) -o setpwc # >From setpwc.c: #include #include #include #include #include #include #include #include #include #define _LINUX_TIME_H 1 /* to get things compile on kernel 2.6.x */ #include #include "pwc-ioctl.h" char *device = "/dev/video0"; #define SET_PAN 0 #define SET_TILT 1 void error_exit(char *what_ioctl) { fprintf(stderr, "Error while doing ioctl %s: %s\n", what_ioctl, strerror /* commented out: some versions of the driver seem to return * unexpected errors */ /* exit(1); */ } etc. Thanks, H.