antialiasing

Anti-aliased Arc Pygame

我的梦境 提交于 2020-01-14 09:21:06
问题 I am trying to code a simple circle timer in Python using Pygame. At the moment it looks like this: As you can see, the blue line is very wavy and has white dots in it. I am achieving this blue line by using pygame.draw.arc() function, but it is not anti-aliased and looks bad. I would like it to be anti-aliased, but gfxdraw module which should let me achieve this, doesn't support arc width selection. Here's code snippet: pygame.draw.arc(screen, blue, [center[0] - 120, center[1] - 120, 240,

QPainter::rotate disables antialiasing of drawn text

谁说我不能喝 提交于 2020-01-14 07:45:08
问题 I use QPainter::setRenderHint(QPainter::Antialiasing, true) to tell Qt that I want it to antialias any drawing I do (in this case, text drawn with drawText() ). This works fine and the text looks good, until I want to rotate the pixmap I'm drawing to e.g. Painter.translate(0, height()); Painter.rotate(-90); (to rotate the QPainter 90 degrees counterclockwise and bring it back into view) The call to rotate() seems to disable antialiasing for any text drawn - the text is drawn at the correct

iPhone: problem rotating a UIView - doesn't look right

非 Y 不嫁゛ 提交于 2020-01-07 02:32:26
问题 I am adding a simple UIView to my app. This works fine, until I use the 'transform' property to rotate it: myView = [[UIView alloc] initWithFrame:CGRectMake(50, 50, 100, 100)]; myView.backgroundColor = [UIColor whiteColor]; myView.transform = CGAffineTransformMakeRotation(-0.2); [self.view addSubview:myView]; //self.view is just another generic UIView The added view is rotated, but has jagged edges - i.e. the edges have not been anti-aliased. Here's an example of what I mean: aliased vs. anti

Can't seem to disable anti-aliasing in Android

蓝咒 提交于 2020-01-05 07:27:10
问题 I'm new to Android, and I've finished a game which was meant to feature pixel art. I was going to scale up my images (imageviews and bitmaps drawn to canvas) from small pixelated png files. The thing is, I could not seem to disable anti-aliasing whatever method I tried. The image was always blurred. All my images are in one 'drawable' folder. I tried android:antialias="false" within the ImageView in the xml. Tried the method described here: http://www.41post.com/4241/programming/android

OpenTK - How to achive antialiasing using accumulation buffer

风格不统一 提交于 2020-01-05 07:09:16
问题 Im trying to achieve antialiasing using accumulation buffer, but i don't fully understand what i'm doing wrong. The only effects im getting is drop down in fps, which i know is to be expected in this method. The jitter table is a table filled with floats to make antialiasing look smoother. I think it's probably because setting MartixMode doesnt change UniformMatrix method i later use in drawing objects. Here's my OnRenderFrame method: protected override void OnRenderFrame(FrameEventArgs e) {

How to disable anti-aliasing when scaling up an imageview in android?

会有一股神秘感。 提交于 2020-01-04 05:11:07
问题 I have a pixel art that I want to scale up. The problem is when I scale it up, it gets all blurred cause of the antialiasing. Is there a way to disable antialiasing directly from xml? 回答1: i hope its useful Bitmap bmpSource = BitmapFactory.decodeResource(getResources(), SourceFileId); //100 is dimension to resizing image size //Passing filter = false will result in a blocky, pixellated image. //Passing filter = true will give you smoother edges Bitmap bmpScaled = Bitmap.createScaledBitmap

Is there any way to fix the horrendous toolbar icons after the Juno update?

我的未来我决定 提交于 2020-01-03 16:41:11
问题 At least on Windows 7, it looks like the title bar color may have been changed to blue. However, the title bar icons were designed only to be used on a light gray bar rather than using alpha transparency for antialiasing. Note the white highlights around the edge of the green circle "run" icon. The icons look horrendous, like we're in 1995. Is this how it appears on other Windows 7 user's installations as well? I noticed there's theming, and the closest I can find to something that works is

RoundRectangle2D clip is not very smooth

坚强是说给别人听的谎言 提交于 2020-01-03 05:14:31
问题 I have a JPanel that i want to clip the corners so that it has rounded edge. Here is what i am doing. ((Graphics2D)g).setRenderingHint(RenderingHints.KEY_ANTIALIASING,RenderingHints.VALUE_ANTIALIAS_ON); g.setColor(color); Shape s = new RoundRectangle2D.Double(0, 0, width, height, arc, arc); g.setClip(s); So notice that i am setting the clipping to a RoundRectangle2D. Also i am setting anti-aliasing still my rounded edges are really jagged. Soft clipping example this link has a way to do soft

Change font rendering (non-antialiased) with pango

会有一股神秘感。 提交于 2020-01-03 04:49:12
问题 How do I render a string with pango using custom antialiasing and hinting settings? I tried PangoCairo.set_antialias(cairo.ANTIALIAS_NONE) (in pygtk), but it had no effect. I'd like to be able to change freetype's rendering parameters, like I can do via fontconfig/ fonts.conf , but at runtime. (This is on Linux.) Any ideas? 回答1: Well, I'm not sure if understood you right, but I usually use cairo_set_antialias () in my C-code, though I don't know an equivalent in PyGTK. As far as I understand

How Swiffy antialias canvas?

▼魔方 西西 提交于 2020-01-03 03:18:07
问题 I don't understand how swiffy succefully antialias clipping mask when it exports a flash animation that contains mask. Here is my exemple : Full canvas, with mask. Super dirty in Chrome : http://goo.gl/n8yB5h And a swiffy export where there is a picture that move inside a mask. Super clean on Chrome : http://www.creaktif.com/lab/test4.html I tried a lot of things, including draw a 200% canvas then scale it down, adding more points when I draw my mask, but no way to get a clean mask in my