PDA

View Full Version : What's the best way to flash a LED in IPlug?


cc_
11-13-2010, 02:48 AM
What's the best way to flash a LED in IPlug? At first I thought of doing it using a timer in processreplacing, but that seems icky. Is there any way to keep it in the GUI thread?

olilarkin
11-13-2010, 05:40 AM
Why not count calls to your draw function and only draw it "on" every 25 frames for example (if your Fps is 25). Obviously you need to make sure the control is allways dirty so the draw function gets called. If you want it to be in sync with the host I guess you have to set the state from process replacing.

cc_
11-13-2010, 09:00 AM
Ah yes, setting it always dirty and counting in draw a good idea. I don't need it in sync with the host.