Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Core / CSharp / System / Windows / Media3D / DiffuseMaterial.cs / 1 / DiffuseMaterial.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: 3D diffuse material // // See spec at *** FILL IN LATER *** // // History: // 06/25/2003 : t-gregr - Created // 01/28/2005 : jordanpa - Renamed BrushMaterial to DiffuseMaterial // //--------------------------------------------------------------------------- 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 { ////// DiffuseMaterial allows a 2d brush to be used on a 3d model that has been lit /// with a diffuse lighting model /// public sealed partial class DiffuseMaterial : Material { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Constructs a DiffuseMaterial /// public DiffuseMaterial() { } ////// Constructor that sets the Brush property to "brush" /// /// The new material's brush public DiffuseMaterial(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 diffuse material // // See spec at *** FILL IN LATER *** // // History: // 06/25/2003 : t-gregr - Created // 01/28/2005 : jordanpa - Renamed BrushMaterial to DiffuseMaterial // //--------------------------------------------------------------------------- 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 { ////// DiffuseMaterial allows a 2d brush to be used on a 3d model that has been lit /// with a diffuse lighting model /// public sealed partial class DiffuseMaterial : Material { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Constructs a DiffuseMaterial /// public DiffuseMaterial() { } ////// Constructor that sets the Brush property to "brush" /// /// The new material's brush public DiffuseMaterial(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
- Condition.cs
- Scene3D.cs
- StylusPointPropertyInfo.cs
- WsdlHelpGeneratorElement.cs
- TreeSet.cs
- TableAutomationPeer.cs
- ActivityDesignerLayoutSerializers.cs
- Rect.cs
- BindingSource.cs
- SHA384Managed.cs
- Model3DGroup.cs
- SessionState.cs
- SoapSchemaImporter.cs
- StorageAssociationSetMapping.cs
- pingexception.cs
- WorkflowTraceTransfer.cs
- ResourceDescriptionAttribute.cs
- Decorator.cs
- StackBuilderSink.cs
- ReplacementText.cs
- VBIdentifierNameEditor.cs
- SafeTimerHandle.cs
- AppDomainFactory.cs
- WebBrowserEvent.cs
- QueryCacheEntry.cs
- _ListenerResponseStream.cs
- HandoffBehavior.cs
- IpcManager.cs
- NamespaceEmitter.cs
- PaintEvent.cs
- ErrorTableItemStyle.cs
- GroupStyle.cs
- BinarySerializer.cs
- PreviewPageInfo.cs
- ScrollEventArgs.cs
- PropertyPushdownHelper.cs
- externdll.cs
- ElementMarkupObject.cs
- SecurityRuntime.cs
- AttachInfo.cs
- HtmlElementCollection.cs
- ConnectionProviderAttribute.cs
- FunctionMappingTranslator.cs
- HandleCollector.cs
- HeaderedContentControl.cs
- SelectedDatesCollection.cs
- HostedNamedPipeTransportManager.cs
- SettingsAttributeDictionary.cs
- Scalars.cs
- ToolStripComboBox.cs
- ContextStack.cs
- ListCommandEventArgs.cs
- PersistChildrenAttribute.cs
- ConstructorNeedsTagAttribute.cs
- SqlParameterizer.cs
- CultureInfo.cs
- TextSelection.cs
- File.cs
- CryptoHelper.cs
- BooleanKeyFrameCollection.cs
- DependencyPropertyHelper.cs
- NumericUpDownAccelerationCollection.cs
- HttpModuleActionCollection.cs
- AdornedElementPlaceholder.cs
- SelectedGridItemChangedEvent.cs
- AssociationSetEnd.cs
- EntityDataSourceChangedEventArgs.cs
- TableLayoutCellPaintEventArgs.cs
- Facet.cs
- TrustManagerPromptUI.cs
- PtsHelper.cs
- QuadraticBezierSegment.cs
- SystemIPGlobalProperties.cs
- CaseStatementSlot.cs
- KeyboardNavigation.cs
- SHA1Managed.cs
- ImmComposition.cs
- DialogResultConverter.cs
- SmtpFailedRecipientsException.cs
- CodeNamespaceImport.cs
- UITypeEditor.cs
- Label.cs
- TreeViewImageIndexConverter.cs
- PaintEvent.cs
- RadioButton.cs
- NamedPipeAppDomainProtocolHandler.cs
- BaseHashHelper.cs
- CollectionViewGroup.cs
- BaseResourcesBuildProvider.cs
- SourceLineInfo.cs
- ControlCommandSet.cs
- Tokenizer.cs
- SimpleTextLine.cs
- StylesEditorDialog.cs
- DataGridTableCollection.cs
- UpdatePanel.cs
- ServiceDescriptionData.cs
- SqlInternalConnectionSmi.cs
- CodeConditionStatement.cs
- AlignmentYValidation.cs