Liking cljdoc? Tell your friends :D

javax.sound.midi.Sequence

A Sequence is a data structure containing musical information (often an entire song or composition) that can be played back by a Sequencer object. Specifically, the Sequence contains timing information and one or more tracks. Each track consists of a series of MIDI events (such as note-ons, note-offs, program changes, and meta-events). The sequence's timing information specifies the type of unit that is used to time-stamp the events in the sequence.

A Sequence can be created from a MIDI file by reading the file into an input stream and invoking one of the getSequence methods of MidiSystem. A sequence can also be built from scratch by adding new Tracks to an empty Sequence, and adding MidiEvent objects to these Tracks.

A Sequence is a data structure containing musical
information (often an entire song or composition) that can be played
back by a Sequencer object. Specifically, the
Sequence contains timing
information and one or more tracks.  Each track consists of a
series of MIDI events (such as note-ons, note-offs, program changes, and meta-events).
The sequence's timing information specifies the type of unit that is used
to time-stamp the events in the sequence.

A Sequence can be created from a MIDI file by reading the file
into an input stream and invoking one of the getSequence methods of
MidiSystem.  A sequence can also be built from scratch by adding new
Tracks to an empty Sequence, and adding
MidiEvent objects to these Tracks.
raw docstring

*-ppqclj

Static Constant.

The tempo-based timing type, for which the resolution is expressed in pulses (ticks) per quarter note.

type: float

Static Constant.

The tempo-based timing type, for which the resolution is expressed in pulses (ticks) per quarter note.

type: float
raw docstring

*-smpte-24clj

Static Constant.

The SMPTE-based timing type with 24 frames per second (resolution is expressed in ticks per frame).

type: float

Static Constant.

The SMPTE-based timing type with 24 frames per second (resolution is expressed in ticks per frame).

type: float
raw docstring

*-smpte-25clj

Static Constant.

The SMPTE-based timing type with 25 frames per second (resolution is expressed in ticks per frame).

type: float

Static Constant.

The SMPTE-based timing type with 25 frames per second (resolution is expressed in ticks per frame).

type: float
raw docstring

*-smpte-30clj

Static Constant.

The SMPTE-based timing type with 30 frames per second (resolution is expressed in ticks per frame).

type: float

Static Constant.

The SMPTE-based timing type with 30 frames per second (resolution is expressed in ticks per frame).

type: float
raw docstring

*-smpte-30-dropclj

Static Constant.

The SMPTE-based timing type with 29.97 frames per second (resolution is expressed in ticks per frame).

type: float

Static Constant.

The SMPTE-based timing type with 29.97 frames per second (resolution is expressed in ticks per frame).

type: float
raw docstring

->sequenceclj

(->sequence division-type resolution)
(->sequence division-type resolution num-tracks)

Constructor.

Constructs a new MIDI sequence with the specified timing division type, timing resolution, and number of tracks. The division type must be one of the recognized MIDI timing types. For tempo-based timing, divisionType is PPQ (pulses per quarter note) and the resolution is specified in ticks per beat. For SMTPE timing, divisionType specifies the number of frames per second and the resolution is specified in ticks per frame. The sequence will be initialized with the number of tracks specified by numTracks. These tracks are initially empty (i.e. they contain only the meta-event End of Track). The tracks may be retrieved for editing using the getTracks() method. Additional tracks may be added, or existing tracks removed, using createTrack() and deleteTrack(javax.sound.midi.Track).

division-type - the timing division type (PPQ or one of the SMPTE types) - float resolution - the timing resolution - int num-tracks - the initial number of tracks in the sequence. - int

throws: javax.sound.midi.InvalidMidiDataException - if divisionType is not valid

Constructor.

Constructs a new MIDI sequence with the specified timing division
 type, timing resolution, and number of tracks.  The division type must be one of the
 recognized MIDI timing types.  For tempo-based timing,
 divisionType is PPQ (pulses per quarter note) and
 the resolution is specified in ticks per beat.  For SMTPE timing,
 divisionType specifies the number of frames per
 second and the resolution is specified in ticks per frame.
 The sequence will be initialized with the number of tracks specified by
 numTracks. These tracks are initially empty (i.e.
 they contain only the meta-event End of Track).
 The tracks may be retrieved for editing using the getTracks()
 method.  Additional tracks may be added, or existing tracks removed,
 using createTrack() and deleteTrack(javax.sound.midi.Track).

division-type - the timing division type (PPQ or one of the SMPTE types) - `float`
resolution - the timing resolution - `int`
num-tracks - the initial number of tracks in the sequence. - `int`

throws: javax.sound.midi.InvalidMidiDataException - if divisionType is not valid
raw docstring

create-trackclj

(create-track this)

Creates a new, initially empty track as part of this sequence. The track initially contains the meta-event End of Track. The newly created track is returned. All tracks in the sequence may be retrieved using getTracks(). Tracks may be removed from the sequence using deleteTrack(javax.sound.midi.Track).

returns: the newly created track - javax.sound.midi.Track

Creates a new, initially empty track as part of this sequence.
 The track initially contains the meta-event End of Track.
 The newly created track is returned.  All tracks in the sequence
 may be retrieved using getTracks().  Tracks may be
 removed from the sequence using deleteTrack(javax.sound.midi.Track).

returns: the newly created track - `javax.sound.midi.Track`
raw docstring

delete-trackclj

(delete-track this track)

Removes the specified track from the sequence.

track - the track to remove - javax.sound.midi.Track

returns: true if the track existed in the track and was removed, otherwise false. - boolean

Removes the specified track from the sequence.

track - the track to remove - `javax.sound.midi.Track`

returns: true if the track existed in the track and was removed,
 otherwise false. - `boolean`
raw docstring

get-division-typeclj

(get-division-type this)

Obtains the timing division type for this sequence.

returns: the division type (PPQ or one of the SMPTE types) - float

Obtains the timing division type for this sequence.

returns: the division type (PPQ or one of the SMPTE types) - `float`
raw docstring

get-microsecond-lengthclj

(get-microsecond-length this)

Obtains the duration of this sequence, expressed in microseconds.

returns: this sequence's duration in microseconds. - long

Obtains the duration of this sequence, expressed in microseconds.

returns: this sequence's duration in microseconds. - `long`
raw docstring

get-patch-listclj

(get-patch-list this)

Obtains a list of patches referenced in this sequence. This patch list may be used to load the required Instrument objects into a Synthesizer.

returns: an array of Patch objects used in this sequence - javax.sound.midi.Patch[]

Obtains a list of patches referenced in this sequence.
 This patch list may be used to load the required
 Instrument objects
 into a Synthesizer.

returns: an array of Patch objects used in this sequence - `javax.sound.midi.Patch[]`
raw docstring

get-resolutionclj

(get-resolution this)

Obtains the timing resolution for this sequence. If the sequence's division type is PPQ, the resolution is specified in ticks per beat. For SMTPE timing, the resolution is specified in ticks per frame.

returns: the number of ticks per beat (PPQ) or per frame (SMPTE) - int

Obtains the timing resolution for this sequence.
 If the sequence's division type is PPQ, the resolution is specified in ticks per beat.
 For SMTPE timing, the resolution is specified in ticks per frame.

returns: the number of ticks per beat (PPQ) or per frame (SMPTE) - `int`
raw docstring

get-tick-lengthclj

(get-tick-length this)

Obtains the duration of this sequence, expressed in MIDI ticks.

returns: this sequence's length in ticks - long

Obtains the duration of this sequence, expressed in MIDI ticks.

returns: this sequence's length in ticks - `long`
raw docstring

get-tracksclj

(get-tracks this)

Obtains an array containing all the tracks in this sequence. If the sequence contains no tracks, an array of length 0 is returned.

returns: the array of tracks - javax.sound.midi.Track[]

Obtains an array containing all the tracks in this sequence.
 If the sequence contains no tracks, an array of length 0 is returned.

returns: the array of tracks - `javax.sound.midi.Track[]`
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close