'...
'Create an instance of ImageElement class
Dim imgElem As Neodynamic.SDK.ImageElement
imgElem = Neodynamic.SDK.ImageElement.FromUrl("~/images/night.jpg")
'Create an instance of PerspectiveReflection class
Dim reflection As New Neodynamic.SDK.PerspectiveReflection()
reflection.Angle = 270;
reflection.Opacity = 50;
reflection.Length = 50;
reflection.WidthPercentage = 150;
'Apply the action on the ImageElement
imgElem.Actions.Add(reflection)
'Add the ImageElement to the Elements collection of the ImageDraw control
Me.ImageDraw1.Elements.Add(imgElem)
'...
//...
//Create an instance of ImageElement class
Neodynamic.SDK.ImageElement imgElem = Neodynamic.SDK.ImageElement.FromUrl("~/images/night.jpg");
//Create an instance of PerspectiveReflection class
Neodynamic.SDK.PerspectiveReflection reflection = new Neodynamic.SDK.PerspectiveReflection();
reflection.Angle = 270;
reflection.Opacity = 50;
reflection.Length = 50;
reflection.WidthPercentage = 150;
//Apply the action on the ImageElement
imgElem.Actions.Add(reflection);
//Add the ImageElement to the Elements collection of the ImageDraw control
this.ImageDraw1.Elements.Add(imgElem);
//...
...
<neoimg:imagedraw id="ImageDraw1" runat="server">
<Canvas AutoSize="True" />
<Elements>
<neoimg:ImageElement Source="File" SourceFile="~/images/night.jpg">
<Actions>
<neoimg:PerspectiveReflection Angle="270" Length="50" Opacity="50" WidthPercentage="150" />
</Actions>
</neoimg:ImageElement>
</Elements>
</neoimg:imagedraw>
...
PerspectiveReflection
Represented by
Neodynamic.SDK.PerspectiveReflection class.
This action adds perspective reflection to an
Element.
ImageDraw makes it easy to apply perspective reflection to any Element allowing you to specify similar settings as PrespectiveShadow action.
In the following example we have an
ImageElement on the
Canvas and a simple
PerspectiveReflection action is applied on the
ImageElement.
ImageElement before the action is applied. |
ImageElement with PerspectiveReflection action applied on it. |