aboutsummaryrefslogtreecommitdiff
path: root/vimbainterface.py
diff options
context:
space:
mode:
authorJohn Sun <jsun@sightmachine.com>2014-04-02 16:22:14 -0700
committerJohn Sun <jsun@sightmachine.com>2014-04-02 16:22:14 -0700
commit01e24424971ffa9faa5dabf2e6724cea997a2afb (patch)
tree8882d0e2c93e2a1f74178c21b6bffa02a2edee16 /vimbainterface.py
parent54bec3f39dc7915593a29c22ed1aac0e29ab53b6 (diff)
downloadpymba-01e24424971ffa9faa5dabf2e6724cea997a2afb.tar.gz
pymba-01e24424971ffa9faa5dabf2e6724cea997a2afb.zip
First pass at making pymba a pip installable module.
1) Moved all the source-code under a new folder "pyvimba". Yes I changed the name. Feel free to change it back 2) Added initial CHANGES.txt, MANIFEST.in, LICENSE, README.txt 3) Move opencv_example.py to "tests" directory
Diffstat (limited to 'vimbainterface.py')
-rw-r--r--vimbainterface.py44
1 files changed, 0 insertions, 44 deletions
diff --git a/vimbainterface.py b/vimbainterface.py
deleted file mode 100644
index 03a5f80..0000000
--- a/vimbainterface.py
+++ /dev/null
@@ -1,44 +0,0 @@
-# -*- coding: utf-8 -*-
-import vimbastructure as structs
-from vimbaobject import VimbaObject
-from vimbaexception import VimbaException
-from vimbadll import VimbaDLL
-from ctypes import *
-
-# interface features are automatically readable as object attributes.
-class VimbaInterface(VimbaObject):
- """
- A Vimba interface object. This class provides the minimal access
- to Vimba functions required to control the interface.
- """
-
- @property
- def interfaceIdString(self):
- return self._interfaceIdString
-
- # own handle is inherited as self._handle
- def __init__(self, interfaceIdString):
-
- # call super constructor
- super(VimbaInterface, self).__init__()
-
- # set ID
- self._interfaceIdString = interfaceIdString
-
- def openInterface(self):
- """
- Open the interface.
- """
- errorCode = VimbaDLL.interfaceOpen(self._interfaceIdString,
- byref(self._handle))
- if errorCode != 0:
- raise VimbaException(errorCode)
-
- def closeInterface(self):
- """
- Close the interface.
- """
- errorCode = VimbaDLL.interfaceClose(self._handle)
- if errorCode != 0:
- raise VimbaException(errorCode)
- \ No newline at end of file