From b9f147f3f72f0ce0eecf7e6598cad4b785aa4719 Mon Sep 17 00:00:00 2001 From: Walter Bender Date: Wed, 29 Dec 2010 17:03:42 +0000 Subject: refactored camera code to use poll for MESSAGE_EOS instead of timeout --- (limited to 'TurtleArt/tawindow.py') diff --git a/TurtleArt/tawindow.py b/TurtleArt/tawindow.py index a063a2d..ba5b5cf 100755 --- a/TurtleArt/tawindow.py +++ b/TurtleArt/tawindow.py @@ -249,11 +249,6 @@ class TurtleArtWindow(): CONSTANTS['width'] = int(self.canvas.width / self.coord_scale) CONSTANTS['height'] = int(self.canvas.height / self.coord_scale) - self.lc = LogoCode(self) - self.saved_pictures = [] - - self.block_operation = '' - if self.interactive_mode: self._setup_misc() self._show_toolbar_palette(0, False) @@ -264,13 +259,18 @@ class TurtleArtWindow(): PALETTES[PALETTE_NAMES.index('sensor')].append('voltage') self.audio_started = False - self.camera = False + self.camera_available = False v4l2src = gst.element_factory_make('v4l2src') if v4l2src.props.device_name is not None: PALETTES[PALETTE_NAMES.index('sensor')].append('readcamera') PALETTES[PALETTE_NAMES.index('sensor')].append('luminance') PALETTES[PALETTE_NAMES.index('sensor')].append('camera') - self.camera = True + self.camera_available = True + + self.lc = LogoCode(self) + self.saved_pictures = [] + + self.block_operation = '' """ The following code will initialize a USB RFID reader. Please note that -- cgit v0.9.1