Exemplo n.º 1
0
            /// <summary>
            /// The constructor.
            /// </summary>
            /// <param name="scope">The associated shape edit scope.</param>
            /// <param name="item">The current styled item.</param>
            public IFCMaterialStack(IFCImportShapeEditScope scope, IFCStyledItem styledItem, IFCPresentationLayerAssignment layerAssignment)
            {
                m_Scope = scope;
                if (styledItem != null)
                {
                    m_MaterialElementId = styledItem.GetMaterialElementId(scope);
                }
                else if (layerAssignment != null)
                {
                    m_MaterialElementId = layerAssignment.GetMaterialElementId(scope);
                }

                if (m_MaterialElementId != ElementId.InvalidElementId)
                {
                    m_Scope.PushMaterialId(m_MaterialElementId);
                }
            }
            /// <summary>
            /// The constructor.
            /// </summary>
            /// <param name="scope">The associated shape edit scope.</param>
            /// <param name="item">The current styled item.</param>
            public IFCMaterialStack(IFCImportShapeEditScope scope, IFCStyledItem styledItem, IFCPresentationLayerAssignment layerAssignment)
            {
                m_Scope = scope;
                if (styledItem != null)
                    m_MaterialElementId = styledItem.GetMaterialElementId(scope);
                else if (layerAssignment != null)
                    m_MaterialElementId = layerAssignment.GetMaterialElementId(scope);

                if (m_MaterialElementId != ElementId.InvalidElementId)
                    m_Scope.PushMaterialId(m_MaterialElementId);
            }