manually fix imports

This commit is contained in:
Thomas Kriechbaumer 2017-04-16 15:17:29 +02:00
parent dadb50946e
commit 83a428e0b7
2 changed files with 5 additions and 7 deletions

View File

@ -12,7 +12,9 @@ from kaitaistruct import __version__ as ks_version, KaitaiStruct, KaitaiStream,
if parse_version(ks_version) < parse_version('0.7'):
raise Exception("Incompatible Kaitai Struct Python API: 0.7 or later is required, but you have %s" % (ks_version))
from exif_le import ExifLe
from .exif_le import ExifLe
from .exif_be import ExifBe
class Exif(KaitaiStruct):
def __init__(self, _io, _parent=None, _root=None):
self._io = _io
@ -24,5 +26,3 @@ class Exif(KaitaiStruct):
self.body = ExifLe(self._io)
elif _on == 19789:
self.body = ExifBe(self._io)

View File

@ -12,7 +12,8 @@ from kaitaistruct import __version__ as ks_version, KaitaiStruct, KaitaiStream,
if parse_version(ks_version) < parse_version('0.7'):
raise Exception("Incompatible Kaitai Struct Python API: 0.7 or later is required, but you have %s" % (ks_version))
from exif import Exif
from .exif import Exif
class Jpeg(KaitaiStruct):
class ComponentId(Enum):
@ -207,6 +208,3 @@ class Jpeg(KaitaiStruct):
self.thumbnail_x = self._io.read_u1()
self.thumbnail_y = self._io.read_u1()
self.thumbnail = self._io.read_bytes(((self.thumbnail_x * self.thumbnail_y) * 3))