From bad6b272459191cdd688031bb36c97abc870055f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20K=C3=BCpper?= Date: Sun, 28 Apr 2013 10:15:40 +0200 Subject: [PATCH] Fixed webcam-image-aspect on ScreenProfiles. --- Vocaluxe/Screens/CScreenProfiles.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Vocaluxe/Screens/CScreenProfiles.cs b/Vocaluxe/Screens/CScreenProfiles.cs index 87ff1d71..b3c3740e 100644 --- a/Vocaluxe/Screens/CScreenProfiles.cs +++ b/Vocaluxe/Screens/CScreenProfiles.cs @@ -314,11 +314,9 @@ namespace Vocaluxe.Screens { if (_Snapshot == null) CWebcam.GetFrame(ref _WebcamTexture); - _Statics[_StaticAvatar].Texture = _WebcamTexture; - RectangleF bounds = new RectangleF(_WebcamTexture.Rect.X, _WebcamTexture.Rect.Y, _WebcamTexture.Rect.W, _WebcamTexture.Rect.H); - RectangleF rect = new RectangleF(0f, 0f, _WebcamTexture.Rect.W, _WebcamTexture.Rect.H); - CHelper.SetRect(bounds, out rect, rect.Width / rect.Height, EAspect.Crop); + _Statics[_StaticAvatar].Aspect = EAspect.Crop; + _Statics[_StaticAvatar].Texture = _WebcamTexture; } else _Statics[_StaticAvatar].Texture = CProfiles.Avatars[avatarNr].Texture;