![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
![]() |
| | Thread Tools | Display Modes |
| | #1 (permalink) |
| Guest | Re: Drawing difference between Avaon and GDI Hello Lei, I just wrote a blogpost on how you can get a sharp WPF line while keeping the anti-aliased effects for diagonal/curved lines, check out the SnapsToDevicePixels property: http://blogs.msdn.com/seema/archive/...red-lines.aspx Enjoy! SeemaR http://blogs.msdn.com/seema/ "Lei Jiang" wrote: > I agree with you. Anti-aliasing really make lines looks smooth, but in some > situation, I want the lines looks exactly the same width. If Avalon provide > an option that make me could aligns the line with the center of a pixel, it > would be great. In my situation, the precise position of a rectangle is not > important, but a rectangle with different line width is not acceptable. > > "Frank Hileman" <frankhil@no.spamming.prodigesoftware.com> дÈëÏûÏ¢ > news:uPhlDxlWFHA.2256@TK2MSFTNGP14.phx.gbl... > > For the rectangular labels in green, specifically: it is clear here that > you > > need a rectangle positioning and width that is precisely aligns the center > > of a pixel with the center of the rectangle lines. If Avalon does not > > provide an easy way to do this, it should be added, as it is a common > > requirement. > > > > Anti-aliasing does not solve the fractional pixel problem. As you can see, > > it can make the problem worse. > > > > In VG.net you can control anti-aliasing with a RenderAppearance property. > If > > you turn off anti-aliasing for the rectangle you will get the correct > > effect. This property can also be set on a composite object, so that all > > elements within are affected. A similar property in Avalon would be very > > helpful. It would also be helpful to have pixel-perfect control over > > positioning and sizes. > > > > Another thing that would help is control over the gamma correction used > when > > computing the fractional pixel values for anti-aliasing. A gamma > correction > > that looks good over a light background generally works poorly over a dark > > background. > > > > As a "fudge" in Avalon you can make line widths thicker. This will not > > correct the true problem of pixel misalignment -- some lines will appear > > thicker than others. Pablo's comment about the resolution of display > devices > > increasing is true in the long-term -- but I suspect the term is very long > > in the real world, perhaps 10 years to be widespread, and longer for > > industrial applications, which often use low-end display devices. > > > > Regards, > > Frank Hileman > > > > check out VG.net: http://www.vgdotnet.com > > Animated vector graphics system > > Integrated Visual Studio .NET graphics editor > > > > "Lei Jiang" <code@263.net> wrote in message > > news:%23$%23CLFXWFHA.3712@TK2MSFTNGP09.phx.gbl... > > >I am porting a graphics program from GDI to Avalon and found there are > some > > > differences between the drawing in Avalon and that in GDI. > > > > > > Please see the attachment(I have compressed them to save the bandwidth), > > > lines and texts in both picture use the same > > > color and size, but it seems the lines and texts in Avalon are more > > > "obscure" and "gloomy". This makes the drawing not that clear. > > > > > > Is there any method that could make the drawing in Avalon more "birght" > > > and > > > "clear", just like that in GDI? > > > > > > Thanks! > > > > > > > > > > > > > > > > > > > |
My System Specs![]() |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Canvas does not allow drawing | PhredBear | Vista General | 2 | 08-13-2008 02:07 PM |
| paintshop drawing etc | Mudnox | Vista General | 0 | 10-30-2007 07:17 AM |
| Drawing Packages | Andrew Aitchison | Vista General | 1 | 05-05-2007 05:16 PM |
| Drawing over title bar | Keith Patrick | Avalon | 5 | 03-31-2007 03:38 PM |
| WPF Custom Drawing | Weston Weems | Avalon | 3 | 08-24-2006 11:42 AM |