MIDI

Jan Waclawek wek@evona.sk
Pondělí Leden 30 11:20:25 CET 2006


Zo specifikacie MIDI-SMF:
<delta-time> is stored as a variable-length quantity.  It represents the
amount of time before the following event.  If the first event in a
track occurs at the very beginning of a track, or if two events occur
simultaneously, a delta-time of zero is used.  Delta-times are always
present.  (Not storing delta-times of 0 requires at least two bytes for
any other value, and most delta-times aren't zero.)  Delta-time is in
some fraction of a beat (or a second, for recording a track with SMPTE
times), as specified in the header chunk.

Inaksie povedane, jednotka casu nie je fixne stanovena a je definovana v 
header chunk dvoma parametrami, jeden urcuje tempo (t.j. trvanie 
stvrtovej noty (beat)) a druhy urcuje pocet tickov (casovych jednotiek) 
v jednej stvrtovej note.

Odporucam nastudovat si cely dokument.

wek

PS.: nechapem preco su v konfere len niektore odkazy z threadu...

PS2.: davam ku vseobecnemu dobru jeden moj rany vytvor, ktory parsuje 
MID subor a vypluje ho v citatelnej podobe (urcite su aj podobne profi, 
ale tym ze som ho pisal som mnohe pochopil): 
http://www.efton.sk/misc/READMIDI.EXE (pochopitelne, klasicky 
disclaimer, moze to byt absolutne nepouzitele).


Marek Peca wrote:
>>No tak to tu ted zkousim, ale nejak mi to nevychazi:
>>Mam tu treba (FF.51) je 645161d a vyexperimentovany vysledek je asi
>>790us/tik.
>>Pritom tu mam ale FF 58 04 04 02 18 08 a tedy:
>>645161 / 24 = 26880 ale ja potrebuju mnohem min, neco kolem zminovanych 790.
>>Nevite co s tim ?
> 
> 
> Tak to nevim, uz si to nepamatuju a moje nekdejsi MIDI programy
> strezi vyhorely harddisk. Nicmene, 26880/790 je neco kolem triceti,
> tak me napada, jestli to tttttt neni spis v 1/32 mikrosekundy -- to
> je totiz hodinova frekvence MIDI (1MHz/32 = 31250Hz).
> 
> Je tu nekdo, kdo si odpoved na tuto otazku smyslu byti a vesmiru
> pamatuje?
> 
> ZdraviM.P.
> 
> 
>>ZN
>>
>>
>>----- Original Message -----
>>From: "Marek Peca" <marek@tynska.cuni.cz>
>>To: "HW-news" <hw-list@list.hw.cz>
>>Sent: Friday, January 27, 2006 8:28 PM
>>Subject: Re: MIDI
>>
>>
>>Je to tady, jenom jsem slepej:
>>
>>1) Tempo
>>
>>FF 51 03 tt tt tt
>>
>>Indicates a tempo change. The 3 data bytes of tt tt tt are the tempo
>>in microseconds per quarter note.
>>
>>2) Time Signature
>>
>>FF 58 04 nn dd cc bb
>>
>>Time signature is expressed as 4 numbers. nn and dd represent the
>>"numerator" and "denominator" of the signature as notated on sheet
>>music. The denominator is a negative power of 2: 2 = quarter note, 3
>>= eighth, etc. The cc expresses the number of MIDI clocks in a
>>metronome click. The bb parameter expresses the number of notated
>>32nd notes in a MIDI quarter note (24 MIDI clocks). This event allows
>>a program to relate what MIDI thinks of as a quarter, to something
>>entirely different. For example, 6/8 time with a metronome click
>>every 3 eighth notes and 24 clocks per quarter note would be the
>>following event:
>>
>>FF 58 04 06 03 18 08
>>
>>Jasne, takze konkretni casovy udaj musite vypocitat z tttttt a cc.
>>(pocet_us_za_jednotku = tttttt/cc)
>>
>>S MIDI je ale jinak krasa delat, uz se mi po tom stejska :)
>>Delal jsem sqelej 32kanalovej MIDI-kontroler s AT89C2051, kterej
>>misto A/D prevodniku pouzival vestavenej komparator a logaritmicky
>>potenciometry na dorovnani RC exponencialy.
>>
>>Ale je to masakr, kdyz krome vlastnich dat zpracovavate jeste
>>prichozi odjinud, musi se davat bacha na pripadne vkladani
>>prikazovejch bajtu a taky na preteceni vyrovnavaci pameti.
>>
>>
>>Pekny vecer,
>>Marek P.
>>
>>_______________________________________________
>>HW-list mailing list  -  sponsored by www.HW.cz
>>Hw-list@list.hw.cz
>>http://list.hw.cz/mailman/listinfo/hw-list
>>
>>
>>--
>>No virus found in this incoming message.
>>Checked by AVG Free Edition.
>>Version: 7.1.375 / Virus Database: 267.14.23/240 - Release Date: 25.1.2006
>>
>>
> 
> 
> _______________________________________________
> HW-list mailing list  -  sponsored by www.HW.cz
> Hw-list@list.hw.cz
> http://list.hw.cz/mailman/listinfo/hw-list
> 




Další informace o konferenci Hw-list