pytimbre.audio.ListChunk

class pytimbre.audio.ListChunk(reader: FileIO = None, size: int = None, offset: int = None, name: str = None)

Bases: ChunkInformation

This 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_location

artist

chunk_name

chunk_offset

chunk_size

color_palette_count

commissioned_organization

copyright

creation_date

creation_software

cropping_information

data_source

description

digitizing_engineer

dots_per_inch

engineer_name

file_start_time

general_comments

key_words

lightness_settings

original_form

originating_object_dimensions

originating_object_medium

subject_genre

subject_name

title

track_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