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:
@@ -79,18 +79,18 @@ namespace StgSharp.Math
|
||||
}
|
||||
|
||||
public Matrix34(
|
||||
float a00,
|
||||
float a01,
|
||||
float a02,
|
||||
float a03,
|
||||
float a10,
|
||||
float a11,
|
||||
float a12,
|
||||
float a13,
|
||||
float a20,
|
||||
float a21,
|
||||
float a22,
|
||||
float a23 )
|
||||
float a00,
|
||||
float a01,
|
||||
float a02,
|
||||
float a03,
|
||||
float a10,
|
||||
float a11,
|
||||
float a12,
|
||||
float a13,
|
||||
float a20,
|
||||
float a21,
|
||||
float a22,
|
||||
float a23 )
|
||||
{
|
||||
Unsafe.SkipInit( out this );
|
||||
isTransposed = false;
|
||||
@@ -111,7 +111,8 @@ namespace StgSharp.Math
|
||||
throw new ArgumentOutOfRangeException( nameof( columNum ) );
|
||||
}
|
||||
InternalTranspose();
|
||||
fixed( float* p = &this.transpose.m00 ) {
|
||||
fixed( float* p = &this.transpose.m00 )
|
||||
{
|
||||
ulong pbit = ( ( ulong )p ) + ( ( ( ulong )sizeof( Vector4 ) ) * ( ( ulong )rowNum ) ) + ( ( ( ulong )sizeof( float ) ) * ( ( ulong )columNum ) );
|
||||
return *( float* )pbit;
|
||||
}
|
||||
@@ -125,7 +126,8 @@ namespace StgSharp.Math
|
||||
throw new ArgumentOutOfRangeException( nameof( columNum ) );
|
||||
}
|
||||
InternalTranspose();
|
||||
fixed( float* p = &this.transpose.m00 ) {
|
||||
fixed( float* p = &this.transpose.m00 )
|
||||
{
|
||||
ulong pbit = ( ( ulong )p ) + ( ( ( ulong )sizeof( Vector4 ) ) * ( ( ulong )rowNum ) ) + ( ( ( ulong )sizeof( float ) ) * ( ( ulong )columNum ) );
|
||||
*( float* )pbit = value;
|
||||
}
|
||||
@@ -135,8 +137,10 @@ namespace StgSharp.Math
|
||||
|
||||
internal unsafe void InternalTranspose()
|
||||
{
|
||||
if( !isTransposed ) {
|
||||
fixed( ColumnSet4* source = &this.mat ) {
|
||||
if( !isTransposed )
|
||||
{
|
||||
fixed( ColumnSet4* source = &this.mat )
|
||||
{
|
||||
fixed( ColumnSet3* target = &this.transpose ) {
|
||||
InternalIO.Intrinsic.transpose43( source, target );
|
||||
}
|
||||
@@ -147,9 +151,7 @@ namespace StgSharp.Math
|
||||
}
|
||||
|
||||
[MethodImpl( MethodImplOptions.AggressiveInlining )]
|
||||
public static unsafe Matrix34 operator -(
|
||||
Matrix34 left,
|
||||
Matrix34 right )
|
||||
public static unsafe Matrix34 operator -( Matrix34 left, Matrix34 right )
|
||||
{
|
||||
Matrix34 ret = new Matrix34();
|
||||
InternalIO.Intrinsic.sub_mat_4( &left.mat, &right.mat, &ret.mat );
|
||||
@@ -160,8 +162,8 @@ namespace StgSharp.Math
|
||||
public static Matrix34 operator *( Matrix34 mat, float value )
|
||||
{
|
||||
return new Matrix34(
|
||||
mat.mat.colum0 * value, mat.mat.colum1 * value,
|
||||
mat.mat.colum2 * value, mat.mat.colum3 * value );
|
||||
mat.mat.colum0 * value, mat.mat.colum1 * value, mat.mat.colum2 * value,
|
||||
mat.mat.colum3 * value );
|
||||
}
|
||||
|
||||
[MethodImpl( MethodImplOptions.AggressiveInlining )]
|
||||
@@ -222,14 +224,12 @@ namespace StgSharp.Math
|
||||
public static Matrix34 operator /( Matrix34 mat, float value )
|
||||
{
|
||||
return new Matrix34(
|
||||
mat.mat.colum0 / value, mat.mat.colum1 / value,
|
||||
mat.mat.colum2 / value, mat.mat.colum3 / value );
|
||||
mat.mat.colum0 / value, mat.mat.colum1 / value, mat.mat.colum2 / value,
|
||||
mat.mat.colum3 / value );
|
||||
}
|
||||
|
||||
[MethodImpl( MethodImplOptions.AggressiveInlining )]
|
||||
public static unsafe Matrix34 operator +(
|
||||
Matrix34 left,
|
||||
Matrix34 right )
|
||||
public static unsafe Matrix34 operator +( Matrix34 left, Matrix34 right )
|
||||
{
|
||||
Matrix34 ret = new Matrix34();
|
||||
InternalIO.Intrinsic.add_mat_4( &left.mat, &right.mat, &ret.mat );
|
||||
|
||||
Reference in New Issue
Block a user