Nevron .NET Vision
Nevron.GraphicsCore Namespace / NProjection Class / YDepth Property
Example


In This Topic
    YDepth Property
    In This Topic
    The offset of the 3D objects along the Y axis depending on their Z depth when the projection is ProjectionType.Orthogonal.
    Syntax
    'Declaration
     
    
    <System.ComponentModel.CategoryAttribute("General")>
    <System.ComponentModel.DescriptionAttribute("The offset of the 3D objects along the Y axis depending on their Z depth when the projection is ProjectionType.Orthogonal.")>
    <System.ComponentModel.DefaultValueAttribute(0.25)>
    <System.Xml.Serialization.XmlAttributeAttribute()>
    Public Property YDepth As System.Single
    'Usage
     
    
    Dim instance As NProjection
    Dim value As System.Single
     
    instance.YDepth = value
     
    value = instance.YDepth
    [System.ComponentModel.Category("General")]
    [System.ComponentModel.Description("The offset of the 3D objects along the Y axis depending on their Z depth when the projection is ProjectionType.Orthogonal.")]
    [System.ComponentModel.DefaultValue(0.25)]
    [System.Xml.Serialization.XmlAttribute()]
    public System.float YDepth {get; set;}
    Remarks
    This property has effect only when the projection type is ProjectionType.Orthogonal. When you use the standard 2D projection the Z coordinate does not influence the projected coordinates, because the depth is not taken into account. To create a 2 and a half projection for example you'll need a projection that uses the Z coordinate to generate a positive or negative offset along the X and Y axis of the viewport depending on the Z depth of the object so that you can distingues object with different Z values. The default value of this property is 0.
    Example
    The following example creates a 2D Half Orthogonal projection:
    Dim chartView As NView = (CType(NChartControl.Charts(0), NChart)).View 
    chartView.Projection = ProjectionType.Orthogonal
    chartView.XDepth = 0.5f
    chartView.YDepth = 0.5f
    NView chartView = ((NChart)NChartControl.Charts[0]).View;
    chartView.Projection = ProjectionType.Orthogonal;
    chartView.XDepth = 0.5f;
    chartView.YDepth = 0.5f;
    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