MCPcopy Create free account
hub / github.com/bspaans/python-mingus / header

Method header

mingus/midi/midi_file_out.py:47–50  ·  view source on GitHub ↗

Return a header for type 1 MIDI file.

(self)

Source from the content-addressed store, hash-verified

45 return self.header() + b"".join(tracks)
46
47 def header(self):
48 """Return a header for type 1 MIDI file."""
49 tracks = a2b_hex("%04x" % len([t for t in self.tracks if t.track_data != ""]))
50 return b"MThd\x00\x00\x00\x06\x00\x01" + tracks + self.time_division
51
52 def reset(self):
53 """Reset every track."""

Callers 1

get_midi_dataMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected