Author: rloach
Date: 2007-01-14 12:11:06 -0500 (Sun, 14 Jan 2007)
New Revision: 70989
Added:
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompilationFailedException.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledShader.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/OutOfVideoMemoryException.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderCompiler.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderSemantic.cs
Modified:
trunk/Mono.Xna/examples/Pong/
trunk/Mono.Xna/src/Microsoft.Xna.Framework.Game/
trunk/Mono.Xna/src/Microsoft.Xna.Framework/
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Audio/AudioEngine.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingBox.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingSphere.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/BasicDirectionalLight.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledEffect.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Compiler.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderConstantCollection.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Texture3D.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Matrix.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Plane.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Point.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Properties/AssemblyInfo.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Quaternion.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Ray.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Rectangle.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector2.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector3.cs
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector4.cs
Log:
Applied duff's patch, some ToString() fixes.
Property changes on: trunk/Mono.Xna/examples/Pong
___________________________________________________________________
Name: svn:ignore
- Pong.csproj
Pong.csproj.user
+ Pong.csproj
Pong.csproj.user
bin
obj
Property changes on: trunk/Mono.Xna/src/Microsoft.Xna.Framework
___________________________________________________________________
Name: svn:ignore
- Microsoft.Xna.Framework.prjx
bin
obj
Include.am
Microsoft.Xna.Framework.csproj
Microsoft.Xna.Framework.csproj.user
Microsoft.Xna.Framework.mdp
+ Microsoft.Xna.Framework.prjx
bin
obj
Include.am
Microsoft.Xna.Framework.csproj
Microsoft.Xna.Framework.csproj.user
Microsoft.Xna.Framework.mdp
Microsoft.Xna.Framework.xml
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Audio/AudioEngine.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Audio/AudioEngine.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Audio/AudioEngine.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -27,6 +27,7 @@
using System;
using System.Collections.ObjectModel;
+using System.Runtime.InteropServices;
namespace Microsoft.Xna.Framework.Audio
{
@@ -54,9 +55,13 @@
public static bool operator !=(AudioEngine left, AudioEngine right) {
throw new NotImplementedException(); }
public static bool operator ==(AudioEngine left, AudioEngine right) {
throw new NotImplementedException(); }
+
+ public bool IsDisposed
+ {
+ [return: MarshalAs(UnmanagedType.U1)]
+ get { throw new NotImplementedException(); }
+ }
- public bool IsDisposed { get { throw new NotImplementedException(); } }
-
public ReadOnlyCollection<RendererDetail> RendererDetails { get {
throw new NotImplementedException(); } }
public event EventHandler Disposing;
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingBox.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingBox.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingBox.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -30,10 +30,11 @@
using System.ComponentModel;
using System.Globalization;
using System.Runtime.InteropServices;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
-
[TypeConverter(typeof(Microsoft.Xna.Framework.Design.BoundingBoxConverter))]
+ [TypeConverter(typeof(BoundingBoxConverter))]
[Serializable]
[StructLayout(LayoutKind.Sequential)]
public struct BoundingBox : IEquatable<BoundingBox>
@@ -59,64 +60,30 @@
public ContainmentType Contains(BoundingBox box)
{
- ContainmentType result;
- this.Contains(ref box, out result);
- return result;
+ //test if all corner is in the same side of a face by
just checking min and max
+ if (box.Max.X < Min.X
+ || box.Min.X > Max.X
+ || box.Max.Y < Min.Y
+ || box.Min.Y > Max.Y
+ || box.Max.Z < Min.Z
+ || box.Min.Z > Max.Z)
+ return ContainmentType.Disjoint;
+
+
+ if (box.Min.X >= Min.X
+ && box.Max.X <= Max.X
+ && box.Min.Y >= Min.Y
+ && box.Max.Y <= Max.Y
+ && box.Min.Z >= Min.Z
+ && box.Max.Z <= Max.Z)
+ return ContainmentType.Contains;
+
+ return ContainmentType.Intersects;
}
public void Contains(ref BoundingBox box, out ContainmentType result)
{
- // The box is disjoint when all corner is outside of one plane of
box.
- // The box contain the other box when all corner is inside
- // else it intersect
- //So take care of the other box contain and the following situation
- // ____________
- // /
- // _________/_____
- // / /|
- // / / |
- // /_ _ _/_____
- // ______________/
- // | |
- // | |
- // |_ _ _|_____
- // | |
- // | |
- // | /
- // | /
- // | /
- // __________|/
-
- //test if all corner is in the same side of a face by just
checking min and max
- if (box.Max.X < Min.X
- || box.Min.X > Max.X
- || box.Max.Y < Min.Y
- || box.Min.Y > Max.Y
- || box.Max.Z < Min.Z
- || box.Min.Z > Max.Z)
- {
- result = ContainmentType.Disjoint;
- return;
- }
-
- //test if all corner of box is inside
- bool isInside = true;
- foreach (Vector3 corner in box.GetCorners())
- {
- if (this.Contains(corner) !=
ContainmentType.Contains
- && this.Contains(corner) !=
ContainmentType.Intersects)
- {
- isInside = false;
- }
- }
- if (isInside)
- {
- //all corner is inside
- result = ContainmentType.Contains;
- return;
- }
- result = ContainmentType.Intersects;
- return;
+ result = Contains(box);
}
public ContainmentType Contains(BoundingFrustum frustum)
@@ -360,3 +327,4 @@
}
}
+
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingSphere.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingSphere.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/BoundingSphere.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -30,10 +30,11 @@
using System.ComponentModel;
using System.Globalization;
using System.Text;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
-
[TypeConverter(typeof(Microsoft.Xna.Framework.Design.BoundingBoxConverter))]
+ [TypeConverter(typeof(BoundingSphereConverter))]
[Serializable]
public struct BoundingSphere : IEquatable<BoundingSphere>
{
Modified:
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/BasicDirectionalLight.cs
===================================================================
---
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/BasicDirectionalLight.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/BasicDirectionalLight.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -31,32 +31,41 @@
namespace Microsoft.Xna.Framework.Graphics
{
- /// <summary>
- /// Provides methods for manipulating the directional lights used by the
BasicEffect class.
- /// </summary>
- public sealed class BasicDirectionalLight
- {
- /// <summary>
- /// Gets or sets the diffuse color of this light.
- /// </summary>
- /// <returns>The diffuse color of this light.</returns>
- public Vector3 DiffuseColor { get { throw new
NotImplementedException(); } set { throw new NotImplementedException(); } }
+ public sealed class BasicDirectionalLight
+ {
+ /// <summary>
+ /// Gets or sets the diffuse color of this light.
+ /// </summary>
+ public Vector3 DiffuseColor {
+ get { return diffuseColor; }
+ set { diffuseColor = value; }
+ }
+ private Vector3 diffuseColor;
+
+ /// <summary>
+ /// Gets or sets light direction.
+ /// </summary>
+ public Vector3 Direction {
+ get{return direction;}
+ set { direction = value; }
+ }
+ private Vector3 direction;
+ /// <summary>
+ /// Enables this light.
+ /// </summary>
+ public bool Enabled {
+ get { return enabled; }
+ set { Enabled = value; }
+ }
+ private bool enabled;
- /// <summary>
- /// Gets or sets light direciton.
- /// </summary>
- /// <returns>Gets or sets the light direciton. This value must be a
unit vector.</returns>
- public Vector3 Direction { get { throw new NotImplementedException();
} set { throw new NotImplementedException(); } }
-
- /// <summary>Enables this light.</summary>
- /// <returns>true to enable this light; false otherwise.
- /// </returns>
- public bool Enabled { get { throw new NotImplementedException(); } set
{ throw new NotImplementedException(); } }
-
- /// <summary>
- /// Gets or sets the specular color of the light.
- /// </summary>
- /// <returns>The specular color of the light.</returns>
- public Vector3 SpecularColor { get { throw new
NotImplementedException(); } set { throw new NotImplementedException(); } }
- }
-}
\ No newline at end of file
+ /// <summary>
+ /// Gets or sets the specular color of the light.
+ /// </summary>
+ public Vector3 SpecularColor {
+ get { return specularColor; }
+ set { specularColor = value; }
+ }
+ private Vector3 specularColor;
+ }
+}
Added:
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompilationFailedException.cs
===================================================================
---
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompilationFailedException.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompilationFailedException.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -0,0 +1,42 @@
+#region License
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
+*/
+#endregion License
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+using System.Runtime.InteropServices;
+
+namespace Microsoft.Xna.Framework.Graphics
+{
+ public class CompilationFailedException : ExternalException
+ {
+ public CompilationFailedException() { throw new
NotImplementedException(); }
+ public CompilationFailedException(string message) { throw new
NotImplementedException(); }
+ public CompilationFailedException(string message, Exception
inner) { throw new NotImplementedException(); }
+
+ }
+}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledEffect.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledEffect.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledEffect.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -32,6 +32,7 @@
namespace Microsoft.Xna.Framework.Graphics
{
+ [Serializable]
public struct CompiledEffect
{
public CompiledEffect(byte[] compiledEffectCode, string errors) {
throw new NotImplementedException(); }
Added: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledShader.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledShader.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/CompiledShader.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -0,0 +1,51 @@
+#region License
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
+*/
+#endregion License
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+using System.Runtime.InteropServices;
+
+namespace Microsoft.Xna.Framework.Graphics
+{
+ [Serializable]
+ [StructLayout(LayoutKind.Sequential)]
+ public struct CompiledShader
+ {
+
+ public byte[] GetShaderCode() { throw new
NotImplementedException(); }
+ public string ErrorsAndWarnings { get { throw new
NotImplementedException(); } }
+ public bool Success { get { throw new
NotImplementedException(); } }
+ public CompiledShader(byte[] compiledShaderCode, string errors)
{ throw new NotImplementedException(); }
+ public string[] GetSamplers() { throw new
NotImplementedException(); }
+ public ShaderSemantic[] GetInputSemantics() { throw new
NotImplementedException(); }
+ public ShaderSemantic[] GetOutputSemantics() { throw new
NotImplementedException(); }
+ public Version ShaderVersion { get { throw new
NotImplementedException(); } }
+ public int ShaderSize { get { throw new
NotImplementedException(); } }
+ public override string ToString() { throw new
NotImplementedException(); }
+ }
+}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Compiler.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Compiler.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Compiler.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -62,7 +62,7 @@
public abstract Stream Open(CompilerIncludeHandlerType includeType,
string filename);
}
-
+ [Serializable]
public struct CompilerMacro
{
public string Definition { get { throw new NotImplementedException();
} set { throw new NotImplementedException(); } }
Added:
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/OutOfVideoMemoryException.cs
===================================================================
---
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/OutOfVideoMemoryException.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/OutOfVideoMemoryException.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -0,0 +1,50 @@
+#region License
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
+*/
+#endregion License
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+using System.Runtime.InteropServices;
+
+namespace Microsoft.Xna.Framework.Graphics
+{
+ public class OutOfVideoMemoryException : ExternalException
+ {
+ public OutOfVideoMemoryException()
+ {
+ throw new NotImplementedException();
+ }
+ public OutOfVideoMemoryException(string message)
+ {
+ throw new NotImplementedException();
+ }
+ public OutOfVideoMemoryException(string message, Exception
inner)
+ {
+ throw new NotImplementedException();
+ }
+ }
+}
Added: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderCompiler.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderCompiler.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderCompiler.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -0,0 +1,47 @@
+#region License
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
+*/
+#endregion License
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+using System.IO;
+
+namespace Microsoft.Xna.Framework.Graphics
+{
+ public static class ShaderCompiler
+ {
+ public static CompiledShader AssembleFromFile(Stream
shaderSourceCode, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, TargetPlatform platform) { throw new
NotImplementedException(); }
+ public static CompiledShader AssembleFromFile(string
shaderFileName, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, TargetPlatform platform) { throw new
NotImplementedException(); }
+ public static CompiledShader AssembleFromFile(Stream
shaderSourceCode, int numberBytes, CompilerMacro[] preprocessorDefines,
CompilerIncludeHandler includeHandler, CompilerOptions options, TargetPlatform
platform) { throw new NotImplementedException(); }
+ public static CompiledShader AssembleFromSource(string
shaderSourceCode, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, TargetPlatform platform) { throw new
NotImplementedException(); }
+ public static CompiledShader CompileFromFile(Stream
shaderSourceCode, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, string functionName, ShaderProfile
profile, TargetPlatform platform) { throw new NotImplementedException(); }
+ public static CompiledShader CompileFromFile(string
shaderFileName, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, string functionName, ShaderProfile
profile, TargetPlatform platform) { throw new NotImplementedException(); }
+ public static CompiledShader CompileFromFile(Stream
shaderSourceCode, int numberBytes, CompilerMacro[] preprocessorDefines,
CompilerIncludeHandler includeHandler, CompilerOptions options, string
functionName, ShaderProfile profile, TargetPlatform platform) { throw new
NotImplementedException(); }
+ public static CompiledShader CompileFromSource(string
shaderSourceCode, CompilerMacro[] preprocessorDefines, CompilerIncludeHandler
includeHandler, CompilerOptions options, string functionName, ShaderProfile
profile, TargetPlatform platform) { throw new NotImplementedException(); }
+ public static string Disassemble(byte[] shaderCode, bool
enableColorCode, string comments) { throw new NotImplementedException(); }
+ }
+}
Modified:
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderConstantCollection.cs
===================================================================
---
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderConstantCollection.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++
trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderConstantCollection.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -37,7 +37,7 @@
namespace Microsoft.Xna.Framework.Graphics
{
- public class ShaderConstantCollection : IEnumerable,
IEnumerable<ShaderConstant>
+ public sealed class ShaderConstantCollection : IEnumerable,
IEnumerable<ShaderConstant>
{
public IEnumerator<ShaderConstant> GetEnumerator()
{
Added: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderSemantic.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderSemantic.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/ShaderSemantic.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -0,0 +1,41 @@
+#region License
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
+*/
+#endregion License
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace Microsoft.Xna.Framework.Graphics
+{
+ [Serializable]
+ public struct ShaderSemantic
+ {
+ public override string ToString() { throw new
NotImplementedException(); }
+ public VertexElementUsage VertexElementUsage { get { throw new
NotImplementedException(); } set { throw new NotImplementedException(); } }
+ public int UsageIndex { get { throw new
NotImplementedException(); } set { throw new NotImplementedException(); } }
+ }
+}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Texture3D.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Texture3D.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Graphics/Texture3D.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -1,27 +1,27 @@
#region License
-/*
-MIT License
-Copyright � 2006 The Mono.Xna Team
-http://www.taoframework.com
-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:
-
-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.
+/*
+MIT License
+Copyright � 2006 The Mono.Xna Team
+http://www.taoframework.com
+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:
+
+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.
*/
#endregion License
@@ -72,4 +72,4 @@
public ResourceUsage ResourceUsage { get { throw new
NotImplementedException(); } }
public int Width { get { throw new NotImplementedException(); } }
}
-}
\ No newline at end of file
+}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Matrix.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Matrix.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Matrix.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -29,11 +29,14 @@
using System.Globalization;
using System.Runtime.InteropServices;
using System.Text;
+using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a matrix.</summary>
[Serializable, StructLayout(LayoutKind.Sequential)]
+ [TypeConverter(typeof(MatrixConverter))]
public struct Matrix : IEquatable<Matrix>
{
#region Public Constructors
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Plane.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Plane.cs 2007-01-14 17:10:38 UTC
(rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Plane.cs 2007-01-14 17:11:06 UTC
(rev 70989)
@@ -27,14 +27,14 @@
using System;
using System.ComponentModel;
-
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>
/// Defines a plane.
/// </summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.PlaneConverter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=f48fa5f25d27e8ff")]
+ [TypeConverter(typeof(PlaneConverter))]
public struct Plane : IEquatable<Plane>
{
/// <summary>Distance from plane to origin.</summary>
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Point.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Point.cs 2007-01-14 17:10:38 UTC
(rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Point.cs 2007-01-14 17:11:06 UTC
(rev 70989)
@@ -27,12 +27,13 @@
using System;
using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a point in 2D space.</summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.PointConverter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=f48fa5f25d27e8ff")]
+ [TypeConverter(typeof(PointConverter))]
public struct Point : IEquatable<Point>
{
/// <summary>Specifies the x-coordinate of the Point.</summary>
@@ -84,8 +85,7 @@
/// <returns>A System.String that represents the current
Point.</returns>
public override string ToString()
{
- System.Globalization.CultureInfo info1 =
System.Globalization.CultureInfo.CurrentCulture;
- return string.Format(info1, "{{X:{0} Y:{1}}}", new object[] {
this.X.ToString(info1), this.Y.ToString(info1) });
+ return string.Format("{{X:{0} Y:{1}}}", X, Y);
}
/// <summary>Determines whether two Point instances are
equal.</summary>
@@ -108,3 +108,4 @@
}
}
+
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Properties/AssemblyInfo.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Properties/AssemblyInfo.cs
2007-01-14 17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Properties/AssemblyInfo.cs
2007-01-14 17:11:06 UTC (rev 70989)
@@ -63,3 +63,8 @@
//
[assembly: AssemblyVersion("0.1.0.0")]
[assembly: AssemblyFileVersion("0.1.0.0")]
+
+[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
+[assembly: SecurityPermission(SecurityAction.RequestMinimum, UnmanagedCode =
true)]
+[assembly: SecurityPermission(SecurityAction.RequestMinimum, Execution = true)]
+[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification
= true)]
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Quaternion.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Quaternion.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Quaternion.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -27,12 +27,13 @@
using System;
using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a quaternion.</summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.QuaternionConverter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff")]
+ [TypeConverter(typeof(QuaternionConverter))]
public struct Quaternion : IEquatable<Quaternion>
{
/// <summary>Specifies the x value of the vector component of the
quaternion.</summary>
@@ -511,15 +512,7 @@
/// <returns>String that represents the object.</returns>
public override string ToString()
{
-#warning String builder?
- System.Globalization.CultureInfo info1 =
System.Globalization.CultureInfo.CurrentCulture;
- return
- string.Format(info1, "{{X:{0} Y:{1} Z:{2} W:{3}}}",
- new object[]
- {
- X.ToString(info1), Y.ToString(info1),
- Z.ToString(info1), W.ToString(info1)
- });
+ return string.Format("{{X:{0} Y:{1} Z:{2} W:{3}}}", X, Y, Z, W);
}
}
}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Ray.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Ray.cs 2007-01-14 17:10:38 UTC
(rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Ray.cs 2007-01-14 17:11:06 UTC
(rev 70989)
@@ -27,12 +27,13 @@
using System;
using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a ray.</summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.RayConverter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff")]
+ [TypeConverter(typeof(RayConverter))]
public struct Ray : IEquatable<Ray>
{
#region Public Fields
@@ -153,7 +154,7 @@
public override string ToString()
{
- return string.Format("/{Position:{0} Direction:{1}/}",
this.Position.ToString(), Direction.ToString());
+ return string.Format("{{Position:{0} Direction:{1}}}",
Position.ToString(), Direction.ToString());
}
#endregion
}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Rectangle.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Rectangle.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Rectangle.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -28,13 +28,14 @@
using System;
using System.Globalization;
using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a rectangle.</summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.RectangleConverter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff")]
+ [TypeConverter(typeof(RectangleConverter))]
public struct Rectangle : IEquatable<Rectangle>
{
/// <summary>Specifies the x-coordinate of the rectangle.</summary>
@@ -144,15 +145,7 @@
/// <returns>String that represents the object.</returns>
public override string ToString()
{
-#warning StringBuilder
- CultureInfo info1 = CultureInfo.CurrentCulture;
- return
- string.Format(info1, "{{X:{0} Y:{1} Width:{2} Height:{3}}}",
- new object[]
- {
- this.X.ToString(info1),
this.Y.ToString(info1),
- this.Width.ToString(info1),
this.Height.ToString(info1)
- });
+ return string.Format("{{X:{0} Y:{1} Width:{2} Height:{3}}}", X, Y,
Width, Height);
}
/// <summary>Gets the hash code for this object.</summary>
@@ -180,4 +173,4 @@
return !a.Equals(b);
}
}
-}
\ No newline at end of file
+}
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector2.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector2.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector2.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -28,12 +28,13 @@
using System;
using System.ComponentModel;
using System.Runtime.InteropServices;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a vector with two components.</summary>
[Serializable, StructLayout(LayoutKind.Sequential)]
- [TypeConverter("Microsoft.Xna.Framework.Design.Vector2Converter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=f48fa5f25d27e8ff")]
+ [TypeConverter(typeof(Vector2Converter))]
public struct Vector2 : IEquatable<Vector2>
{
/// <summary>Gets or sets the x component of the vector.</summary>
@@ -76,7 +77,7 @@
/// <returns>String that represents the object.</returns>
public override string ToString()
{
- return X.ToString() + ", " + Y.ToString();
+ return string.Format("{{X:{0} Y:{1}}}", X, Y);
}
/// <summary>
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector3.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector3.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector3.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -27,11 +27,14 @@
using System;
using System.Runtime.InteropServices;
+using Microsoft.Xna.Framework.Design;
+using System.ComponentModel;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a vector with three components.</summary>
[Serializable, StructLayout(LayoutKind.Sequential)]
+ [TypeConverter(typeof(Vector3Converter))]
public struct Vector3 : IEquatable<Vector3>
{
/// <summary>Gets or sets the x component of the vector.</summary>
@@ -162,7 +165,7 @@
/// <returns>String that represents the object.</returns>
public override string ToString()
{
- return "{X:" + X.ToString() + " Y:" + Y.ToString() + "
Z:" + Z.ToString() + "}";
+ return string.Format("{{X:{0} Y:{1} Z:{2}}}", X, Y, Z);
}
/// <summary>Determines whether the specified System.Object is equal
to the Vector3.</summary>
Modified: trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector4.cs
===================================================================
--- trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector4.cs 2007-01-14
17:10:38 UTC (rev 70988)
+++ trunk/Mono.Xna/src/Microsoft.Xna.Framework/Vector4.cs 2007-01-14
17:11:06 UTC (rev 70989)
@@ -27,12 +27,13 @@
using System;
using System.ComponentModel;
+using Microsoft.Xna.Framework.Design;
namespace Microsoft.Xna.Framework
{
/// <summary>Defines a vector with four components.</summary>
[Serializable]
- [TypeConverter("Microsoft.Xna.Framework.Design.Vector4Converter,
Microsoft.Xna.Framework, Version=1.0.0.0, Culture=neutral, PublicKeyToken=ff")]
+ [TypeConverter(typeof(Vector4Converter))]
public struct Vector4 : IEquatable<Vector4>
{
/// <summary>Gets or sets the x component of the vector.</summary>
@@ -140,15 +141,7 @@
/// <returns>String that represents the object.</returns>
public override string ToString()
{
-#warning Stringbuilder
- System.Globalization.CultureInfo info1 =
System.Globalization.CultureInfo.CurrentCulture;
- return
- string.Format(info1, "{{X:{0} Y:{1} Z:{2} W:{3}}}",
- new object[]
- {
- this.X.ToString(info1),
this.Y.ToString(info1),
- this.Z.ToString(info1),
this.W.ToString(info1)
- });
+ return string.Format("{{X:{0} Y:{1} Z:{2} W:{3}}}", X, Y, Z, W);
}
/// <summary>Determines whether the specified System.Object is equal
to the Vector4.</summary>
Property changes on: trunk/Mono.Xna/src/Microsoft.Xna.Framework.Game
___________________________________________________________________
Name: svn:ignore
- Microsoft.Xna.Framework.Game.prjx
Include.am
Microsoft.Xna.Framework.Game.csproj
Microsoft.Xna.Framework.Game.csproj.user
Microsoft.Xna.Framework.Game.mdp
bin
obj
+ Microsoft.Xna.Framework.Game.prjx
Include.am
Microsoft.Xna.Framework.Game.csproj
Microsoft.Xna.Framework.Game.csproj.user
Microsoft.Xna.Framework.Game.mdp
bin
obj
Microsoft.Xna.Framework.Game.xml
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches