This document is archived and information here might be outdated.  Recommended version.


IGlobeDisplayLayers.SetLayerShadingMode Method (ArcObjects .NET 10.5 SDK)
ArcObjects Library Reference (GlobeCore)  

IGlobeDisplayLayers.SetLayerShadingMode Method

Indicates if the layer is smoothly shaded.

[Visual Basic .NET]
Public Sub SetLayerShadingMode ( _
    ByVal pLayer As ILayer, _
    ByVal isSmooth As Boolean _
)
[C#]
public void SetLayerShadingMode (
    ILayer pLayer,
    bool isSmooth
);
[C++]
HRESULT SetLayerShadingMode(
  ILayer* pLayer,
  VARIANT_BOOL isSmooth
);
[C++]

Parameters pLayer [in]
pLayer is a parameter of type ILayer isSmooth [in] isSmooth is a parameter of type VARIANT_BOOL

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

Use this method to set the shading mode for a layer.

Note that if you add a layer to globe via code and want the shading mode to be persisted when the globe document is saved then you should explicitly add the I3DProperties extension to your layer as follows:

 

ESRI.ArcGIS.Analyst3D.I3DProperties p3DProperties;
p3DProperties=new Feature3DPropertiesClass();
ESRI.ArcGIS.Carto.ILayerExtensions layerExtension=ftrLayer as ESRI.ArcGIS.Carto.ILayerExtensions;
layerExtension.AddExtension(p3DProperties);
           
//Now set the layer shading

glbDisplayLayers.SetLayerShadingMode(ftrLayer as ESRI.ArcGIS.Carto.ILayer, true);
glbDisplayLayers.RefreshLayer(ftrLayer as ESRI.ArcGIS.Carto.ILayer);

See Also

IGlobeDisplayLayers Interface