[directmusic] RE : Re: RE : Re: Primary and secondary segments...

  • From: "John Difool" <jdifool@xxxxxxxxxxxx>
  • To: directmusic@xxxxxxxxxxxxx
  • Date: Wed, 19 Feb 2003 17:25:40 +0100


Sorry for my ignorance, but I just can't do it. As soon as I try to
modify the tempo once the tempo is track added, the music does not play
anymore.

This is Delphi please just focus on the calls...

////////////////////////////////////////////////////////////////////

Tempo             : TDMus_Tempo_Param;
DMTempoTrack      : IDirectMusicTrack8 =3D NULL;

CoCreateInstance(CLSID_DirectMusicTempoTrack, nil, CLSCTX_INPROC,
IID_IDirectMusicTrack8, DMTempoTrack);

DMSegment2.InsertTrack(DMTempoTrack, $1);

Tempo.dblTempo :=3D 130;

DMSegment2.SetParam(GUID_TempoParam, $1, DMUS_SEG_ALLTRACKS , 0,
@Tempo);

////////////////////////////////////////////////////////////////////////

What's wrong in there, no compilation error, just no sound anymore. If I
deleted the Setparam call, everything is fine.

Thanks


-----Message d'origine-----
De=A0: directmusic-bounce@xxxxxxxxxxxxx
[mailto:directmusic-bounce@xxxxxxxxxxxxx] De la part de Todor Fay
Envoy=E9=A0: mardi 18 f=E9vrier 2003 20:42
=C0=A0: directmusic@xxxxxxxxxxxxx
Objet=A0: [directmusic] Re: RE : Re: Primary and secondary segments...


Good. I'm sure that was your problem.

No, secondary segments should not have tempo tracks. That would compete
with the tempo track in the primary segment. Actually, I'm pretty sure
that in DX8 and on this is not a problem, the secondary segment tempo
track is ignored.=20

Todor

-----Original Message-----
From: directmusic-bounce@xxxxxxxxxxxxx
[mailto:directmusic-bounce@xxxxxxxxxxxxx] On Behalf Of John Difool
Sent: Tuesday, February 18, 2003 11:33 AM
To: directmusic@xxxxxxxxxxxxx
Subject: [directmusic] RE : Re: Primary and secondary segments...



No, I didn't insert a tempo track. I'll do that.

BTW do I have to add a tempo to the secondary segments as well? Or a
tempo track in the primary segment is enough?

-----Message d'origine-----
De=3DA0: directmusic-bounce@xxxxxxxxxxxxx
[mailto:directmusic-bounce@xxxxxxxxxxxxx] De la part de Todor Fay
Envoy=3DE9=3DA0: mardi 18 f=3DE9vrier 2003 06:26
=3DC0=3DA0: directmusic@xxxxxxxxxxxxx
Objet=3DA0: [directmusic] Re: Primary and secondary segments...


Does the segment have a tempo track? If it doesn't, that is why you are
getting the message. Playing as a primary does not automatically install
a tempo track; that must be authored in the first place.=3D20

Todor

-----Original Message-----
From: directmusic-bounce@xxxxxxxxxxxxx
[mailto:directmusic-bounce@xxxxxxxxxxxxx] On Behalf Of John Difool
Sent: Monday, February 17, 2003 12:52 PM
To: directmusic@xxxxxxxxxxxxx
Subject: [directmusic] Primary and secondary segments...



Hi,

I would like to know what makes a segment the primary segment and what
makes others the secondaries?

The only difference I see is the flag in the PlaysegmentEx
(DMUS_SEGF_SECONDARY or not), is that it?

I am asking this because I want to set the tempo in the primary segment
(default control segment) but what seems to be the primary segment (the
only one I play without the DMUS_SEGF_SECONDARY flag) keeps returning
the error message "the requested track is not contained by the segment"
when I use the Setparam function.

What am I missing?

Thanks in advance.















Other related posts:

  • » [directmusic] RE : Re: RE : Re: Primary and secondary segments...