diff options
author | Mattias Andrée <maandree@kth.se> | 2016-08-16 12:38:01 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2016-08-16 12:38:01 +0200 |
commit | ab5165c215afef4f2bfa0b7e3859e055da493da6 (patch) | |
tree | 45c09e8a92435dba789dca88cc43e0731339f6b1 /src | |
parent | ... (diff) | |
download | pylibcoopgamma-ab5165c215afef4f2bfa0b7e3859e055da493da6.tar.gz pylibcoopgamma-ab5165c215afef4f2bfa0b7e3859e055da493da6.tar.bz2 pylibcoopgamma-ab5165c215afef4f2bfa0b7e3859e055da493da6.tar.xz |
Fix libcoopgamma.py + finish makefile
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r-- | src/libcoopgamma.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/libcoopgamma.py b/src/libcoopgamma.py index fe3e57a..162fa23 100644 --- a/src/libcoopgamma.py +++ b/src/libcoopgamma.py @@ -447,7 +447,7 @@ class FilterTable: and `filters[0].priority` are undefined. ''' def __init__(self, red_size : int = None, green_size : int = None, blue_size : int = None, - depth : Depth = None, filters : list): + depth : Depth = None, filters : list = None): ''' Constructor @@ -466,7 +466,10 @@ class FilterTable: self.green_size = green_size self.blue_size = blue_size self.depth = depth - self.filters = list(QueriedFilter(*f) if isinstance(f, tuple) else f for f in filters) + if filters is None: + self.filters + else: + self.filters = list(QueriedFilter(*f) if isinstance(f, tuple) else f for f in filters) def make_ramps(self) -> Ramps: ''' @@ -939,7 +942,7 @@ class Context: (successful, value) = value if successful: raise ErrorReport.create_error(value) - return FilterTable:(*value) + return FilterTable(*value) def get_gamma_sync(self, query : FilterQuery) -> FilterTable: ''' |