のない私は、この問題の解決策を見つけることができません。Monogameテクスチャの色
私は質感や、いくつかのプリミティブを描画するDrawUserPrimitivesで四角形を作成するためにVertexPositionTextureを使用しています。
Rectangleがある:
tmpPoint.VerticesList[0] = new VertexPositionTexture(new Vector3(-size, size, 0), new Vector2(0, 0));
tmpPoint.VerticesList[1] = new VertexPositionTexture(new Vector3(size, size, 0), new Vector2(1f, 0));
tmpPoint.VerticesList[2] = new VertexPositionTexture(new Vector3(-size, -size, 0), new Vector2(0, 1f));
tmpPoint.VerticesList[3] = new VertexPositionTexture(new Vector3(size, -size, 0), new Vector2(1f, 1f));
効果アップsetted:
Effect = new BasicEffect(game.GraphicsDevice) {
VertexColorEnabled = true,
TextureEnabled = true };
Effect.EnableDefaultLighting();
と描画方法:
public void DrawRectangle()
{
originalBlend = game.GraphicsDevice.BlendState;
game.GraphicsDevice.BlendState = BlendState.AlphaBlend;
Effect.World = PointScale * PointRotation * PointTranslation;
Effect.CurrentTechnique.Passes[0].Apply();
game.GraphicsDevice.DrawUserPrimitives<VertexPositionTexture>(PrimitiveType.TriangleStrip, VerticesList, 0, vertexBuffer.VertexCount/2); 0, 0, 4, 0, 2);
game.GraphicsDevice.BlendState = originalBlend;
}
すべての罰金が、質感を持つ矩形が何色を持っていない、唯一のアルファチャンネル黒の勾配。あなたは
Effect.EnableDefaultLighting();
Effect.LightingEnabled = true;
VertexColorEnabled = true;
色が作業している...
が、テクスチャ用の画像は、次のとおりです。
私は削除しようとしたとき混乱するかもしれませんが、既にWindows 7のマシン上の色でうまく動作します。私がTFSでチェックインしたとき、すべてのc私はこの問題を抱えています。私はまだWindows 7マシンを持っていません。 Cで
DLLの::\プログラムファイル(x86の)\ MonoGame \ v3ではしかし、私は何の問題もなく、ホストマシン上で... Windows 7の実行ファイル、なし、成功して別のマシンに
をチェックします。 0 \アセンブリ\ DesktopGLパスCにおける3.5.1.1679
DLLのです:\ MSBuildの\ MonoGame \ V3.0の\ツールはデバッグ中3.5.1.1679
DLLの\です\プログラムファイル(x86の)パスは3.5.1.1679
(唯一の違いが記載されている)
ロードアセンブリ:
のMscorlib.dll 1076年6月4日
System.Core.dll 4.6.1055.0
System.dllの4.6。 1075.0
System.Drawing.dll 4.6.1068.2
System.Windows.Forms.dll 4.6.1055。Cで
DLLの::\プログラムファイル(x86の)\ MonoGame \ v3の問題を持つ別のWindows 10(Windowsのすべてのバージョン7+)機械(差なし)で0
\プログラムファイル(x86の)\ MSBuildの\ MonoGame \ V3.0の\ツールはデバッグ中3.5.1.1679
DLLのです:0.0 \アセンブリ\ DesktopGLパスはCで3.5.1.1679
DLLのです\ pathは3.5.1.16です(唯一の違いが記載されている)79
ロードアセンブリ:
がmscorlib.dll 1080年4月6日
System.Core.dll 4.6.1038.0
システム。 dll 4.6.1081.0
System.Drawing.dll 4.6.1078.0
のSystem.Windows.Forms.dll 4.6.1038.0
オープン問題:https://github.com/mono/MonoGame/issues/5029
UPDATE:それが唯一のインテルHDグラフィックス上で動作していないどのようなようだが、Radeonの上とNVidiaはうまく動作します...
コードを投稿してください。 [mcve] – MickyD
ミッキー、ありがとう。完了しました。 – sahap
私は新しい動作を調べました。 – sahap