Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / Media3D / Matrix3DStack.cs / 1305600 / Matrix3DStack.cs
//---------------------------------------------------------------------------- // //// Copyright (c) Microsoft Corporation. All rights reserved. // // // Description: This is a super simple Matrix3DStack implementation. // MatrixStack (2D) is optimized to avoid boxig and copying // of structs. This was written as a stop-gap to address // a bug until we can use CodeGen here. // // History: // 1/19/2004 : [....] - Created // //--------------------------------------------------------------------------- using System; using System.Collections; using System.Collections.Generic; namespace System.Windows.Media.Media3D { // internal class Matrix3DStack { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- //------------------------------------------------------ // // Public Methods // //----------------------------------------------------- public void Clear() { _stack.Clear(); } public Matrix3D Pop() { Matrix3D top = Top; _stack.RemoveAt(_stack.Count - 1); return top; } ////// Empty => [matrix] /// tail | [top] => tail | [top] | [matrix * top] /// public void Push(Matrix3D matrix) { if (_stack.Count > 0) { matrix.Append(Top); } _stack.Add(matrix); } //------------------------------------------------------ // // Public Properties // //------------------------------------------------------ public int Count { get { return _stack.Count; } } public bool IsEmpty { get { return (_stack.Count == 0); } } public Matrix3D Top { get { return _stack[_stack.Count - 1]; } } //----------------------------------------------------- // // Public Events // //------------------------------------------------------ //----------------------------------------------------- // // Private Fields // //----------------------------------------------------- #region Private Fields private readonly List_stack = new List (); #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TrackingProfileManager.cs
- BodyGlyph.cs
- CodeExpressionStatement.cs
- XXXInfos.cs
- DateTimeFormatInfoScanner.cs
- StringValueSerializer.cs
- ListViewUpdatedEventArgs.cs
- IntSecurity.cs
- JapaneseLunisolarCalendar.cs
- SqlClientMetaDataCollectionNames.cs
- DataList.cs
- StringTraceRecord.cs
- ClientBuildManager.cs
- View.cs
- OleDbRowUpdatingEvent.cs
- ValueProviderWrapper.cs
- BitSet.cs
- SafeHandles.cs
- AddInAdapter.cs
- TypeDescriptionProvider.cs
- DataColumnSelectionConverter.cs
- CustomAttributeSerializer.cs
- SecurityImpersonationBehavior.cs
- UDPClient.cs
- HtmlTableCellCollection.cs
- CoTaskMemUnicodeSafeHandle.cs
- Control.cs
- XmlReturnWriter.cs
- NamedPipeWorkerProcess.cs
- GenericTypeParameterBuilder.cs
- RepeaterItemCollection.cs
- WebPartVerbCollection.cs
- FileNotFoundException.cs
- SuspendDesigner.cs
- ColumnBinding.cs
- WindowsUserNameSecurityTokenAuthenticator.cs
- DataColumnPropertyDescriptor.cs
- SemanticValue.cs
- LocalServiceSecuritySettings.cs
- RowUpdatedEventArgs.cs
- EntityCollection.cs
- AuthorizationPolicyTypeElementCollection.cs
- CommandEventArgs.cs
- X509Chain.cs
- FieldDescriptor.cs
- WorkflowRuntime.cs
- CreateRefExpr.cs
- EntityDataSourceQueryBuilder.cs
- EventDescriptor.cs
- SqlCommand.cs
- DtrList.cs
- OutputCacheProfile.cs
- ScrollProviderWrapper.cs
- Point3D.cs
- StructuredProperty.cs
- SessionStateModule.cs
- ICspAsymmetricAlgorithm.cs
- ColorConvertedBitmap.cs
- CodeRemoveEventStatement.cs
- XPathDocumentBuilder.cs
- SqlInfoMessageEvent.cs
- XmlSerializerObjectSerializer.cs
- OleDbCommandBuilder.cs
- BoundPropertyEntry.cs
- NodeLabelEditEvent.cs
- PaintValueEventArgs.cs
- ZipIOLocalFileHeader.cs
- Vector3DConverter.cs
- HotCommands.cs
- bidPrivateBase.cs
- SchemaReference.cs
- PropertyMap.cs
- ApplicationSecurityInfo.cs
- UnsafeNetInfoNativeMethods.cs
- DataList.cs
- EncoderReplacementFallback.cs
- TreeNodeClickEventArgs.cs
- DrawToolTipEventArgs.cs
- XmlElement.cs
- ProfileGroupSettings.cs
- FormsAuthenticationTicket.cs
- ArithmeticLiteral.cs
- DataGridGeneralPage.cs
- BrowsableAttribute.cs
- RegistryKey.cs
- TdsParameterSetter.cs
- XmlDataLoader.cs
- TargetInvocationException.cs
- DynamicValidatorEventArgs.cs
- Size3D.cs
- XPathCompileException.cs
- ViewStateException.cs
- ProxyManager.cs
- WorkflowViewManager.cs
- PngBitmapDecoder.cs
- LineMetrics.cs
- NativeMethods.cs
- RetrieveVirtualItemEventArgs.cs
- ConnectionManagementElement.cs
- Pick.cs