From c22baa8417ef28292cee06ac44d34e5407a5197f Mon Sep 17 00:00:00 2001 From: Konstantin Koch Date: Sat, 5 Sep 2015 14:48:26 +0200 Subject: [PATCH] Fix Alpha value for Fonts and fix buildCache invalidation. Kerning for the Font in the SampleContent project is deactivated for as this is not supported by our FontProcessor yet. --- .../Processors/FontDescriptionProcessor.cs | 8 +------- .../AlphaTestEffectSample/AlphaTestEffectSample.csproj | 6 ++++++ Samples/SampleContent/Fonts/Debug.spritefont | 2 +- Visual Studio/ANXVisualStudioPackage/BuildAppDomain.cs | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ANX.Framework.Content.Pipeline/Processors/FontDescriptionProcessor.cs b/ANX.Framework.Content.Pipeline/Processors/FontDescriptionProcessor.cs index ed187f6e..f3018973 100644 --- a/ANX.Framework.Content.Pipeline/Processors/FontDescriptionProcessor.cs +++ b/ANX.Framework.Content.Pipeline/Processors/FontDescriptionProcessor.cs @@ -249,7 +249,6 @@ namespace ANX.Framework.Content.Pipeline.Processors private Texture2DContent ConvertBitmap(Bitmap bitmap) { var bitmapContent = new PixelBitmapContent(bitmap.Width, bitmap.Height); - var destColor = new Color(); for (int x = 0; x < bitmap.Width; x++) { @@ -257,12 +256,7 @@ namespace ANX.Framework.Content.Pipeline.Processors { System.Drawing.Color sourceColor = bitmap.GetPixel(x, y); - destColor.R = sourceColor.R; - destColor.G = sourceColor.G; - destColor.B = sourceColor.B; - destColor.A = sourceColor.A; - - bitmapContent.SetPixel(x, y, destColor); + bitmapContent.SetPixel(x, y, Color.FromNonPremultiplied(sourceColor.R, sourceColor.G, sourceColor.B, sourceColor.A)); } } diff --git a/Samples/AlphaTestEffectSample/AlphaTestEffectSample.csproj b/Samples/AlphaTestEffectSample/AlphaTestEffectSample.csproj index 22427f31..6b833081 100644 --- a/Samples/AlphaTestEffectSample/AlphaTestEffectSample.csproj +++ b/Samples/AlphaTestEffectSample/AlphaTestEffectSample.csproj @@ -39,6 +39,9 @@ ..\..\bin\Debug\ANX.Framework.dll + + ..\..\bin\Debug\ANX.InputDevices.Windows.XInput.dll + ..\..\bin\Debug\ANX.InputSystem.Standard.dll @@ -48,6 +51,9 @@ ..\..\bin\Debug\ANX.RenderSystem.Windows.DX10.dll + + ..\..\bin\Debug\ANX.SoundSystem.Windows.XAudio.dll + diff --git a/Samples/SampleContent/Fonts/Debug.spritefont b/Samples/SampleContent/Fonts/Debug.spritefont index a98d8910..d43e9b63 100644 --- a/Samples/SampleContent/Fonts/Debug.spritefont +++ b/Samples/SampleContent/Fonts/Debug.spritefont @@ -29,7 +29,7 @@ sind. UseKerning steuert das Layout der Schriftart. Wenn dieser Wert wahr ist, werden Kerning-Informationen bei der Platzierung von Zeichen verwendet. --> - true + false