Daily update on 20251015-002614 by Nitload Youmu. Additional Message : Organize files of numerial math.

Signed-off-by: Nitload <YoumuLiu_NSI@whv0t.onmicrosoft.com>
This commit is contained in:
Nitload
2025-10-15 00:26:15 +08:00
parent c5eaf250ab
commit e283490525
50 changed files with 1319 additions and 1520 deletions
@@ -1,34 +1,32 @@
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// file="GeometryOperation.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
// -----------------------------------------------------------------------
// file="GeometryOperation"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
using StgSharp.Mathematics;
using StgSharp.Mathematics.Graphic;
using System.Runtime.CompilerServices;
@@ -37,10 +35,10 @@ namespace StgSharp.Geometries
public static unsafe class GeometryOperation
{
[MethodImpl( MethodImplOptions.AggressiveInlining )]
public static Vec3 DefaultMotion( int tick )
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static Vec3 DefaultMotion(int tick)
{
return default( Vec3 );
return default(Vec3);
}
}
@@ -1,34 +1,35 @@
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// file="IPlainEntity.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
// -----------------------------------------------------------------------
// file="IPlainEntity.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
//
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
using StgSharp.Mathematics;
using StgSharp.Mathematics.Graphic;
using System;
using System.Collections.Generic;
@@ -43,7 +44,7 @@ namespace StgSharp.Geometries
public Vec2 CenterPosition { get; set; }
public bool CollideWith( IPlainEntity entity );
public bool CollideWith(IPlainEntity entity);
}
@@ -52,12 +53,12 @@ namespace StgSharp.Geometries
private PlainGeometry _shape;
public PlainEntity( PlainGeometry shape )
public PlainEntity(PlainGeometry shape)
{
_shape = shape;
}
bool IPlainEntity.CollideWith( IPlainEntity entity )
bool IPlainEntity.CollideWith(IPlainEntity entity)
{
throw new NotImplementedException();
}
@@ -1,34 +1,32 @@
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// file="ParticleOnPlain.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
// -----------------------------------------------------------------------
// file="ParticleOnPlain"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
using StgSharp.Mathematics;
using StgSharp.Mathematics.Graphic;
using System;
using System.Collections.Generic;
@@ -43,14 +41,14 @@ namespace StgSharp.Geometries
public class ParticleOnPlain : IInstancing, IPlainEntity
{
public ParticleOnPlain( PlainInstancingBuffer<ParticleOnPlain> buffer )
public ParticleOnPlain(PlainInstancingBuffer<ParticleOnPlain> buffer)
{
if( buffer == null ) {
throw new ArgumentNullException( paramName: nameof( buffer ) );
if (buffer == null) {
throw new ArgumentNullException(paramName:nameof(buffer));
}
GlobalBuffer = buffer;
BufferId = buffer.CreateInstanceID();
( ( IInstancingBuffer )buffer ).InstanceList.Add( this );
((IInstancingBuffer)buffer).InstanceList.Add(this);
}
public GeometryMotion Motion { get; set; }
@@ -61,14 +59,14 @@ namespace StgSharp.Geometries
Vec3 IInstancing.CenterPositionGlobal { get; set; }
bool IPlainEntity.CollideWith( IPlainEntity entity )
bool IPlainEntity.CollideWith(IPlainEntity entity)
{
throw new NotImplementedException();
}
Vec2 IPlainEntity.CenterPosition
{
get => GlobalBuffer.CoordAndRotationList[ BufferId ].XY;
get => GlobalBuffer.CoordAndRotationList[BufferId].XY;
set => throw new NotImplementedException();
}
@@ -1,35 +1,33 @@
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// file="PlainGeometry.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
// -----------------------------------------------------------------------
// file="PlainGeometry"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
using StgSharp.Graphics;
using StgSharp.Mathematics;
using StgSharp.Mathematics.Graphic;
using System;
using System.ComponentModel;
@@ -45,15 +43,15 @@ namespace StgSharp.Geometries
protected Vec4[] vertexMat;
internal CoordinationBase coordinate;
internal PlainGeometry( CoordinationBase coordination )
internal PlainGeometry(CoordinationBase coordination)
{
coordinate = coordination;
}
public Point this[ int index ]
public Point this[int index]
{
get => new Point( vertexMat[ index ] );
set => vertexMat[ index ].vec = value.coordVec;
get => new Point(vertexMat[index]);
set => vertexMat[index].vec = value.coordVec;
}
public int VertexCount => this.vertexMat.Length;
@@ -1,34 +1,33 @@
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// file="PlainInstancingBuffer.cs"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
// -----------------------------------------------------------------------
// file="PlainInstancingBuffer"
// Project: StgSharp
// AuthorGroup: Nitload Space
// Copyright (c) Nitload Space. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person
// obtaining a copy of this software and associated documentation
// files (the “Software”), to deal in the Software without restriction,
// including without limitation the rights to use, copy, modify, merge,
// publish, distribute, sublicense, and/or sell copies of the Software,
// and to permit persons to whom the Software is furnished to do so,
// subject to the following conditions:
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
// The above copyright notice and
// this permission notice shall be included in all copies
// or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED “AS IS”,
// WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
using StgSharp.Mathematics;
using StgSharp.Mathematics.Graphic;
using StgSharp.Mathematics.Numeric;
using System;
using System.Collections;
@@ -38,19 +37,20 @@ using System.Diagnostics.Contracts;
using System.Linq;
using System.Numerics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace StgSharp.Geometries
{
public class PlainInstancingBuffer<T> : IDisposable, IEnumerable<T>, IInstancingBuffer
where T: IInstancing
public class PlainInstancingBuffer<T> : IDisposable, IEnumerable<T>, IInstancingBuffer where T: IInstancing
{
private bool disposedValue;
private CoordinatePlain globalCorrdinnate;
private CoordinatePlain globalCoordinate;
private List<Vec4> coordList;
private List<IInstancing> instanceList;
private List<float> scalingList;
@@ -58,9 +58,9 @@ namespace StgSharp.Geometries
public PlainInstancingBuffer()
{
coordList = new List<Vec4>( capacity: 100 );
instanceList = new List<IInstancing>( capacity: 100 );
scalingList = new List<float>( capacity: 100 );
coordList = new List<Vec4>(capacity:100);
instanceList = new List<IInstancing>(capacity:100);
scalingList = new List<float>(capacity:100);
coordArray = Array.Empty<Vec4>();
scaleArray = Array.Empty<float>();
mutex = new Mutex();
@@ -68,125 +68,96 @@ namespace StgSharp.Geometries
public List<IInstancing> InstanceList
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => instanceList;
}
public List<Vec4> CoordAndRotationList
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => coordList;
}
public List<float> ScalingList
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => scalingList;
}
public Span<Vec4> CoordAndRotationSpan
{
get
{
if( coordArray.Length != coordList.Capacity )
{
FieldInfo fieldInfo = typeof( List<Vec4> ).
GetField( "_items", BindingFlags.NonPublic | BindingFlags.Instance );
if( fieldInfo == null )
{
#pragma warning disable CA1065
#pragma warning disable CA2201
throw new NullReferenceException();
#pragma warning restore CA2201
#pragma warning restore CA1065
}
coordArray = ( Vec4[] )fieldInfo.GetValue( coordList );
}
return new Span<Vec4>( coordArray, 0, coordList.Count );
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => CollectionsMarshal.AsSpan(coordList);
}
public Span<float> ScalingSpan
{
get
{
if( scaleArray.Length != coordList.Capacity )
{
FieldInfo fieldInfo = typeof( List<float> ).
GetField( "_items", BindingFlags.NonPublic | BindingFlags.Instance );
if( fieldInfo == null )
{
#pragma warning disable CA1065
#pragma warning disable CA2201
throw new NullReferenceException();
#pragma warning restore CA2201
#pragma warning restore CA1065
}
scaleArray = ( float[] )fieldInfo.GetValue( scalingList );
}
return new Span<float>( scaleArray, 0, coordList.Count );
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get => CollectionsMarshal.AsSpan(scalingList);
}
public int CreateInstanceID()
{
mutex.WaitOne();
int ret = instanceList.Count;
coordList.Add( new Vec4() );
scalingList.Add( 0 );
coordList.Add(new Vec4());
scalingList.Add(0);
mutex.ReleaseMutex();
return ret;
}
// ~PlainInstancingBuffer()
// {
// Dispose(disposing: false);
// Dispose(disposing: false);
// }
public void Dispose()
{
Dispose( disposing: true );
GC.SuppressFinalize( this );
Dispose(disposing:true);
GC.SuppressFinalize(this);
}
public IEnumerator<T> GetEnumerator()
{
foreach( IInstancing item in instanceList ) {
yield return ( T )item;
foreach (IInstancing item in instanceList) {
yield return (T)item;
}
}
public void Remove( T instance )
public void Remove(T instance)
{
mutex.WaitOne();
if( instance.GlobalBuffer != this ) {
if (instance.GlobalBuffer != this) {
throw new ArgumentException(
message: "instance does not belong to current Particle Buffer",
paramName: nameof( instance ) );
message:"instance does not belong to current Particle Buffer",
paramName:nameof(instance));
}
int index = instance.BufferId;
IInstancing temp = instanceList[ instanceList.Count - 1 ];
instanceList[ instance.BufferId ] = temp;
IInstancing temp = instanceList[^1];
instanceList[instance.BufferId] = temp;
temp.BufferId = instance.BufferId;
coordList[ instance.BufferId ] = coordList[ coordList.Count - 1 ];
scalingList[ instance.BufferId ] = scalingList[ scalingList.Count - 1 ];
coordList[instance.BufferId] = coordList[^1];
scalingList[instance.BufferId] = scalingList[^1];
instanceList.RemoveAt( instanceList.Count - 1 );
coordList.RemoveAt( coordList.Count - 1 );
scalingList.RemoveAt( scalingList.Count - 1 );
instanceList.RemoveAt(instanceList.Count - 1);
coordList.RemoveAt(coordList.Count - 1);
scalingList.RemoveAt(scalingList.Count - 1);
mutex.ReleaseMutex();
}
public void UpdateAllParticles()
{
foreach( IInstancing particle in instanceList ) {
foreach (IInstancing particle in instanceList) {
particle.Move();
}
}
protected virtual void Dispose( bool disposing )
protected virtual void Dispose(bool disposing)
{
if( !disposedValue )
if (!disposedValue)
{
if( disposing ) {
if (disposing) {
mutex.Dispose();
}
@@ -199,8 +170,8 @@ namespace StgSharp.Geometries
IEnumerator IEnumerable.GetEnumerator()
{
foreach( IInstancing item in instanceList ) {
yield return ( T )item;
foreach (IInstancing item in instanceList) {
yield return (T)item;
}
}