Daily update on 20250618-051714 by Nitload Youmu. Additional Message : Brief support to collection operation in EXPRESS. A collection type added in core lib and compilestack.
Signed-off-by: Nitload <YoumuLiu_NSI@whv0t.onmicrosoft.com>
This commit is contained in:
@@ -41,11 +41,7 @@ namespace StgSharp.Geometries
|
||||
public interface IPlainEntity
|
||||
{
|
||||
|
||||
public Vec2 CenterPosition
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
public Vec2 CenterPosition { get; set; }
|
||||
|
||||
public bool CollideWith( IPlainEntity entity );
|
||||
|
||||
|
||||
@@ -53,29 +53,13 @@ namespace StgSharp.Geometries
|
||||
( ( IInstancingBuffer )buffer ).InstanceList.Add( this );
|
||||
}
|
||||
|
||||
public GeometryMotion Motion
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
public GeometryMotion Motion { get; set; }
|
||||
|
||||
public IInstancingBuffer GlobalBuffer
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
public IInstancingBuffer GlobalBuffer { get; set; }
|
||||
|
||||
public int BufferId
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
public int BufferId { get; set; }
|
||||
|
||||
Vec3 IInstancing.CenterPositionGlobal
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
Vec3 IInstancing.CenterPositionGlobal { get; set; }
|
||||
|
||||
bool IPlainEntity.CollideWith( IPlainEntity entity )
|
||||
{
|
||||
|
||||
@@ -37,7 +37,7 @@ using System.ComponentModel;
|
||||
namespace StgSharp.Geometries
|
||||
{
|
||||
/// <summary>
|
||||
/// Plain geometry only contains straight sides.
|
||||
/// Plain geometry only contains straight sides.
|
||||
/// </summary>
|
||||
public abstract class PlainGeometry : IGeometry
|
||||
{
|
||||
@@ -58,10 +58,7 @@ namespace StgSharp.Geometries
|
||||
|
||||
public int VertexCount => this.vertexMat.Length;
|
||||
|
||||
public abstract ReadOnlySpan<int> VertexIndices
|
||||
{
|
||||
get;
|
||||
}
|
||||
public abstract ReadOnlySpan<int> VertexIndices { get; }
|
||||
|
||||
#pragma warning disable CA1819
|
||||
public Vec4[] VertexStream => vertexMat;
|
||||
|
||||
@@ -85,12 +85,12 @@ namespace StgSharp.Geometries
|
||||
{
|
||||
get
|
||||
{
|
||||
if( coordArray.Length != coordList.Capacity ) {
|
||||
if( coordArray.Length != coordList.Capacity )
|
||||
{
|
||||
FieldInfo fieldInfo = typeof( List<Vec4> ).
|
||||
GetField(
|
||||
"_items",
|
||||
BindingFlags.NonPublic | BindingFlags.Instance );
|
||||
if( fieldInfo == null ) {
|
||||
GetField( "_items", BindingFlags.NonPublic | BindingFlags.Instance );
|
||||
if( fieldInfo == null )
|
||||
{
|
||||
#pragma warning disable CA1065
|
||||
#pragma warning disable CA2201
|
||||
throw new NullReferenceException();
|
||||
@@ -107,12 +107,12 @@ namespace StgSharp.Geometries
|
||||
{
|
||||
get
|
||||
{
|
||||
if( scaleArray.Length != coordList.Capacity ) {
|
||||
if( scaleArray.Length != coordList.Capacity )
|
||||
{
|
||||
FieldInfo fieldInfo = typeof( List<float> ).
|
||||
GetField(
|
||||
"_items",
|
||||
BindingFlags.NonPublic | BindingFlags.Instance );
|
||||
if( fieldInfo == null ) {
|
||||
GetField( "_items", BindingFlags.NonPublic | BindingFlags.Instance );
|
||||
if( fieldInfo == null )
|
||||
{
|
||||
#pragma warning disable CA1065
|
||||
#pragma warning disable CA2201
|
||||
throw new NullReferenceException();
|
||||
@@ -167,8 +167,7 @@ namespace StgSharp.Geometries
|
||||
temp.BufferId = instance.BufferId;
|
||||
|
||||
coordList[ instance.BufferId ] = coordList[ coordList.Count - 1 ];
|
||||
scalingList[ instance.BufferId ] = scalingList[
|
||||
scalingList.Count - 1 ];
|
||||
scalingList[ instance.BufferId ] = scalingList[ scalingList.Count - 1 ];
|
||||
|
||||
instanceList.RemoveAt( instanceList.Count - 1 );
|
||||
coordList.RemoveAt( coordList.Count - 1 );
|
||||
@@ -185,7 +184,8 @@ namespace StgSharp.Geometries
|
||||
|
||||
protected virtual void Dispose( bool disposing )
|
||||
{
|
||||
if( !disposedValue ) {
|
||||
if( !disposedValue )
|
||||
{
|
||||
if( disposing ) {
|
||||
mutex.Dispose();
|
||||
}
|
||||
@@ -204,8 +204,7 @@ namespace StgSharp.Geometries
|
||||
}
|
||||
}
|
||||
|
||||
IGeometry IInstancingBuffer.TypicalShape => throw new NotImplementedException(
|
||||
);
|
||||
IGeometry IInstancingBuffer.TypicalShape => throw new NotImplementedException();
|
||||
|
||||
#region field of mem opt
|
||||
|
||||
|
||||
Reference in New Issue
Block a user