// applies to TIN layers only
var nodeRendererDef = new TinNodeRendererDefinition();
nodeRendererDef.Description = "Nodes";
nodeRendererDef.Label = "Nodes";
nodeRendererDef.SymbolTemplate = nodeSymbol.MakeSymbolReference();
var tinLayer = MapView.Active.Map.GetLayersAsFlattenedList().OfType<TinLayer>().FirstOrDefault();
if (tinLayer == null)
return;
if (tinLayer.CanCreateRenderer(nodeRendererDef))
{
CIMTinRenderer renderer = tinLayer.CreateRenderer(nodeRendererDef);
if (tinLayer.CanSetRenderer(renderer, SurfaceRendererTarget.Points))
tinLayer.SetRenderer(renderer, SurfaceRendererTarget.Points);
}