pytimbre.audio.ListChunk¶
- class pytimbre.audio.ListChunk(reader: FileIO = None, size: int = None, offset: int = None, name: str = None)¶
Bases:
ChunkInformationThis is an extra chunk that can provide metadata to the user through customizable fields.
- __init__(reader: FileIO = None, size: int = None, offset: int = None, name: str = None)¶
This will construct the information within the class and read the contents of the LIST chunk :param reader: FileIO - the binary reader that will be able to extract the information from the file :param size: int - the size of the data chunk :param offset: int - the offset of the chunk’s data :param name: str - the name of the chunk
https://www.recordingblogs.com/wiki/list-chunk-of-a-wave-file#:~:text=List%20chunk%20%28of%20a%20RIFF%20file %29%20%20,%20Depends%20on%20the%20list%20type%20ID%20
Methods
__init__([reader, size, offset, name])This will construct the information within the class and read the contents of the LIST chunk :param reader: FileIO - the binary reader that will be able to extract the information from the file :param size: int - the size of the data chunk :param offset: int - the offset of the chunk's data :param name: str - the name of the chunk
from_waveform(wfm)This function populates the data for the wave file from the information within the metadata class and a dictionary that may not be present within the metadata.
write_chunk(writer)This function writes the contents of this LIST chunk to the file at the current cursor location :param writer: FileIO - The object controlling how the data is written to the file
Attributes
archival_locationartistchunk_namechunk_offsetchunk_sizecolor_palette_countcommissioned_organizationcopyrightcreation_datecreation_softwarecropping_informationdata_sourcedescriptiondigitizing_engineerdots_per_inchengineer_namefile_start_timegeneral_commentskey_wordslightness_settingsoriginal_formoriginating_object_dimensionsoriginating_object_mediumsubject_genresubject_nametitletrack_number- static from_waveform(wfm)¶
This function populates the data for the wave file from the information within the metadata class and a dictionary that may not be present within the metadata. :param meta_data: The class containing information from the file :type meta_data: AudioMetaData
- write_chunk(writer)¶
This function writes the contents of this LIST chunk to the file at the current cursor location :param writer: FileIO - The object controlling how the data is written to the file