Xceed Chart for WinForms v4.4 Documentation
Projection Property
Example 


Xceed.Chart.Standard.v4.4 Assembly > Xceed.Chart.Standard Namespace > View Class : Projection Property
Controls the projection type of the camera. Can be ProjectionType.Orthogonal or ProjectionType.Perspective.
Syntax
'Declaration
 
<DefaultValueAttribute()>

<CategoryAttribute("General")>

<DescriptionAttribute("Controls the projection type of the camera. Can be ProjectionType.Orthogonal or ProjectionType.Perspective.")>

Public Property Projection As ProjectionType
'Usage
 
Dim instance As View

Dim value As ProjectionType

 

instance.Projection = value

 

value = instance.Projection
[DefaultValue()]

[Category("General")]

[Description("Controls the projection type of the camera. Can be ProjectionType.Orthogonal or ProjectionType.Perspective.")]

public ProjectionType Projection {get; set;}
Remarks
Perspective projection is more suitable for 3D charts, because it gives you a perception of depth. In this mode you can also control the PerspectiveAngle parameter. If you want to display 2D charts you must switch to orthogonal projection which is better for analytical charts like stock for example. In Orthogonal projection you can modify the XDepth and YDepth parameters that allow you to achieve two and a half projection, which is also widely used.
Example
The following example modifies the projection applied on the chart camera:
Dim chartView As View = (CType(ChartControl.Charts(0), Chart)).View 

chartView.Projection = ProjectionType.Orthogonal

chartView.XDepth = 0.4f

chartView.YDepth = 0.4f
View chartView = ((NChart)NChartControl.Charts[0]).View;

chartView.Projection = ProjectionType.Orthogonal;

chartView.XDepth = 0.4f;

chartView.YDepth = 0.4f;
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

View Class
View Members