VS:Stipple: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(No difference)
|
Revision as of 20:05, 13 August 2008
.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix
Description
Creates a group of stipple shapes and returns the handle to the group.
The illustrations below show the same set of stipple shapes drawn with clipToProfile set to 0, 1, and 2 from left to right:
The shapeType parameter is a code of which shape to be used:
- 2 - line
- 3 - rect
- 4 - oval
- 5 - poly
In the case of a poly, you merge the shapeType with the number of edges of the polygons you want to be created by the following formula:
shapeType = numEdges * 10 + 5
so when you specify for example 125 as ShapeType that means 5- polygon with 12 edges.
FUNCTION Stipple(
hProfileObject :HANDLE;
shapeType :INTEGER;
density :INTEGER;
clipToProfile :INTEGER;
minSize :REAL;
maxSize :REAL;
minAspectRatio :REAL;
maxAspectRatio :REAL;
randomRotate :BOOLEAN) :HANDLE;
def vs.Stipple(hProfileObject, shapeType, density, clipToProfile, minSize, maxSize, minAspectRatio, maxAspectRatio, randomRotate): return HANDLE
Parameters
hProfileObject HANDLE shapeType INTEGER density INTEGER clipToProfile INTEGER minSize REAL maxSize REAL minAspectRatio REAL maxAspectRatio REAL randomRotate BOOLEAN
Example
PROCEDURE Example; VAR hProfileObject :HANDLE; shapeType :INTEGER; density :INTEGER; clipToProfile :INTEGER; minSize :REAL; maxSize :REAL; minAspectRatio :REAL; maxAspectRatio :REAL; randomRotate :BOOLEAN; h :HANDLE; BEGIN CallTool(-204); hProfileObject := FSActLayer; shapeType := 5; density := 50; clipToProfile := 2; minSize := 1; maxSize := 5; minAspectRatio := 1; maxAspectRatio := 2; randomRotate := true; h := Stipple(hProfileObject, shapeType, density, clipToProfile, minSize, maxSize, minAspectRatio, maxAspectRatio, randomRotate); END; Run(Example);
Version
Availability: from All Versions
This is drop-in function.