MCPcopy Create free account
hub / github.com/christophhart/HISE / fillPath

Method fillPath

hi_scripting/scripting/api/ScriptingGraphics.cpp:2274–2291  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2272}
2273
2274void ScriptingObjects::GraphicsObject::fillPath(var path, var area)
2275{
2276 if (PathObject* pathObject = dynamic_cast<PathObject*>(path.getObject()))
2277 {
2278 Path p = pathObject->getPath();
2279
2280 if (p.getBounds().isEmpty())
2281 return;
2282
2283 if (area.isArray())
2284 {
2285 Rectangle<float> r = getRectangleFromVar(area);
2286 p.scaleToFit(r.getX(), r.getY(), r.getWidth(), r.getHeight(), false);
2287 }
2288
2289 drawActionHandler.addDrawAction(new ScriptedDrawActions::fillPath(p));
2290 }
2291}
2292
2293void ScriptingObjects::GraphicsObject::drawPath(var path, var area, var strokeType)
2294{

Callers 15

drawBackgroundMethod · 0.45
paintItemMethod · 0.45
paintMethod · 0.45
Oscilloscope.jsFile · 0.45
BufferMonitor.jsFile · 0.45
paintMethod · 0.45
paintMethod · 0.45
applyMaskMethod · 0.45
drawLinearSliderMethod · 0.45
fillPathHiStyleMethod · 0.45
paintCableMethod · 0.45
drawVectorRotaryKnobMethod · 0.45

Calls 11

addDrawActionMethod · 0.80
getObjectMethod · 0.45
getPathMethod · 0.45
isEmptyMethod · 0.45
getBoundsMethod · 0.45
isArrayMethod · 0.45
scaleToFitMethod · 0.45
getXMethod · 0.45
getYMethod · 0.45
getWidthMethod · 0.45
getHeightMethod · 0.45

Tested by

no test coverage detected