VEC namespace

Vector canvas drawing, plotting, layers, items and export.

Symbols in this namespace: 107

SymbolKindCategoryDescription
VEC.ANIM.CIRCLECommandVector animation statementsAlias of VEC.ANIM.ORBIT.
VEC.ANIM.MOVECommandVector animation statementsAnimates the item position. loops=1 runs once; loops=0 loops forever; yoyo=TRUE reverses every other loop.
VEC.ANIM.OPACITYCommandVector animation statementsAnimates item opacity between two values in range 0..1.
VEC.ANIM.OPACITY_KEYFRAMESCommandVector animation statementsAnimates item opacity using absolute time/value keyframes. This is useful for discrete states: switches, traffic lights, phase indicators, etc. loops=0 loops forever.
VEC.ANIM.OPACITY_PATHCommandVector animation statementsAlias of VEC.ANIM.OPACITY_KEYFRAMES.
VEC.ANIM.ORBITCommandVector animation statementsAnimates an item on a circular orbit around a center point. Alias: VEC.ANIM.CIRCLE.
VEC.ANIM.PATHCommandVector animation statementsAnimates an item along a polyline trajectory. Very useful for physics/mathematics demonstrations. Alias: VEC.ANIM.TRAJECTORY.
VEC.ANIM.ROTATECommandVector animation statementsAnimates the item rotation in degrees.
VEC.ANIM.ROTATE_PATHCommandVector animation statementsAnimates item rotation through a list of angle keyframes. This is more useful than linear rotation for physics, because the angle can come from a numerical simulation. Alias: VEC.ANIM.ROTATION_PATH.
VEC.ANIM.ROTATION_PATHCommandVector animation statementsAlias of VEC.ANIM.ROTATE_PATH.
VEC.ANIM.SCALECommandVector animation statementsAnimates uniform scale, useful for pulsating markers or attention cues.
VEC.ANIM.STATECommandVector animation statementsAlias of VEC.ANIM.OPACITY_KEYFRAMES, intended for visibility/state timelines.
VEC.ANIM.STOPCommandVector animation statementsStops animations. Omit itemId or pass 0 to stop all animations on the canvas.
VEC.ANIM.TRAJECTORYCommandVector animation statementsAlias of VEC.ANIM.PATH.
VEC.ANIM.VISIBLE_TIMELINECommandVector animation statementsAlias of VEC.ANIM.OPACITY_KEYFRAMES.
VEC.ARROWCommandVector canvas statementsAdds a line with a simple arrow head, useful for annotations and motion/vector diagrams.
VEC.ARROW_IDFunctionVector canvas functionsFunction form of VEC.ARROW. It returns the item id.
VEC.AXESCommandVector canvas statementsDraws X/Y axes with optional ticks. This is intentionally simple and script-friendly.
VEC.BATCHCommandVector canvas statementsTemporarily freezes viewport repaints/info-label updates while many vector items are created. Use VEC.BATCH v, TRUE before a heavy plot block and VEC.BATCH v, FALSE after it. Alias: VEC.FREEZE.
VEC.BRUSHCommandVector canvas statementsSets the fill brush for rectangles and ellipses. Use TRANSPARENT/NONE to draw outlines only.
VEC.CAPTURE_AVICommandVector export and capture statementsCaptures the animated vector canvas directly to an AVI file. Default codec is MJPG; aliases: VEC.SAVE_AVI and VEC.EXPORT_AVI.
VEC.CAPTURE_FRAMESCommandVector export and capture statementsAlias of VEC.CAPTURE_PNG.
VEC.CAPTURE_PNGCommandVector export and capture statementsCaptures a sequence of PNG frames from the current canvas while active animations are running. Aliases: VEC.CAPTURE_FRAMES and VEC.EXPORT_FRAMES.
VEC.CAPTURE_STACKFunctionVector canvas functionsCaptures the animated vector canvas into a stack/image-sequence object that can be passed to GUI.SHOW or saved by the normal image/stack pipeline. Alias: VEC.STACK.
VEC.CLEARCommandVector canvas statementsRemoves all vector items from the selected canvas without destroying the window.
VEC.CLOSECommandVector canvas statementsCloses a vector canvas window.
VEC.CREATEFunctionVector canvas functionsCreates an interactive vector canvas and returns a numeric handle. The canvas is a scriptable QGraphicsScene-based whiteboard that can be exported to SVG or rasterized back to a Mat.
VEC.ELLIPSECommandVector canvas statementsAdds an ellipse inscribed in the rectangle x,y,w,h using the current pen and brush.
VEC.ELLIPSE_IDFunctionVector canvas functionsFunction form of VEC.ELLIPSE. It adds the ellipse and returns its item id.
VEC.EXPORT_AVICommandVector export and capture statementsAlias of VEC.CAPTURE_AVI.
VEC.EXPORT_FRAMESCommandVector export and capture statementsAlias of VEC.CAPTURE_PNG.
VEC.FLUSHCommandVector canvas statementsAlias of VEC.SYNC.
VEC.FONTCommandVector canvas statementsSets the current font used by VEC.TEXT.
VEC.FRAMEFunctionVector canvas functionsAlias of VEC.MAT, named for animated/capture workflows: returns the current canvas frame as Mat.
VEC.FRAME_PNGCommandVector export and capture statementsAlias of VEC.SAVE_FRAME.
VEC.FREEZECommandVector canvas statementsAlias of VEC.BATCH.
VEC.GRIDCommandVector canvas statementsDraws a lightweight grid as one vector item. It is useful as a plotting/geometry reference layer.
VEC.IMAGECommandVector canvas statementsInserts the first frame of an image/stack into the vector canvas. If w and h are positive the image is scaled; opacity is 0..1.
VEC.IMAGE_IDFunctionVector canvas functionsFunction form of VEC.IMAGE. It adds the image layer and returns its item id.
VEC.ITEM.CENTER_XFunctionVector item query functionsReturns the current scene-center x coordinate of a vector item.
VEC.ITEM.CENTER_YFunctionVector item query functionsReturns the current scene-center y coordinate of a vector item.
VEC.ITEM.DRAGGABLECommandVector item statementsAlias of VEC.ITEM.MOVABLE.
VEC.ITEM.MOVABLECommandVector item statementsMakes an item draggable with the mouse inside the vector canvas. Movable items are also made selectable. Alias: VEC.ITEM.DRAGGABLE.
VEC.ITEM.MOVECommandVector item statementsAlias of VEC.ITEM.POS.
VEC.ITEM.OPACITYCommandVector item statementsSets opacity 0..1 for one existing item.
VEC.ITEM.OPACITY_VALUEFunctionVector item query functionsReturns the current opacity value of a vector item.
VEC.ITEM.ORIGINCommandVector item statementsSets the local transform origin/pivot for rotation and scale. Alias: VEC.ITEM.PIVOT. This is important for physical systems such as pendulums, levers and rotating arms.
VEC.ITEM.PIVOTCommandVector item statementsAlias of VEC.ITEM.ORIGIN.
VEC.ITEM.POSCommandVector item statementsSets the position transform of an existing vector item. Alias: VEC.ITEM.MOVE.
VEC.ITEM.ROTATECommandVector item statementsRotates an existing vector item around its local bounding-box center.
VEC.ITEM.ROTATIONFunctionVector item query functionsReturns the current rotation angle of a vector item in degrees.
VEC.ITEM.SCALECommandVector item statementsScales an existing item around its local bounding-box center. If sy is omitted, sx is used for both axes.
VEC.ITEM.SELECTABLECommandVector item statementsEnables or disables mouse selection for an existing vector item.
VEC.ITEM.XFunctionVector item query functionsReturns the current x position transform of a vector item.
VEC.ITEM.YFunctionVector item query functionsReturns the current y position transform of a vector item.
VEC.ITEM.ZCommandVector item statementsChanges the z-order of an existing item.
VEC.ITEM_COUNTFunctionVector canvas functionsReturns the number of registered vector items in the canvas.
VEC.LAST_ITEMFunctionVector canvas functionsReturns the numeric id of the last vector item created on the canvas. This id can be used by VEC.ITEM.* and VEC.ANIM.* commands.
VEC.LAYERCommandVector layer statementsAlias of VEC.LAYER.SELECT.
VEC.LAYER.CLEARCommandVector layer statementsDeletes all vector items assigned to the selected layer. Useful for interactive redraw loops where a dynamic overlay is recalculated.
VEC.LAYER.SELECTCommandVector layer statementsSelects the current drawing layer. New vector items are assigned to that layer. The default layer is named default.
VEC.LAYER.SHOWCommandVector layer statementsAlias of VEC.LAYER.VISIBLE.
VEC.LAYER.VISIBLECommandVector layer statementsShows or hides all items belonging to a layer. Alias: VEC.LAYER.SHOW.
VEC.LINECommandVector canvas statementsAdds a line using the current pen.
VEC.LINE_IDFunctionVector canvas functionsFunction form of VEC.LINE. It adds the line and returns its item id.
VEC.MATFunctionVector canvas functionsRasterizes the current vector canvas and returns it as an image/Mat value. By default it produces a normal 3-channel BGR Mat; with transparent=TRUE it keeps an alpha channel and makes the background transparent.
VEC.NEWFunctionVector canvas functionsAlias of VEC.CREATE.
VEC.OPACITYCommandVector canvas statementsSets the default opacity for following vector items. Opacity is 0..1.
VEC.PENCommandVector canvas statementsSets the current stroke color, width and style for following vector primitives. Colors are Qt names or #RRGGBB. Styles: SOLID, DASH, DOT, DASHDOT, DASHDOTDOT, NONE.
VEC.PLOT.AREACommandVector plot statementsDraws a filled area under a data polyline down to a baseline. Use VEC.BRUSH before the command to choose the fill color; alias: VEC.PLOT.FILL.
VEC.PLOT.AXESCommandVector plot statementsDraws a scientific plot frame in the given rectangle, including border, tick marks, optional grid and zero axes when visible in range.
VEC.PLOT.BARCommandVector plot statementsAlias of VEC.PLOT.BARS.
VEC.PLOT.BARSCommandVector plot statementsDraws a categorical bar plot from a numeric list. The current brush fills the bars, and the current pen outlines them.
VEC.PLOT.FILLCommandVector plot statementsAlias of VEC.PLOT.AREA.
VEC.PLOT.FUNCTIONCommandVector plot statementsEvaluates a function of x and plots it as a polyline. The expression can use normal math functions such as SIN, COS, EXP, SQRT, etc. When autoScale is TRUE the y range is estimated from the sampled values.
VEC.PLOT.FUNCTION_IDFunctionVector plot functionsFunction form of VEC.PLOT.FUNCTION. It returns the created item id of the plotted curve.
VEC.PLOT.HISTCommandVector plot statementsAlias of VEC.PLOT.HISTOGRAM.
VEC.PLOT.HISTOGRAMCommandVector plot statementsBuilds a histogram from a numeric list. If xMin=xMax the range is auto-estimated; if yMax<=0 the histogram height is auto-scaled. Alias: VEC.PLOT.HIST.
VEC.PLOT.LABELSCommandVector plot statementsAdds title, X label and Y label to a plot rectangle. The Y label is rotated vertically.
VEC.PLOT.LEGENDCommandVector plot statementsDraws a small legend box. Each item uses color|label syntax; comma is also accepted as separator.
VEC.PLOT.PARAMETRICCommandVector plot statementsEvaluates a parametric curve using variable t and plots it in the selected rectangle. Useful for circles, spirals, Lissajous figures and many mathematical curves.
VEC.PLOT.PARAMETRIC_IDFunctionVector plot functionsFunction form of VEC.PLOT.PARAMETRIC. It returns the created item id of the plotted curve.
VEC.PLOT.POINTSCommandVector plot statementsAlias of VEC.PLOT.XY.
VEC.PLOT.SCATTERCommandVector plot statementsPlots a list of data-space points as vector point markers in the selected plot rectangle.
VEC.PLOT.TICKSCommandVector plot statementsAdds numeric tick labels around a VEC.PLOT.AXES rectangle. decimals=-1 uses compact general formatting.
VEC.PLOT.XYCommandVector plot statementsPlots a polyline from data-space points into the specified plot rectangle. Alias: VEC.PLOT.POINTS.
VEC.PLOT.XY_IDFunctionVector plot functionsFunction form of VEC.PLOT.XY. It plots the data polyline and returns the created item id.
VEC.PNGCommandVector export and capture statementsAlias of VEC.SAVE_PNG.
VEC.POINTCommandVector canvas statementsAdds a small circular point marker using the current pen color.
VEC.POINT_IDFunctionVector canvas functionsFunction form of VEC.POINT. It adds the point marker and returns its item id.
VEC.POLYGONCommandVector canvas statementsAdds a closed polygon using the current pen and brush.
VEC.POLYGON_IDFunctionVector canvas functionsFunction form of VEC.POLYGON. It returns the item id.
VEC.POLYLINECommandVector canvas statementsAdds an open polyline. The point list is a compact string using semicolon-separated x,y pairs.
VEC.POLYLINE_IDFunctionVector canvas functionsFunction form of VEC.POLYLINE. It returns the item id.
VEC.RECTCommandVector canvas statementsAdds a rectangle using the current pen and brush.
VEC.RECT_IDFunctionVector canvas functionsFunction form of VEC.RECT. It adds the rectangle and returns its item id.
VEC.SAVE_AVICommandVector export and capture statementsAlias of VEC.CAPTURE_AVI.
VEC.SAVE_FRAMECommandVector export and capture statementsCaptures the current animated canvas state to a PNG frame. With transparent=TRUE the background is transparent. Alias: VEC.FRAME_PNG.
VEC.SAVE_PNGCommandVector export and capture statementsRasterizes and saves the current vector canvas as a PNG preview.
VEC.SAVE_SVGCommandVector export and capture statementsExports the vector canvas to SVG. This keeps vector primitives scalable and is ideal for reports/documentation.
VEC.STACKFunctionVector canvas functionsAlias of VEC.CAPTURE_STACK.
VEC.SVGCommandVector export and capture statementsAlias of VEC.SAVE_SVG.
VEC.SYNCCommandVector canvas statementsProcesses pending Qt GUI events for a bounded time. Use it after heavy vector scene creation and before export/animation when a script builds many items continuously. maxMs is clamped to 1..250 ms. Alias: VEC.FLUSH.
VEC.TEXTCommandVector canvas statementsAdds a text item using the current pen color and current font.
VEC.TEXT_IDFunctionVector canvas functionsFunction form of VEC.TEXT. It adds the text and returns its item id.
VEC.TO_MATFunctionVector canvas functionsAlias of VEC.MAT.
VEC.ZCommandVector canvas statementsSets the default z-order for following vector items. Higher values are drawn above lower values.

VEC.ANIM.CIRCLE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.CIRCLE handle, itemId, centerX, centerY, radius, durationMs [, startDeg [, endDeg [, loops [, yoyo]]]]

Alias of VEC.ANIM.ORBIT.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
startDegOptional parameter. If omitted, the command uses its internal default.
endDegOptional parameter. If omitted, the command uses its internal default.
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.CIRCLE

VEC.ANIM.MOVE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.MOVE handle, itemId, x1, y1, x2, y2, durationMs [, loops [, yoyo]]

Animates the item position. loops=1 runs once; loops=0 loops forever; yoyo=TRUE reverses every other loop.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.MOVE v, ball, 40, 180, 600, 180, 2500, 0, TRUE

VEC.ANIM.OPACITY

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.OPACITY handle, itemId, o1, o2, durationMs [, loops [, yoyo]]

Animates item opacity between two values in range 0..1.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.OPACITY

VEC.ANIM.OPACITY_KEYFRAMES

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.OPACITY_KEYFRAMES handle, itemId, "timeMs,opacity;timeMs,opacity;..." [, loops]

Animates item opacity using absolute time/value keyframes. This is useful for discrete states: switches, traffic lights, phase indicators, etc. loops=0 loops forever.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.OPACITY_KEYFRAMES v, leverA, "0,1;5200,1;5201,0;10400,0", 0

VEC.ANIM.OPACITY_PATH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.OPACITY_PATH handle, itemId, keyframes [, loops]

Alias of VEC.ANIM.OPACITY_KEYFRAMES.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.OPACITY_PATH

VEC.ANIM.ORBIT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.ORBIT handle, itemId, centerX, centerY, radius, durationMs [, startDeg [, endDeg [, loops [, yoyo]]]]

Animates an item on a circular orbit around a center point. Alias: VEC.ANIM.CIRCLE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
startDegOptional parameter. If omitted, the command uses its internal default.
endDegOptional parameter. If omitted, the command uses its internal default.
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.ORBIT v, moon, 400, 260, 120, 3000, 0, 360, 0, FALSE

VEC.ANIM.PATH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.PATH handle, itemId, "x,y;x,y;...", durationMs [, loops [, yoyo]]

Animates an item along a polyline trajectory. Very useful for physics/mathematics demonstrations. Alias: VEC.ANIM.TRAJECTORY.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.PATH v, particle, "80,320;180,220;320,250;520,160", 4000, 0, TRUE

VEC.ANIM.ROTATE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.ROTATE handle, itemId, a1, a2, durationMs [, loops [, yoyo]]

Animates the item rotation in degrees.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.ROTATE

VEC.ANIM.ROTATE_PATH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.ROTATE_PATH handle, itemId, "a;a;a;...", durationMs [, loops [, yoyo]]

Animates item rotation through a list of angle keyframes. This is more useful than linear rotation for physics, because the angle can come from a numerical simulation. Alias: VEC.ANIM.ROTATION_PATH.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.ROTATE_PATH v, rod, angleList, 6000, 0, TRUE

VEC.ANIM.ROTATION_PATH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.ROTATION_PATH handle, itemId, angleList, durationMs [, loops [, yoyo]]

Alias of VEC.ANIM.ROTATE_PATH.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.ROTATION_PATH

VEC.ANIM.SCALE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.SCALE handle, itemId, s1, s2, durationMs [, loops [, yoyo]]

Animates uniform scale, useful for pulsating markers or attention cues.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.SCALE

VEC.ANIM.STATE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.STATE handle, itemId, keyframes [, loops]

Alias of VEC.ANIM.OPACITY_KEYFRAMES, intended for visibility/state timelines.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.STATE

VEC.ANIM.STOP

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.STOP handle [, itemId]

Stops animations. Omit itemId or pass 0 to stop all animations on the canvas.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
itemIdOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.STOP v

VEC.ANIM.TRAJECTORY

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.TRAJECTORY handle, itemId, "x,y;x,y;...", durationMs [, loops [, yoyo]]

Alias of VEC.ANIM.PATH.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.
yoyoOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.TRAJECTORY

VEC.ANIM.VISIBLE_TIMELINE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector animation statements   Namespace: VEC

VEC.ANIM.VISIBLE_TIMELINE handle, itemId, keyframes [, loops]

Alias of VEC.ANIM.OPACITY_KEYFRAMES.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
loopsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ANIM.VISIBLE_TIMELINE

VEC.ARROW

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.ARROW handle, x1, y1, x2, y2 [, headSize]

Adds a line with a simple arrow head, useful for annotations and motion/vector diagrams.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
headSizeOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ARROW v, 80, 420, 300, 360, 18

VEC.ARROW_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.ARROW_ID(handle, x1, y1, x2, y2 [, headSize])

Function form of VEC.ARROW. It returns the item id.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
headSizeOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.ARROW_ID(handle, x1, y1, x2, y2 [, headSize])

VEC.AXES

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.AXES handle [, originX [, originY [, tickStep [, color [, width]]]]]

Draws X/Y axes with optional ticks. This is intentionally simple and script-friendly.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
originXOptional parameter. If omitted, the command uses its internal default.
originYOptional parameter. If omitted, the command uses its internal default.
tickStepOptional parameter. If omitted, the command uses its internal default.
colorOptional plot/drawing color value.
widthOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.AXES v, 60, 420, 50, "#444444", 1.5

VEC.BATCH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.BATCH handle [, enabled]

Temporarily freezes viewport repaints/info-label updates while many vector items are created. Use VEC.BATCH v, TRUE before a heavy plot block and VEC.BATCH v, FALSE after it. Alias: VEC.FREEZE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
enabledBoolean switch: TRUE/1 enables the option, FALSE/0 disables it.

Minimal example

VEC.BATCH v, TRUE
' heavy plot commands...
VEC.BATCH v, FALSE
VEC.SYNC v, 40

VEC.BRUSH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.BRUSH handle [, color|TRANSPARENT]

Sets the fill brush for rectangles and ellipses. Use TRANSPARENT/NONE to draw outlines only.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
colorOptional plot/drawing color value.
TRANSPARENTOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.BRUSH v, "#ffeeaa"

VEC.CAPTURE_AVI

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.CAPTURE_AVI handle, path, frames [, fps [, transparent [, fourcc]]]

Captures the animated vector canvas directly to an AVI file. Default codec is MJPG; aliases: VEC.SAVE_AVI and VEC.EXPORT_AVI.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fpsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.
fourccOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.CAPTURE_AVI v, "out/orbit.avi", 180, 30, FALSE, "MJPG"

VEC.CAPTURE_FRAMES

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.CAPTURE_FRAMES handle, folder, prefix, frames [, delayMs [, transparent]]

Alias of VEC.CAPTURE_PNG.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
delayMsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.CAPTURE_FRAMES

VEC.CAPTURE_PNG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.CAPTURE_PNG handle, folder, prefix, frames [, delayMs [, transparent]]

Captures a sequence of PNG frames from the current canvas while active animations are running. Aliases: VEC.CAPTURE_FRAMES and VEC.EXPORT_FRAMES.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
delayMsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.CAPTURE_PNG v, "out/orbit_frames", "orbit", 90, 33, FALSE

VEC.CAPTURE_STACK

FUNCTIONVECBATCH-FRIENDLYSTACK / VIDEOVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.CAPTURE_STACK(handle, frames [, fps [, transparent]])

Captures the animated vector canvas into a stack/image-sequence object that can be passed to GUI.SHOW or saved by the normal image/stack pipeline. Alias: VEC.STACK.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fpsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

stack = VEC.CAPTURE_STACK(v, 120, 30, FALSE)
GUI.SHOW stack, "Vector animation stack"

VEC.CLEAR

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.CLEAR handle

Removes all vector items from the selected canvas without destroying the window.

Minimal example

VEC.CLEAR v

VEC.CLOSE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.CLOSE handle

Closes a vector canvas window.

Minimal example

VEC.CLOSE v

VEC.CREATE

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.CREATE(width, height [, title [, background]])

Creates an interactive vector canvas and returns a numeric handle. The canvas is a scriptable QGraphicsScene-based whiteboard that can be exported to SVG or rasterized back to a Mat.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
titleOptional GUI/DataPlot window title.
backgroundInitial canvas background value.

Minimal example

v = VEC.CREATE(800, 500, "Vector demo", "white")

VEC.ELLIPSE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.ELLIPSE handle, x, y, w, h

Adds an ellipse inscribed in the rectangle x,y,w,h using the current pen and brush.

Minimal example

VEC.ELLIPSE v, 260, 70, 160, 90

VEC.ELLIPSE_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.ELLIPSE_ID(handle, x, y, w, h)

Function form of VEC.ELLIPSE. It adds the ellipse and returns its item id.

Minimal example

ball = VEC.ELLIPSE_ID(v, 60, 180, 40, 40)

VEC.EXPORT_AVI

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.EXPORT_AVI handle, path, frames [, fps [, transparent [, fourcc]]]

Alias of VEC.CAPTURE_AVI.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fpsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.
fourccOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.EXPORT_AVI

VEC.EXPORT_FRAMES

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.EXPORT_FRAMES handle, folder, prefix, frames [, delayMs [, transparent]]

Alias of VEC.CAPTURE_PNG.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
delayMsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.EXPORT_FRAMES

VEC.FLUSH

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.FLUSH handle [, maxMs]

Alias of VEC.SYNC.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
maxMsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.FLUSH

VEC.FONT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.FONT handle [, family [, pointSize [, bold [, italic]]]]

Sets the current font used by VEC.TEXT.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
familyOptional parameter. If omitted, the command uses its internal default.
pointSizeOptional parameter. If omitted, the command uses its internal default.
boldOptional parameter. If omitted, the command uses its internal default.
italicOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.FONT v, "Arial", 18, TRUE, FALSE

VEC.FRAME

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.FRAME(handle [, transparent])

Alias of VEC.MAT, named for animated/capture workflows: returns the current canvas frame as Mat.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.FRAME(handle [, transparent])

VEC.FRAME_PNG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.FRAME_PNG handle, path [, transparent]

Alias of VEC.SAVE_FRAME.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.FRAME_PNG

VEC.FREEZE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.FREEZE handle [, enabled]

Alias of VEC.BATCH.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
enabledBoolean switch: TRUE/1 enables the option, FALSE/0 disables it.

Minimal example

VEC.FREEZE

VEC.GRID

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.GRID handle, step [, color [, width]]

Draws a lightweight grid as one vector item. It is useful as a plotting/geometry reference layer.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
colorOptional plot/drawing color value.
widthOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.GRID v, 50, "#dddddd", 1

VEC.IMAGE

STATEMENTVECBATCH-FRIENDLYIMAGEVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.IMAGE handle, image [, x [, y [, w [, h [, opacity]]]]]

Inserts the first frame of an image/stack into the vector canvas. If w and h are positive the image is scaled; opacity is 0..1.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
xOptional parameter. If omitted, the command uses its internal default.
yOptional parameter. If omitted, the command uses its internal default.
wOptional output width, or ROI width when part of x,y,w,h.
hOptional output height, or ROI height when part of x,y,w,h.
opacityOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.IMAGE v, img, 0, 0, 512, 512, 0.35

VEC.IMAGE_ID

FUNCTIONVECBATCH-FRIENDLYIMAGEVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.IMAGE_ID(handle, image [, x [, y [, w [, h [, opacity]]]]])

Function form of VEC.IMAGE. It adds the image layer and returns its item id.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
xOptional parameter. If omitted, the command uses its internal default.
yOptional parameter. If omitted, the command uses its internal default.
wOptional output width, or ROI width when part of x,y,w,h.
hOptional output height, or ROI height when part of x,y,w,h.
opacityOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.IMAGE_ID(handle, image [, x [, y [, w [, h [, opacity]]]]])

VEC.ITEM.CENTER_X

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.CENTER_X(handle, itemId)

Returns the current scene-center x coordinate of a vector item.

Minimal example

value = VEC.ITEM.CENTER_X(handle, itemId)

VEC.ITEM.CENTER_Y

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.CENTER_Y(handle, itemId)

Returns the current scene-center y coordinate of a vector item.

Minimal example

value = VEC.ITEM.CENTER_Y(handle, itemId)

VEC.ITEM.DRAGGABLE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.DRAGGABLE handle, itemId [, enabled]

Alias of VEC.ITEM.MOVABLE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
enabledBoolean switch: TRUE/1 enables the option, FALSE/0 disables it.

Minimal example

VEC.ITEM.DRAGGABLE

VEC.ITEM.MOVABLE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.MOVABLE handle, itemId [, enabled]

Makes an item draggable with the mouse inside the vector canvas. Movable items are also made selectable. Alias: VEC.ITEM.DRAGGABLE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
enabledBoolean switch: TRUE/1 enables the option, FALSE/0 disables it.

Minimal example

VEC.ITEM.MOVABLE v, chargeItem, TRUE

VEC.ITEM.MOVE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.MOVE handle, itemId, x, y

Alias of VEC.ITEM.POS.

Minimal example

VEC.ITEM.MOVE

VEC.ITEM.OPACITY

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.OPACITY handle, itemId, opacity

Sets opacity 0..1 for one existing item.

Minimal example

VEC.ITEM.OPACITY

VEC.ITEM.OPACITY_VALUE

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.OPACITY_VALUE(handle, itemId)

Returns the current opacity value of a vector item.

Minimal example

value = VEC.ITEM.OPACITY_VALUE(handle, itemId)

VEC.ITEM.ORIGIN

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.ORIGIN handle, itemId, x, y

Sets the local transform origin/pivot for rotation and scale. Alias: VEC.ITEM.PIVOT. This is important for physical systems such as pendulums, levers and rotating arms.

Minimal example

VEC.ITEM.ORIGIN v, rod, 0, 0

VEC.ITEM.PIVOT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.PIVOT handle, itemId, x, y

Alias of VEC.ITEM.ORIGIN.

Minimal example

VEC.ITEM.PIVOT

VEC.ITEM.POS

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.POS handle, itemId, x, y

Sets the position transform of an existing vector item. Alias: VEC.ITEM.MOVE.

Minimal example

VEC.ITEM.POS v, ball, 100, 160

VEC.ITEM.ROTATE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.ROTATE handle, itemId, angleDeg

Rotates an existing vector item around its local bounding-box center.

Minimal example

VEC.ITEM.ROTATE

VEC.ITEM.ROTATION

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.ROTATION(handle, itemId)

Returns the current rotation angle of a vector item in degrees.

Minimal example

value = VEC.ITEM.ROTATION(handle, itemId)

VEC.ITEM.SCALE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.SCALE handle, itemId, sx [, sy]

Scales an existing item around its local bounding-box center. If sy is omitted, sx is used for both axes.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
syOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.ITEM.SCALE

VEC.ITEM.SELECTABLE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.SELECTABLE handle, itemId [, enabled]

Enables or disables mouse selection for an existing vector item.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
enabledBoolean switch: TRUE/1 enables the option, FALSE/0 disables it.

Minimal example

VEC.ITEM.SELECTABLE v, labelItem, TRUE

VEC.ITEM.X

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.X(handle, itemId)

Returns the current x position transform of a vector item.

Minimal example

value = VEC.ITEM.X(handle, itemId)

VEC.ITEM.Y

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector item query functions   Namespace: VEC

VEC.ITEM.Y(handle, itemId)

Returns the current y position transform of a vector item.

Minimal example

value = VEC.ITEM.Y(handle, itemId)

VEC.ITEM.Z

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector item statements   Namespace: VEC

VEC.ITEM.Z handle, itemId, z

Changes the z-order of an existing item.

Minimal example

VEC.ITEM.Z

VEC.ITEM_COUNT

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.ITEM_COUNT(handle)

Returns the number of registered vector items in the canvas.

Minimal example

PRINT VEC.ITEM_COUNT(v)

VEC.LAST_ITEM

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.LAST_ITEM(handle)

Returns the numeric id of the last vector item created on the canvas. This id can be used by VEC.ITEM.* and VEC.ANIM.* commands.

Minimal example

id = VEC.LAST_ITEM(v)

VEC.LAYER

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector layer statements   Namespace: VEC

VEC.LAYER handle [, name]

Alias of VEC.LAYER.SELECT.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
nameOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.LAYER

VEC.LAYER.CLEAR

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector layer statements   Namespace: VEC

VEC.LAYER.CLEAR handle [, name]

Deletes all vector items assigned to the selected layer. Useful for interactive redraw loops where a dynamic overlay is recalculated.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
nameOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.LAYER.CLEAR v, "field"

VEC.LAYER.SELECT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector layer statements   Namespace: VEC

VEC.LAYER.SELECT handle [, name]

Selects the current drawing layer. New vector items are assigned to that layer. The default layer is named default.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
nameOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.LAYER.SELECT v, "field"

VEC.LAYER.SHOW

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector layer statements   Namespace: VEC

VEC.LAYER.SHOW handle, name [, visible]

Alias of VEC.LAYER.VISIBLE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
visibleOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.LAYER.SHOW

VEC.LAYER.VISIBLE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector layer statements   Namespace: VEC

VEC.LAYER.VISIBLE handle, name [, visible]

Shows or hides all items belonging to a layer. Alias: VEC.LAYER.SHOW.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
visibleOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.LAYER.VISIBLE v, "field", TRUE

VEC.LINE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.LINE handle, x1, y1, x2, y2

Adds a line using the current pen.

Minimal example

VEC.LINE v, 20, 20, 300, 120

VEC.LINE_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.LINE_ID(handle, x1, y1, x2, y2)

Function form of VEC.LINE. It adds the line and returns its item id.

Minimal example

line = VEC.LINE_ID(v, 20, 20, 200, 120)

VEC.MAT

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.MAT(handle [, transparent])

Rasterizes the current vector canvas and returns it as an image/Mat value. By default it produces a normal 3-channel BGR Mat; with transparent=TRUE it keeps an alpha channel and makes the background transparent.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

overlay = VEC.MAT(v, TRUE)
GUI.SHOW overlay, "Vector overlay"

VEC.NEW

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.NEW(width, height [, title [, background]])

Alias of VEC.CREATE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
titleOptional GUI/DataPlot window title.
backgroundInitial canvas background value.

Minimal example

value = VEC.NEW(width, height [, title [, background]])

VEC.OPACITY

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.OPACITY handle, opacity

Sets the default opacity for following vector items. Opacity is 0..1.

Minimal example

VEC.OPACITY v, 0.65

VEC.PEN

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.PEN handle, color [, width [, style]]

Sets the current stroke color, width and style for following vector primitives. Colors are Qt names or #RRGGBB. Styles: SOLID, DASH, DOT, DASHDOT, DASHDOTDOT, NONE.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
widthOptional parameter. If omitted, the command uses its internal default.
styleOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PEN v, "red", 2, "SOLID"

VEC.PLOT.AREA

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.AREA handle, left, top, width, height, "x,y;x,y;...", xMin, xMax, yMin, yMax [, baseline]

Draws a filled area under a data polyline down to a baseline. Use VEC.BRUSH before the command to choose the fill color; alias: VEC.PLOT.FILL.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
baselineOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.BRUSH v, "#ddeeff"
VEC.PLOT.AREA v, 70, 55, 620, 300, "0,0;1,2;2,1;3,3", 0, 3, 0, 4, 0

VEC.PLOT.AXES

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.AXES handle, left, top, width, height, xMin, xMax, yMin, yMax [, xTicks [, yTicks [, grid]]]]

Draws a scientific plot frame in the given rectangle, including border, tick marks, optional grid and zero axes when visible in range.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
xTicksOptional parameter. If omitted, the command uses its internal default.
yTicksOptional parameter. If omitted, the command uses its internal default.
gridOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.AXES v, 60, 50, 520, 300, -6.28, 6.28, -1.5, 1.5, 8, 6, TRUE

VEC.PLOT.BAR

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.BAR handle, left, top, width, height, values, yMin, yMax [, barFill]

Alias of VEC.PLOT.BARS.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
barFillOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.BAR

VEC.PLOT.BARS

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.BARS handle, left, top, width, height, "v1;v2;...", yMin, yMax [, barFill]

Draws a categorical bar plot from a numeric list. The current brush fills the bars, and the current pen outlines them.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
barFillOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.BRUSH v, "#88ccee"
VEC.PLOT.BARS v, 80, 80, 280, 220, "2;5;3;7;4", 0, 8, 0.75

VEC.PLOT.FILL

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.FILL handle, left, top, width, height, points, xMin, xMax, yMin, yMax [, baseline]

Alias of VEC.PLOT.AREA.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
baselineOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.FILL

VEC.PLOT.FUNCTION

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.FUNCTION handle, left, top, width, height, expression, xMin, xMax [, samples [, yMin [, yMax [, autoScale]]]]

Evaluates a function of x and plots it as a polyline. The expression can use normal math functions such as SIN, COS, EXP, SQRT, etc. When autoScale is TRUE the y range is estimated from the sampled values.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
samplesOptional parameter. If omitted, the command uses its internal default.
yMinOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
autoScaleOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.FUNCTION v, 60, 50, 520, 300, "MATH.SIN(x)", -6.28, 6.28, 500, -1.2, 1.2, FALSE

VEC.PLOT.FUNCTION_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector plot functions   Namespace: VEC

VEC.PLOT.FUNCTION_ID(handle, left, top, width, height, expression, xMin, xMax [, samples [, yMin [, yMax [, autoScale]]]])

Function form of VEC.PLOT.FUNCTION. It returns the created item id of the plotted curve.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
samplesOptional parameter. If omitted, the command uses its internal default.
yMinOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
autoScaleOptional parameter. If omitted, the command uses its internal default.

Minimal example

curve = VEC.PLOT.FUNCTION_ID(v, 60, 50, 520, 300, "MATH.SIN(x)", -6.28, 6.28, 500, -1.2, 1.2, FALSE)

VEC.PLOT.HIST

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.HIST handle, left, top, width, height, values [, bins [, xMin [, xMax [, yMax [, barFill]]]]]

Alias of VEC.PLOT.HISTOGRAM.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
binsNumber of histogram bins.
xMinOptional parameter. If omitted, the command uses its internal default.
xMaxOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
barFillOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.HIST

VEC.PLOT.HISTOGRAM

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.HISTOGRAM handle, left, top, width, height, "v1;v2;..." [, bins [, xMin [, xMax [, yMax [, barFill]]]]]

Builds a histogram from a numeric list. If xMin=xMax the range is auto-estimated; if yMax<=0 the histogram height is auto-scaled. Alias: VEC.PLOT.HIST.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
binsNumber of histogram bins.
xMinOptional parameter. If omitted, the command uses its internal default.
xMaxOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
barFillOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.HISTOGRAM v, 410, 80, 280, 220, "0.1;0.4;0.5;1.2;1.3;1.8", 8, 0, 2, 0, 0.9

VEC.PLOT.LABELS

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.LABELS handle, left, top, width, height [, title [, xLabel [, yLabel [, fontSize]]]]

Adds title, X label and Y label to a plot rectangle. The Y label is rotated vertically.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
titleOptional GUI/DataPlot window title.
xLabelOptional parameter. If omitted, the command uses its internal default.
yLabelOptional parameter. If omitted, the command uses its internal default.
fontSizeOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.LABELS v, 70, 55, 620, 300, "Oscillazioni", "x", "ampiezza", 12

VEC.PLOT.LEGEND

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.LEGEND handle, left, top, "color|label;color|label;..." [, fontSize [, lineLength [, lineStep]]]

Draws a small legend box. Each item uses color|label syntax; comma is also accepted as separator.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fontSizeOptional parameter. If omitted, the command uses its internal default.
lineLengthOptional parameter. If omitted, the command uses its internal default.
lineStepOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.LEGEND v, 500, 80, "#0033aa|MATH.SIN(x);#cc0000|0.5*MATH.COS(2*x)", 10

VEC.PLOT.PARAMETRIC

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.PARAMETRIC handle, left, top, width, height, exprX, exprY, tMin, tMax [, samples [, xMin [, xMax [, yMin [, yMax [, autoScale]]]]]]

Evaluates a parametric curve using variable t and plots it in the selected rectangle. Useful for circles, spirals, Lissajous figures and many mathematical curves.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
samplesOptional parameter. If omitted, the command uses its internal default.
xMinOptional parameter. If omitted, the command uses its internal default.
xMaxOptional parameter. If omitted, the command uses its internal default.
yMinOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
autoScaleOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.PARAMETRIC v, 60, 50, 520, 300, "MATH.COS(t)", "MATH.SIN(t)", 0, 6.28318, 600, -1.2, 1.2, -1.2, 1.2, FALSE

VEC.PLOT.PARAMETRIC_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector plot functions   Namespace: VEC

VEC.PLOT.PARAMETRIC_ID(handle, left, top, width, height, exprX, exprY, tMin, tMax [, samples [, xMin [, xMax [, yMin [, yMax [, autoScale]]]]]])

Function form of VEC.PLOT.PARAMETRIC. It returns the created item id of the plotted curve.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
samplesOptional parameter. If omitted, the command uses its internal default.
xMinOptional parameter. If omitted, the command uses its internal default.
xMaxOptional parameter. If omitted, the command uses its internal default.
yMinOptional parameter. If omitted, the command uses its internal default.
yMaxOptional parameter. If omitted, the command uses its internal default.
autoScaleOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.PLOT.PARAMETRIC_ID(handle, left, top, width, height, exprX, exprY, tMin, tMax [, samples [, xMin [, xMax [, yMin [, yMax [, autoScale]]]]]])

VEC.PLOT.POINTS

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.POINTS handle, left, top, width, height, "x,y;x,y;...", xMin, xMax, yMin, yMax [, closed]

Alias of VEC.PLOT.XY.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
closedOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.POINTS

VEC.PLOT.SCATTER

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.SCATTER handle, left, top, width, height, "x,y;x,y;...", xMin, xMax, yMin, yMax [, radius]

Plots a list of data-space points as vector point markers in the selected plot rectangle.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
radiusKernel radius or neighborhood radius used by the filter.

Minimal example

VEC.PLOT.SCATTER v, 70, 55, 620, 300, "-3,-1;-1,0;0,1;2,0.2;3,1.3", -3, 3, -2, 2, 4

VEC.PLOT.TICKS

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.TICKS handle, left, top, width, height, xMin, xMax, yMin, yMax [, xTicks [, yTicks [, decimals [, fontSize]]]]

Adds numeric tick labels around a VEC.PLOT.AXES rectangle. decimals=-1 uses compact general formatting.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
xTicksOptional parameter. If omitted, the command uses its internal default.
yTicksOptional parameter. If omitted, the command uses its internal default.
decimalsOptional parameter. If omitted, the command uses its internal default.
fontSizeOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.TICKS v, 70, 55, 620, 300, -6.28, 6.28, -1.5, 1.5, 8, 6, 2, 9

VEC.PLOT.XY

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector plot statements   Namespace: VEC

VEC.PLOT.XY handle, left, top, width, height, "x,y;x,y;...", xMin, xMax, yMin, yMax [, closed]

Plots a polyline from data-space points into the specified plot rectangle. Alias: VEC.PLOT.POINTS.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
closedOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.PLOT.XY v, 60, 50, 520, 300, "-3,-1;-1,0;0,1;2,0.2;3,1.3", -3, 3, -2, 2, FALSE

VEC.PLOT.XY_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector plot functions   Namespace: VEC

VEC.PLOT.XY_ID(handle, left, top, width, height, points, xMin, xMax, yMin, yMax [, closed])

Function form of VEC.PLOT.XY. It plots the data polyline and returns the created item id.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
closedOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.PLOT.XY_ID(handle, left, top, width, height, points, xMin, xMax, yMin, yMax [, closed])

VEC.PNG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.PNG handle, path

Alias of VEC.SAVE_PNG.

Minimal example

VEC.PNG

VEC.POINT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.POINT handle, x, y [, radius]

Adds a small circular point marker using the current pen color.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
radiusKernel radius or neighborhood radius used by the filter.

Minimal example

VEC.POINT v, 250, 120, 4

VEC.POINT_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.POINT_ID(handle, x, y [, radius])

Function form of VEC.POINT. It adds the point marker and returns its item id.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
radiusKernel radius or neighborhood radius used by the filter.

Minimal example

value = VEC.POINT_ID(handle, x, y [, radius])

VEC.POLYGON

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.POLYGON handle, "x,y;x,y;..."

Adds a closed polygon using the current pen and brush.

Minimal example

VEC.POLYGON v, "400,180;520,140;560,260;430,300"

VEC.POLYGON_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.POLYGON_ID(handle, points)

Function form of VEC.POLYGON. It returns the item id.

Minimal example

value = VEC.POLYGON_ID(handle, points)

VEC.POLYLINE

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.POLYLINE handle, "x,y;x,y;..."

Adds an open polyline. The point list is a compact string using semicolon-separated x,y pairs.

Minimal example

VEC.POLYLINE v, "20,240;120,180;220,210;340,110"

VEC.POLYLINE_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.POLYLINE_ID(handle, points)

Function form of VEC.POLYLINE. It returns the item id.

Minimal example

value = VEC.POLYLINE_ID(handle, points)

VEC.RECT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.RECT handle, x, y, w, h

Adds a rectangle using the current pen and brush.

Minimal example

VEC.RECT v, 40, 70, 180, 90

VEC.RECT_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.RECT_ID(handle, x, y, w, h)

Function form of VEC.RECT. It adds the rectangle and returns its item id.

Minimal example

value = VEC.RECT_ID(handle, x, y, w, h)

VEC.SAVE_AVI

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.SAVE_AVI handle, path, frames [, fps [, transparent [, fourcc]]]

Alias of VEC.CAPTURE_AVI.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fpsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.
fourccOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.SAVE_AVI

VEC.SAVE_FRAME

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.SAVE_FRAME handle, path [, transparent]

Captures the current animated canvas state to a PNG frame. With transparent=TRUE the background is transparent. Alias: VEC.FRAME_PNG.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.SAVE_FRAME v, "out/frame_00000.png", TRUE

VEC.SAVE_PNG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.SAVE_PNG handle, path

Rasterizes and saves the current vector canvas as a PNG preview.

Minimal example

VEC.SAVE_PNG v, "out/vector_demo.png"

VEC.SAVE_SVG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.SAVE_SVG handle, path

Exports the vector canvas to SVG. This keeps vector primitives scalable and is ideal for reports/documentation.

Minimal example

VEC.SAVE_SVG v, "out/vector_demo.svg"

VEC.STACK

FUNCTIONVECBATCH-FRIENDLYSTACK / VIDEOVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.STACK(handle, frames [, fps [, transparent]])

Alias of VEC.CAPTURE_STACK.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
fpsOptional parameter. If omitted, the command uses its internal default.
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.STACK(handle, frames [, fps [, transparent]])

VEC.SVG

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector export and capture statements   Namespace: VEC

VEC.SVG handle, path

Alias of VEC.SAVE_SVG.

Minimal example

VEC.SVG

VEC.SYNC

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.SYNC handle [, maxMs]

Processes pending Qt GUI events for a bounded time. Use it after heavy vector scene creation and before export/animation when a script builds many items continuously. maxMs is clamped to 1..250 ms. Alias: VEC.FLUSH.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
maxMsOptional parameter. If omitted, the command uses its internal default.

Minimal example

VEC.SYNC v, 50

VEC.TEXT

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.TEXT handle, x, y, text

Adds a text item using the current pen color and current font.

Minimal example

VEC.TEXT v, 50, 40, "cvBasic VEC canvas"

VEC.TEXT_ID

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.TEXT_ID(handle, x, y, text)

Function form of VEC.TEXT. It adds the text and returns its item id.

Minimal example

value = VEC.TEXT_ID(handle, x, y, text)

VEC.TO_MAT

FUNCTIONVECBATCH-FRIENDLYVECTOR
Kind: Function   Category: Vector canvas functions   Namespace: VEC

VEC.TO_MAT(handle [, transparent])

Alias of VEC.MAT.

Optional parameters

Parameters enclosed in [...] may be omitted. Nested brackets mean that the later parameter is available only when the previous optional level is also supplied.

ParameterMeaning
transparentOptional parameter. If omitted, the command uses its internal default.

Minimal example

value = VEC.TO_MAT(handle [, transparent])

VEC.Z

STATEMENTVECBATCH-FRIENDLYVECTOR
Kind: Command   Category: Vector canvas statements   Namespace: VEC

VEC.Z handle, z

Sets the default z-order for following vector items. Higher values are drawn above lower values.

Minimal example

VEC.Z v, 10