53 lines
1.8 KiB
Diff
53 lines
1.8 KiB
Diff
diff -aur pygame/Setup.in pygame-build/Setup.in
|
|
--- pygame/Setup.in 2011-04-13 17:43:50.987447096 +0200
|
|
+++ pygame-build/Setup.in 2011-04-13 17:50:03.554502812 +0200
|
|
@@ -1,2 +1,2 @@
|
|
#This file defines platform specific modules for linux
|
|
-_camera src/_camera.c src/camera_v4l2.c src/camera_v4l.c $(SDL) $(DEBUG)
|
|
+_camera src/_camera.c src/camera_v4l2.c $(SDL) $(DEBUG)
|
|
diff -aur pygame/src/_camera.c pygame-build/src/_camera.c
|
|
--- pygame/src/_camera.c 2011-04-13 17:43:41.877679441 +0200
|
|
+++ pygame-build/src/_camera.c 2011-04-13 17:50:46.240063533 +0200
|
|
@@ -165,20 +165,8 @@
|
|
PyObject* camera_start (PyCameraObject* self) {
|
|
#if defined(__unix__)
|
|
if (v4l2_open_device(self) == 0) {
|
|
- if (v4l_open_device(self) == 0) {
|
|
- v4l2_close_device(self);
|
|
- return NULL;
|
|
- } else {
|
|
- self->camera_type = CAM_V4L;
|
|
- if (v4l_init_device(self) == 0) {
|
|
- v4l2_close_device(self);
|
|
- return NULL;
|
|
- }
|
|
- if (v4l_start_capturing(self) == 0) {
|
|
- v4l2_close_device(self);
|
|
- return NULL;
|
|
- }
|
|
- }
|
|
+ v4l2_close_device(self);
|
|
+ return NULL;
|
|
} else {
|
|
self->camera_type = CAM_V4L2;
|
|
if (v4l2_init_device(self) == 0) {
|
|
diff -aur pygame/src/camera.h pygame-build/src/camera.h
|
|
--- pygame/src/camera.h 2011-04-13 17:43:41.901012178 +0200
|
|
+++ pygame-build/src/camera.h 2011-04-13 17:51:31.538890072 +0200
|
|
@@ -38,7 +38,6 @@
|
|
|
|
#include <asm/types.h> /* for videodev2.h */
|
|
|
|
- #include <linux/videodev.h>
|
|
#include <linux/videodev2.h>
|
|
#elif defined(__APPLE__)
|
|
#include <QuickTime/QuickTime.h>
|
|
@@ -64,7 +63,6 @@
|
|
#define RGB_OUT 1
|
|
#define YUV_OUT 2
|
|
#define HSV_OUT 4
|
|
-#define CAM_V4L 1
|
|
#define CAM_V4L2 2
|
|
|
|
struct buffer {
|