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 / Scene3D.cs / 1 / Scene3D.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: Scene3D implementation. // // See spec at http://avalon/medialayer/Specifications/Avalon3D%20API%20Spec.mht //--------------------------------------------------------------------------- using System; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using MS.Internal; using System.ComponentModel.Design.Serialization; using System.Windows.Markup; using MS.Internal.Media3D; namespace System.Windows.Media.Media3D { internal partial class Scene3D : Animatable { internal Scene3D() { } ////// Marks the visible realizations of the Scene3D. /// internal void MarkVisibleRealizations(RealizationContext ctx) { Camera camera = Camera; if (Models != null && camera != null) { Matrix3D view = camera.GetViewMatrix(); Matrix3D proj = camera.GetProjectionMatrix(M3DUtil.GetAspectRatio(Viewport.Size)); Matrix3DStack stack3D = ctx.Transform3DStack; // // Update the 3D stack with the coordinate system change into // 2D space. stack3D.Push(proj); // Apply the projection transform (perspective, orthographic, etc.) stack3D.Push(view); // Position and orient camera. Models.MarkVisibleRealizations(ctx); stack3D.Pop(); // Projection. stack3D.Pop(); // Camera view. } } } } // 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: Scene3D implementation. // // See spec at http://avalon/medialayer/Specifications/Avalon3D%20API%20Spec.mht //--------------------------------------------------------------------------- using System; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using MS.Internal; using System.ComponentModel.Design.Serialization; using System.Windows.Markup; using MS.Internal.Media3D; namespace System.Windows.Media.Media3D { internal partial class Scene3D : Animatable { internal Scene3D() { } ////// Marks the visible realizations of the Scene3D. /// internal void MarkVisibleRealizations(RealizationContext ctx) { Camera camera = Camera; if (Models != null && camera != null) { Matrix3D view = camera.GetViewMatrix(); Matrix3D proj = camera.GetProjectionMatrix(M3DUtil.GetAspectRatio(Viewport.Size)); Matrix3DStack stack3D = ctx.Transform3DStack; // // Update the 3D stack with the coordinate system change into // 2D space. stack3D.Push(proj); // Apply the projection transform (perspective, orthographic, etc.) stack3D.Push(view); // Position and orient camera. Models.MarkVisibleRealizations(ctx); stack3D.Pop(); // Projection. stack3D.Pop(); // Camera view. } } } } // 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
- MD5CryptoServiceProvider.cs
- KeyboardNavigation.cs
- IndependentlyAnimatedPropertyMetadata.cs
- WmlMobileTextWriter.cs
- Control.cs
- BlurBitmapEffect.cs
- SubMenuStyle.cs
- Gdiplus.cs
- DynamicRenderer.cs
- TimeSpanMinutesConverter.cs
- SqlDataSourceSummaryPanel.cs
- GenericsInstances.cs
- WinInet.cs
- DocumentPageViewAutomationPeer.cs
- UnsafeNativeMethods.cs
- ExtractorMetadata.cs
- Transform3DGroup.cs
- AutomationPatternInfo.cs
- FrameworkContentElement.cs
- MetadataCollection.cs
- Model3D.cs
- TTSEvent.cs
- thaishape.cs
- GroupAggregateExpr.cs
- XhtmlBasicValidationSummaryAdapter.cs
- ServiceOperationParameter.cs
- ProcessInfo.cs
- NonBatchDirectoryCompiler.cs
- TreeViewHitTestInfo.cs
- FormViewUpdatedEventArgs.cs
- SerializationInfoEnumerator.cs
- SevenBitStream.cs
- SoapHttpTransportImporter.cs
- AssociationEndMember.cs
- TraceSection.cs
- ViewKeyConstraint.cs
- Button.cs
- Transform.cs
- Lasso.cs
- IdentityModelStringsVersion1.cs
- ProcessModule.cs
- SByte.cs
- CriticalFinalizerObject.cs
- CompositeActivityValidator.cs
- KeysConverter.cs
- DeclarativeExpressionConditionDeclaration.cs
- NameTable.cs
- CallSiteBinder.cs
- XmlSchemaDocumentation.cs
- Int64.cs
- PropertyTabChangedEvent.cs
- GeneralTransformGroup.cs
- EDesignUtil.cs
- XmlReader.cs
- DataContext.cs
- SymLanguageVendor.cs
- Parameter.cs
- WindowsScrollBarBits.cs
- SafeBitVector32.cs
- EditBehavior.cs
- AndCondition.cs
- DataServiceQuery.cs
- ParallelEnumerableWrapper.cs
- dataobject.cs
- BuilderPropertyEntry.cs
- CSharpCodeProvider.cs
- EncryptedKeyIdentifierClause.cs
- StackBuilderSink.cs
- PropertyPanel.cs
- RenderingEventArgs.cs
- OracleBoolean.cs
- XmlElementCollection.cs
- ObjectStateEntryDbDataRecord.cs
- GridViewRowEventArgs.cs
- BStrWrapper.cs
- ErrorWrapper.cs
- CacheOutputQuery.cs
- WindowsGraphics.cs
- DynamicDiscoSearcher.cs
- SafeHandle.cs
- PropertyEmitter.cs
- DeferredRunTextReference.cs
- GeneralTransform2DTo3DTo2D.cs
- SrgsElement.cs
- safelink.cs
- AttributeData.cs
- HttpException.cs
- DragEventArgs.cs
- ValidationPropertyAttribute.cs
- TriState.cs
- OAVariantLib.cs
- CroppedBitmap.cs
- HostVisual.cs
- EventManager.cs
- DSACryptoServiceProvider.cs
- XmlSchemaAll.cs
- querybuilder.cs
- sqlnorm.cs
- PackageFilter.cs
- StylusPointDescription.cs