diff --git a/.gitignore b/.gitignore index eb2a1da..933737e 100644 --- a/.gitignore +++ b/.gitignore @@ -186,4 +186,8 @@ cython_debug/ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. -#.idea/ \ No newline at end of file +#.idea/ +/dev/ +/test/ +/main.py +/build_wheel.bat diff --git a/pilk/__init__.py b/pilk/__init__.py index b604027..ec95168 100644 --- a/pilk/__init__.py +++ b/pilk/__init__.py @@ -8,12 +8,12 @@ __title__ = 'pilk' __description__ = 'python silk codec binding' __url__ = 'https://github.com/foyoux/pilk' -__version__ = '0.0.2' +__version__ = '0.2.4' # noinspection SpellCheckingInspection __author__ = 'foyou' __author_email__ = 'yimi.0822@qq.com' -__license__ = 'Apache 2.0' -__copyright__ = f'Copyright 2022 {__author__}' +__license__ = ' GPL-3.0' +__copyright__ = f'Copyright 2022~2023 {__author__}' __ide__ = 'PyCharm - https://www.jetbrains.com/pycharm/' @@ -33,10 +33,8 @@ def get_duration(silk_path: str, frame_ms: int = 20) -> int: size = silk.read(2) if len(size) != 2: break - size = size[0] + size[1] << 8 - if not tencent and size == 0xffff: - break i += 1 + size = size[0] + size[1] * 16 silk.seek(silk.tell() + size) return i * frame_ms diff --git a/setup.py b/setup.py index 7879e03..adf354b 100644 --- a/setup.py +++ b/setup.py @@ -20,7 +20,7 @@ # noinspection SpellCheckingInspection setup( name='pilk', - version='0.2.3', + version='0.2.4', description='python silk voice library', long_description=long_description, long_description_content_type='text/markdown',