Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Media3D / Material.cs / 1 / Material.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: 3D material implementation. // // See spec at http://avalon/medialayer/Specifications/Avalon3D%20API%20Spec.mht // // History: // 06/25/2003 : t-gregr - Created // //--------------------------------------------------------------------------- using System; using System.Diagnostics; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; namespace System.Windows.Media.Media3D { ////// Material is the abstract base class for materials /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] // cannot be read & localized as string public abstract partial class Material : Animatable { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors // Prevent 3rd parties from extending this abstract base class. internal Material() {} #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods // NTRAID#Longhorn-1591973-2006/03/31-[....] - Should be using inherited "Precompute" from Animatable // // These return 'true' if the Material requires realization internal abstract bool PreCompute(); internal static bool PreCompute(Brush brush) { bool requiresRealization = false; if (brush != null) { brush.Precompute(); requiresRealization = brush.RequiresRealizationUpdates; } return requiresRealization; } internal abstract void UpdateRealizations( RealizationContext ctx, ref Rect bounds); internal static void UpdateRealizations( Brush brush, RealizationContext ctx, ref Rect bounds ) { if (brush != null) { brush.UpdateRealizations(bounds, ctx); } } #endregion Internal Methods //------------------------------------------------------ // // Internal Properties // //------------------------------------------------------ #region Internal Properties // NTRAID#Longhorn-1591973-2006/03/31-[....] - Should be using inherited "RequiresRealizationUpdates" from Animatable internal abstract bool RequiresRealization { get; } #endregion Internal Properties } } // 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 material implementation. // // See spec at http://avalon/medialayer/Specifications/Avalon3D%20API%20Spec.mht // // History: // 06/25/2003 : t-gregr - Created // //--------------------------------------------------------------------------- using System; using System.Diagnostics; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; namespace System.Windows.Media.Media3D { ////// Material is the abstract base class for materials /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] // cannot be read & localized as string public abstract partial class Material : Animatable { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors // Prevent 3rd parties from extending this abstract base class. internal Material() {} #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods // NTRAID#Longhorn-1591973-2006/03/31-[....] - Should be using inherited "Precompute" from Animatable // // These return 'true' if the Material requires realization internal abstract bool PreCompute(); internal static bool PreCompute(Brush brush) { bool requiresRealization = false; if (brush != null) { brush.Precompute(); requiresRealization = brush.RequiresRealizationUpdates; } return requiresRealization; } internal abstract void UpdateRealizations( RealizationContext ctx, ref Rect bounds); internal static void UpdateRealizations( Brush brush, RealizationContext ctx, ref Rect bounds ) { if (brush != null) { brush.UpdateRealizations(bounds, ctx); } } #endregion Internal Methods //------------------------------------------------------ // // Internal Properties // //------------------------------------------------------ #region Internal Properties // NTRAID#Longhorn-1591973-2006/03/31-[....] - Should be using inherited "RequiresRealizationUpdates" from Animatable internal abstract bool RequiresRealization { get; } #endregion Internal Properties } } // 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
- DiffuseMaterial.cs
- ComPlusThreadInitializer.cs
- NoResizeHandleGlyph.cs
- HighlightVisual.cs
- ProcessHostFactoryHelper.cs
- FormatSettings.cs
- StructuralObject.cs
- InvalidEnumArgumentException.cs
- ImageField.cs
- ReachUIElementCollectionSerializer.cs
- SspiNegotiationTokenAuthenticatorState.cs
- ExtenderProvidedPropertyAttribute.cs
- ClientBuildManager.cs
- XomlCompilerHelpers.cs
- ASCIIEncoding.cs
- SocketInformation.cs
- EmptyElement.cs
- LogicalTreeHelper.cs
- TCPClient.cs
- TCPClient.cs
- Pen.cs
- UnsafeNativeMethodsCLR.cs
- ExpressionBindingCollection.cs
- ShellProvider.cs
- DrawingAttributesDefaultValueFactory.cs
- ExeContext.cs
- Point3DKeyFrameCollection.cs
- ToolStripLabel.cs
- CollectionChangedEventManager.cs
- BufferAllocator.cs
- DeviceSpecificChoice.cs
- AutoGeneratedFieldProperties.cs
- SQLBinary.cs
- GeneralTransform3DTo2DTo3D.cs
- DataGridViewCellStateChangedEventArgs.cs
- ColorConvertedBitmap.cs
- Mutex.cs
- InheritanceAttribute.cs
- InvokeMethodActivity.cs
- KeyTime.cs
- IntPtr.cs
- Thumb.cs
- ObjectListItemCollection.cs
- DeliveryRequirementsAttribute.cs
- CodeGroup.cs
- ReadingWritingEntityEventArgs.cs
- Rect3D.cs
- DateTime.cs
- RenderCapability.cs
- BindingMAnagerBase.cs
- SchemaTypeEmitter.cs
- IISUnsafeMethods.cs
- AsyncResult.cs
- ControllableStoryboardAction.cs
- NameScope.cs
- CollectionCodeDomSerializer.cs
- QueryPageSettingsEventArgs.cs
- EntryPointNotFoundException.cs
- ObjectParameterCollection.cs
- BrowsableAttribute.cs
- DefaultBinder.cs
- DataBoundControl.cs
- templategroup.cs
- PrimitiveDataContract.cs
- BookmarkScopeManager.cs
- InvokeDelegate.cs
- BaseTemplateParser.cs
- OdbcEnvironmentHandle.cs
- TypeContext.cs
- WindowsSolidBrush.cs
- DeferredElementTreeState.cs
- DataGridViewAutoSizeModeEventArgs.cs
- Graph.cs
- GenericTypeParameterBuilder.cs
- TabletDeviceInfo.cs
- ScalarOps.cs
- Object.cs
- DataGridViewMethods.cs
- ScopelessEnumAttribute.cs
- Rijndael.cs
- DataGridViewCellParsingEventArgs.cs
- Point4DConverter.cs
- TextChangedEventArgs.cs
- XPathNodeIterator.cs
- Pts.cs
- UnsafeCollabNativeMethods.cs
- DefaultEventAttribute.cs
- StateManagedCollection.cs
- FontDialog.cs
- SQLBoolean.cs
- SimpleBitVector32.cs
- ReferenceEqualityComparer.cs
- ZipIOModeEnforcingStream.cs
- ToolStripDropDownItem.cs
- RemoteDebugger.cs
- DbSourceParameterCollection.cs
- LicenseContext.cs
- ByteBufferPool.cs
- IISMapPath.cs
- EditingScope.cs