C# Class GtkZBar.Scanner

Inheritance: Gtk.DrawingArea
Afficher le fichier Open project: jonasfj/zbar-sharp

Méthodes publiques

Méthode Description
Close ( ) : void
ListVideoSources ( ) : string>.IDictionary

List potential video sources on the system

This just adds a default device without checking it's existance on Windows. On Linux this list all /dev/video* devices, and attempts to get their name using /lib/udev/v4l_id, watch the kernel source (link available in source comments) to that this remains compatible. Alternately, define UDEV_RULES and the "/dev/v4l/by-id/" symlinks will be used to find the names. Note this presumably depends on Ubuntu 9.10 udev rules. Thus the other approach is preffered. Note that on Linux this might be solve a lot better using HAL over dbus, however, last I checked HAL is being replaced by DeviceKit which isn't done yet, so unless the APIs are expected to remain stable HAL is a waste of time.

Open ( string device ) : void

Open a video device

ResetLastItemScanned ( ) : void

Resets the last item scanned

This method may only be called from UI-thread.

Scanner ( ) : System

Méthodes protégées

Méthode Description
OnExposeEvent ( Gdk ev ) : bool
OnSizeAllocated ( Gdk allocation ) : void
OnSizeRequested ( Gtk &requisition ) : void

Private Methods

Méthode Description
CaptureVideo ( Video video, ImageScanner scanner ) : void

Capture and scan images

This method will also flip the images so that they need not be flipped when drawing.

HandleDestroyed ( object sender, EventArgs e ) : void
ProcessVideo ( ) : void

Process video, the worker thread

ThreadSafeRedraw ( ) : void

Simple threadsafe redraw method

Method Details

Close() public méthode

public Close ( ) : void
Résultat void

ListVideoSources() public static méthode

List potential video sources on the system
This just adds a default device without checking it's existance on Windows. On Linux this list all /dev/video* devices, and attempts to get their name using /lib/udev/v4l_id, watch the kernel source (link available in source comments) to that this remains compatible. Alternately, define UDEV_RULES and the "/dev/v4l/by-id/" symlinks will be used to find the names. Note this presumably depends on Ubuntu 9.10 udev rules. Thus the other approach is preffered. Note that on Linux this might be solve a lot better using HAL over dbus, however, last I checked HAL is being replaced by DeviceKit which isn't done yet, so unless the APIs are expected to remain stable HAL is a waste of time.
public static ListVideoSources ( ) : string>.IDictionary
Résultat string>.IDictionary

OnExposeEvent() protected méthode

protected OnExposeEvent ( Gdk ev ) : bool
ev Gdk
Résultat bool

OnSizeAllocated() protected méthode

protected OnSizeAllocated ( Gdk allocation ) : void
allocation Gdk
Résultat void

OnSizeRequested() protected méthode

protected OnSizeRequested ( Gtk &requisition ) : void
requisition Gtk
Résultat void

Open() public méthode

Open a video device
public Open ( string device ) : void
device string /// Video device to open ///
Résultat void

ResetLastItemScanned() public méthode

Resets the last item scanned
This method may only be called from UI-thread.
public ResetLastItemScanned ( ) : void
Résultat void

Scanner() public méthode

public Scanner ( ) : System
Résultat System