Wednesday, February 27, 2008

Beam it, play it, fix it, repeat

I had an argument with the CVS repository last night, but i finally managed to make it accept a new branch with the sources for runme featuring the NTXM player. I hope 0xtob won't be against the re-diffusion of his sources (well, he shouldn't since they're LGPL) ... I am now able to upload any .xm to the DS (up to 512KB) and play it with NTXM. I can also upgrade the software to a new build by just pressing SELECT (and test new effects). All it required was a small rewrite of the XMTransport class so that it works with an (abstract) DataReader rather than plain FILE* ... It even makes it more elegant ^_^

Après moult adverses commandes contre Sieur CVS, m'est avis que la nouvelle branche du projest ustilisant le ménestriciel NTXM estoit fièrement campée. Eh oui. Je vais laisser libmikmod derrière moi et poursuivre avec le code (lgpl) de 0xtob. Je peux donc uploader un .XM (jusqu'à 512KB) sur ma DS puis l'écouter avec NTXM. un p'tit SELECT et c'est le player que je mets à jour (histoire de tester le support de nouveaux effets). ça ne m'aura demander qu'une légère réécriture de XMTransport.

edit: okay, i've got "set tempo/speed" effect added. I also added (untested) offset effect and wrote a small tool that inspect .xm to report what effects they're using... I'm not that happy with the way the player keeps state, anyway. Both "Instrument" and "Sample" classes are used as an "samples database", but nothing capture the current state of a playing note, which makes e.g. offset effect tedious to implement ... I fear similar boring edits to be required when we'll have to support retrig and the like.

3 comments:

PypeBros said...

"When using linear Freq Tables, the distance between two octaves is
255 portamento units. e.g. the effect "1FF" at speed 1 will slide the
pitch one octave up."

(http://aluigi.altervista.org/mymusic/xm.txt)

Anonymous said...

c'est bien, c'est bien.. tu ne te décourrages pas.. et tu pourras bientot rentabiliser toutes mes compos.. et les autres "programmeurs homebrew" pourront ensuite s'inspirer de cela pour eux aussi rentabiliser mes compos ;)

héhé

PypeBros said...

http://deku.gbadev.org/program/sound8.html#portaupdown

"static void MODFXPortaUpMid(MOD_UPDATE_VARS *vars)
{
vars->modChn->period =
MODPitchSlide(vars->modChn->period, -vars->modChn->portaSpeed); // Negative=higher pitch
vars->updateFlags |= MOD_UPD_FLG_SET_FREQ;
}"