Comments (2)
Hi dlr2. Yes, this is by design. Reason being, when you use DrawImage with an effect instead of a bitmap, it's not possible to generally define what the scaling will be. For bitmaps, we know what their bounds are. The scale factor is simple to determine. But effects often have infinite bounds, or bounds that aren't really what you'd expect.
Rest assured, there are many ways to get the behavior you want- like using a ScaleEffect or CropEffect to confine the effect to the correct bounds. It's a lot better for the app to do this, than for Win2D to try and create a scale transform which is invalid or unexpected.
This was also brought up with issue #31, which includes a very detailed explanation.
from win2d.
thanks for the answer...my scaling approach is working but I wanted to know if this was either by design or an oversight.
from win2d.
Related Issues (20)
- Somthing is wrong with `Microsoft::Graphics::Canvas::CanvasBitmap::CreateFromBytes` (not straight forward to call it)
- Use non-version-specific RID folders in NuGet package HOT 2
- Upgrade to v1.1.0 causes compiler error HOT 4
- `CanvasDrawingSession.DrawGlyphRun` renders emojis in monochrome when using color font and `CanvasDrawTextOptions.EnableColorFont` option HOT 2
- A referenced assembly was compiled using a newer version of Microsoft.Windows.SDK.NET.dll HOT 1
- How to enable Windows 11's Auto HDR feature on Win2D?
- Changelog for Win2D.uwp 1.27.1 HOT 3
- CanvasTextFormat throws in Unpackaged apps HOT 8
- Microsoft.Graphics.Canvas.winmd cannot be referenced HOT 5
- Microsoft.Graphics.Win2D fail to work with winui after 1.1.0 HOT 3
- Doc Bug in readme.md
- .net8 Cannot create instance of type Microsoft.Graphics.Canvas.UI.Xaml.CanvasControl HOT 1
- Installing the NuGet package results in a fatal error HOT 3
- Exception thrown: 'System.TypeInitializationException' in Microsoft.Graphics.Canvas.Interop.dll
- Strange problem with Microsoft.Graphics.Canvas.Geometry.CanvasPathBuilder HOT 13
- Question about performance
- Error installing Win2D NuGet in WinUI3 app HOT 2
- Text Color Bleeding Out of Outline HOT 2
- The print preview is very blurry at 200% zoom.
- Access Violation App Crash
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from win2d.