Mask.targetSpace

11 views
Skip to first unread message

Gemma Stekelenburg

unread,
May 23, 2018, 9:36:16 AM5/23/18
to StageXL
The toolkit for Dart uses Mask.targetSpace. This is depricated. What should I use to replace this.
"var mask = new Mask.shape(mask_shape)..targetSpace = this;"

Bernhard Pichler

unread,
May 24, 2018, 1:05:48 AM5/24/18
to Gemma Stekelenburg, StageXL
Hi,

I think this feature was removed quite some time ago. You can replace it with two options, depending on your use case.

You can use the Mask.relativeToParent flag which indicates if the Mask is relative to the display object where it is applied to, or relative to the parent of this DisplayObject.

Or you can use the Mask.transformationMatrix where you can set a 2D transformation Matrix. You can calculate this matrix on your own, or use the helper method of DisplayObject which is called getTransformationMatrix.
Matrix getTransformationMatrix(DisplayObject targetSpace)
https://github.com/bp74/StageXL/blob/master/lib/src/display/display_object.dart#L654

Hope this helps!
Bernhard






Gemma Stekelenburg <gemma.ste...@gmail.com> schrieb am Mi., 23. Mai 2018 um 15:36 Uhr:
The toolkit for Dart uses Mask.targetSpace. This is depricated. What should I use to replace this.
"var mask = new Mask.shape(mask_shape)..targetSpace = this;"

--
You received this message because you are subscribed to the Google Groups "StageXL" group.
Visit this group at https://groups.google.com/group/stagexl.
To view this discussion on the web visit https://groups.google.com/d/msgid/stagexl/526873a9-50b4-435a-853b-a6c9601dd49a%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages