Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Media3D / EmissiveMaterial.cs / 1 / EmissiveMaterial.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: 3D emissive material // // See spec at *** FILL IN LATER *** // //--------------------------------------------------------------------------- using System; using System.Diagnostics; using System.Runtime.InteropServices; using System.Windows.Markup; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using MS.Internal; namespace System.Windows.Media.Media3D { ////// EmissiveMaterial allows a 2d brush to be used on a 3d model that has been lit /// as if it were emitting light equal to the color of the brush /// public sealed partial class EmissiveMaterial : Material { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Constructs a EmissiveMaterial /// public EmissiveMaterial() { } ////// Constructor that sets the Brush property to "brush" /// /// The new material's brush public EmissiveMaterial(Brush brush) { Brush = brush; } #endregion Constructors internal override bool PreCompute() { _requiresRealization = Material.PreCompute(Brush); return _requiresRealization; } internal override void UpdateRealizations( RealizationContext ctx, ref Rect bounds ) { Debug.Assert(_requiresRealization); Material.UpdateRealizations(Brush, ctx, ref bounds); } internal override bool RequiresRealization { get { return _requiresRealization; } } //------------------------------------------------------ // // Private Fields // //----------------------------------------------------- #region Private Fields private bool _requiresRealization = false; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: 3D emissive material // // See spec at *** FILL IN LATER *** // //--------------------------------------------------------------------------- using System; using System.Diagnostics; using System.Runtime.InteropServices; using System.Windows.Markup; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using MS.Internal; namespace System.Windows.Media.Media3D { ////// EmissiveMaterial allows a 2d brush to be used on a 3d model that has been lit /// as if it were emitting light equal to the color of the brush /// public sealed partial class EmissiveMaterial : Material { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Constructs a EmissiveMaterial /// public EmissiveMaterial() { } ////// Constructor that sets the Brush property to "brush" /// /// The new material's brush public EmissiveMaterial(Brush brush) { Brush = brush; } #endregion Constructors internal override bool PreCompute() { _requiresRealization = Material.PreCompute(Brush); return _requiresRealization; } internal override void UpdateRealizations( RealizationContext ctx, ref Rect bounds ) { Debug.Assert(_requiresRealization); Material.UpdateRealizations(Brush, ctx, ref bounds); } internal override bool RequiresRealization { get { return _requiresRealization; } } //------------------------------------------------------ // // Private Fields // //----------------------------------------------------- #region Private Fields private bool _requiresRealization = false; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- FileFormatException.cs
- ImportedPolicyConversionContext.cs
- XmlBinaryWriter.cs
- StructuredTypeInfo.cs
- TextBoxAutomationPeer.cs
- ContextMenuStripActionList.cs
- IgnoreFileBuildProvider.cs
- EventBuilder.cs
- ToolStripItem.cs
- AsyncContentLoadedEventArgs.cs
- AnchoredBlock.cs
- XmlQualifiedName.cs
- HtmlSelect.cs
- ProcessHostConfigUtils.cs
- SafeRegistryHandle.cs
- ObjectStorage.cs
- CodeArgumentReferenceExpression.cs
- PropertyCollection.cs
- ListViewGroup.cs
- XmlUrlResolver.cs
- ConfigurationErrorsException.cs
- WebPartDisplayModeCancelEventArgs.cs
- odbcmetadatacolumnnames.cs
- WeakEventTable.cs
- DataRelationCollection.cs
- Attributes.cs
- ProxyHwnd.cs
- StartUpEventArgs.cs
- ContainerControlDesigner.cs
- MetabaseServerConfig.cs
- DbProviderManifest.cs
- AdCreatedEventArgs.cs
- KeySpline.cs
- XmlSchemaComplexContent.cs
- SizeFConverter.cs
- ContentHostHelper.cs
- BinarySerializer.cs
- HeaderUtility.cs
- SecurityProtocol.cs
- DesigntimeLicenseContext.cs
- Trace.cs
- ScriptResourceAttribute.cs
- Convert.cs
- AdjustableArrowCap.cs
- ChameleonKey.cs
- CodeAttachEventStatement.cs
- AtomServiceDocumentSerializer.cs
- EntitySqlQueryCacheEntry.cs
- TraceSection.cs
- TdsParserStaticMethods.cs
- SelectionProcessor.cs
- CLRBindingWorker.cs
- MsmqException.cs
- AdditionalEntityFunctions.cs
- DbProviderFactories.cs
- BindingExpression.cs
- SemanticResultKey.cs
- BamlStream.cs
- DataPagerFieldCommandEventArgs.cs
- TreeView.cs
- SiblingIterators.cs
- FileStream.cs
- Size.cs
- ControlBuilder.cs
- ApplicationInfo.cs
- XmlSchemaComplexContentExtension.cs
- CodeDelegateInvokeExpression.cs
- StartUpEventArgs.cs
- TemplateDefinition.cs
- AsymmetricAlgorithm.cs
- WebPartUtil.cs
- ConfigurationElementProperty.cs
- TreeNodeBinding.cs
- ExceptionHandler.cs
- StreamWriter.cs
- Application.cs
- FontResourceCache.cs
- ComPersistableTypeElement.cs
- MarginCollapsingState.cs
- SystemDiagnosticsSection.cs
- SafeFileHandle.cs
- SerialErrors.cs
- LiteralLink.cs
- ObjectQueryState.cs
- SqlXml.cs
- HttpListenerContext.cs
- UriParserTemplates.cs
- SectionInput.cs
- XmlException.cs
- NativeActivityMetadata.cs
- ActiveXContainer.cs
- PrePrepareMethodAttribute.cs
- CommandField.cs
- SoapMessage.cs
- RoutingUtilities.cs
- HierarchicalDataBoundControl.cs
- ReadOnlyHierarchicalDataSourceView.cs
- SecurityPermission.cs
- DataGridViewColumnTypePicker.cs
- ColumnHeaderConverter.cs