Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / 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
- OrderedDictionary.cs
- Point3DKeyFrameCollection.cs
- GlyphingCache.cs
- TokenBasedSet.cs
- ScalarConstant.cs
- TextElement.cs
- altserialization.cs
- DbConnectionPoolCounters.cs
- PkcsUtils.cs
- ReadWriteObjectLock.cs
- FileDialogCustomPlaces.cs
- ActivityExecutor.cs
- HttpCachePolicyElement.cs
- NumericPagerField.cs
- ConsoleKeyInfo.cs
- GenericTextProperties.cs
- IdentityValidationException.cs
- XmlWhitespace.cs
- CompressEmulationStream.cs
- Inflater.cs
- WindowsEditBoxRange.cs
- SamlSecurityTokenAuthenticator.cs
- mediaeventshelper.cs
- StreamHelper.cs
- Tag.cs
- Activity.cs
- XsltFunctions.cs
- WebPartEditVerb.cs
- BaseTreeIterator.cs
- NetMsmqSecurityElement.cs
- ModulesEntry.cs
- TextSchema.cs
- CookieProtection.cs
- DataTemplateKey.cs
- MediaPlayerState.cs
- XPathParser.cs
- ExpanderAutomationPeer.cs
- RectKeyFrameCollection.cs
- EntityDataSourceWizardForm.cs
- XmlPreloadedResolver.cs
- LongTypeConverter.cs
- Matrix3D.cs
- SerialStream.cs
- CodeTypeDeclarationCollection.cs
- QilChoice.cs
- PropertyGridCommands.cs
- Source.cs
- CircleHotSpot.cs
- DbConnectionPoolOptions.cs
- InheritanceAttribute.cs
- Component.cs
- ViewManager.cs
- RectangleHotSpot.cs
- SqlRemoveConstantOrderBy.cs
- Menu.cs
- UnmanagedBitmapWrapper.cs
- ChannelSinkStacks.cs
- LinkDescriptor.cs
- PrimitiveDataContract.cs
- PinnedBufferMemoryStream.cs
- Brush.cs
- PropertyCollection.cs
- TransformerConfigurationWizardBase.cs
- Walker.cs
- CompiledRegexRunner.cs
- ContextInformation.cs
- Attributes.cs
- DesignerWidgets.cs
- PixelFormatConverter.cs
- WriteableOnDemandStream.cs
- XmlSchemaValidator.cs
- MemoryFailPoint.cs
- RegexCompiler.cs
- JsonSerializer.cs
- WizardDesigner.cs
- BinaryObjectWriter.cs
- ErrorRuntimeConfig.cs
- NetSectionGroup.cs
- DockPattern.cs
- ObjectTokenCategory.cs
- PersonalizationState.cs
- RuntimeResourceSet.cs
- _AutoWebProxyScriptWrapper.cs
- ReadOnlyDataSource.cs
- SignedXmlDebugLog.cs
- GZipDecoder.cs
- PathSegment.cs
- SqlBulkCopyColumnMapping.cs
- SerializationAttributes.cs
- ApplicationSecurityInfo.cs
- SafeArchiveContext.cs
- CompressedStack.cs
- HtmlShim.cs
- TreeNodeConverter.cs
- Select.cs
- XhtmlBasicTextViewAdapter.cs
- TextSelectionHelper.cs
- NotifyCollectionChangedEventArgs.cs
- BaseDataList.cs
- InputMethodStateChangeEventArgs.cs