mirror of
https://github.com/iluvcapra/wavinfo.git
synced 2025-12-31 17:00:41 +00:00
Made sampler udata field nullable
This commit is contained in:
@@ -93,9 +93,12 @@ class WavSmplReader:
|
|||||||
repetition_count=unpacked_loop[5]))
|
repetition_count=unpacked_loop[5]))
|
||||||
|
|
||||||
#: Sampler-specific user data.
|
#: Sampler-specific user data.
|
||||||
self.sampler_udata: bytes = smpl_data[
|
self.sampler_udata: bytes | None = None
|
||||||
header_size + loop_size * loop_count:
|
|
||||||
header_size + loop_size * loop_count + sampler_udata_length]
|
if sampler_udata_length > 0:
|
||||||
|
self.sampler_udata = smpl_data[
|
||||||
|
header_size + loop_size * loop_count:
|
||||||
|
header_size + loop_size * loop_count + sampler_udata_length]
|
||||||
|
|
||||||
def to_dict(self):
|
def to_dict(self):
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user