View Single Post
Old 09-02-2020, 12:42 AM   #8
Tale
Human being with feelings
 
Tale's Avatar
 
Join Date: Jul 2008
Location: The Netherlands
Posts: 3,645
Default

There is a timer callback in IGraphicsWin.cpp, IGraphicsCocoa.mm, and IGraphicsCarbon.cpp that checks pGraphics->IsDirty(). If it returns true (which means one or more controls are dirty), then it tells the OS that the rectangle containing the dirty controls needs redrawing. Then IPlug gets a callback from the OS to redraw (Windows: WM_PAINT; Cocoa: drawRect; Carbon: kEventControlDraw), which calls pGraphics->Draw() with the rectangle that needs redrawing. In strict mode IPlug then simply redraws everything within that rectangle, dirty or not. It also calls pControl->SetClean() for each control, so after pGraphics->Draw() all controls will be clean.
Tale is offline   Reply With Quote