Forcing an effect to start at the beginning

Write here what nice effects or shows you have done with MADRIX or ask other users.

Moderator: MADRIX Team

Locked
MarkC
Posts: 18
Joined: Thu Jul 29, 2010 2:19 am

Forcing an effect to start at the beginning

Post by MarkC »

Hello,
-
I am controlling Madrix from another program via the DMX input. Each button has a different effect that is triggered at specific points in each song (so the effects are synchonized with the song).
-
My problem is that some effects do not start at the beginning when you trigger them more than once. Rather they start wherever they left off the last time you used it. For example, if you have a scrolling text sentence it will not start at the beginning of the sentence, but rather continue mid sentence or whever you left it last time you used it. I have a similar problem with Color Change.
-
Does anybody have a workaround? Maybe adding a macro to force an effect to restart each time it is used? Or maybe I've just missed something.
-
Thanks for any help you can give!
-
Mark
Fritzsche
Support
Support
Posts: 735
Joined: Mon Oct 05, 2009 5:26 pm
Contact:

Re: Forcing an effect to start at the beginning

Post by Fritzsche »

Hi MarkC,

This Effect Macro should help:

Code: Select all

@scriptname="";
@author="";
@version="";
@description="";

float f;

void InitEffect()
{
	f = GetFrameCount();
}

void PreRenderEffect()
{
	f+=GetFrameSteps();
	SetFrameId(fmod(f,GetFrameCount()));
}

void PostRenderEffect()
{

}

void MatrixSizeChanged()
{
	InitEffect();
}
MarkC
Posts: 18
Joined: Thu Jul 29, 2010 2:19 am

Re: Forcing an effect to start at the beginning

Post by MarkC »

Hi Dannenberg,

Your solution looks like it would work. Thanks for helping out!

Unfortunately some of these functions are not recoginized when compiling a macro. I tried the code in a regular script and it compiles OK. But when I put the same code in a macro it gives the error "The function 'GetFrameCount' does not exist. If I comment out that function it then gives the error 'GetFrameSteps' does not exist. It looks like maybe the macro compiler is not recognizing all of the same functions as the script compiler. Could this be a bug?

I am running the lastest version (2.13a).

Thanks again for your help!

Mark
Fritzsche
Support
Support
Posts: 735
Joined: Mon Oct 05, 2009 5:26 pm
Contact:

Re: Forcing an effect to start at the beginning

Post by Fritzsche »

Ok, I am sorry. Maybe I should have been clearer.

In general, there are 4 different locations on where to use a Macro/Script:
- Main Output Macro
- Storage Place Macro
- Effect Macro
- MAS Script Effect

And you are right, some functions work in all four places, while others are specific and not universal.

The Macro I posted above is a Macro for Effects. As such, it works fine on my computer. I also tested it before posting in this thread.

So please make sure to use the right one, as shown at the end of this chapter of the user guide: http://help.madrix.com/index.html?hidd_ ... rray_.html

Are you still encountering problems?

Thanks.
MarkC
Posts: 18
Joined: Thu Jul 29, 2010 2:19 am

Re: Forcing an effect to start at the beginning

Post by MarkC »

Thanks Dannenberg,

You were right, I had it in the wrong place - and now it's working great.
-
I was using the Storage Place Macro and not the Effect Macro. In the past I've written a lot of MAS Script Macros but this is the first time I've tried effect macros and I didn't realize there were 3 other places macros could be used (and obviously I picked the wrong one).
-
Thanks again for our help!
-
Mark
neilric99
Posts: 33
Joined: Sun Oct 10, 2010 6:37 pm

Re: Forcing an effect to start at the beginning

Post by neilric99 »

I like people posting issues that they see as it opens up a dialog with the developers. We all learn so much about how powerful Madrix is and how much thought has gone into making it a great product.

I nearly all cases we have been pointed to the manual for the answer, I just wish the manual was intuitive to read to able to easily find the answers ourselves, the best for this IMHO is through the use of tutorials and web based training.

Neil
in So California
Fritzsche
Support
Support
Posts: 735
Joined: Mon Oct 05, 2009 5:26 pm
Contact:

Re: Forcing an effect to start at the beginning

Post by Fritzsche »

Thank you very much for your feedback!

If something comes up, please let us know in this thread!


@Neil I am sorry to hear that the manual cannot hold up to your expectations. If you have some comments, please let me know by sending an e-mail or message. Thanks!
neilric99
Posts: 33
Joined: Sun Oct 10, 2010 6:37 pm

Re: Forcing an effect to start at the beginning

Post by neilric99 »

Theres no problem with the manual, its more an issue of how-to's & tutorials etc.

In all cases where you have pointed to the section of the manual that describes what we need it has been useful. There are so many features in Madrix that this would normally be handled by structured training classes. DO you do this at the big exhibitions that you attend or your distributors doing training locally.

I wont be able to attend LDI this year, but I will be in LA for the concert lighting master class. I see a number of training events around that event, but dont see anything Madrix.
Locked