These forums are currently read-only due to receiving more spam than actual discussion. Sorry.

It is currently Sat Dec 02, 2017 4:25 pm Advanced search

Canvas : stroke draws 2 pixels wide with opacity

Here you can discuss things related to HTML and the Web in general that do not fit in to other categories.

Canvas : stroke draws 2 pixels wide with opacity

Postby anjanesh » Fri May 22, 2009 4:50 am

Has anyone else noticed this ?

https://developer.mozilla.org/en/Canvas ... #section_4
ctx.strokeRect(50,50,50,50); shows an image with the inner most rectangle which is black & 1 pixel in width.

But if you look at the example, https://developer.mozilla.org/samples/c ... _rect.html
it shows the inner most rectangle as 2 pixels wide and lighter than black.
This is happening on all browsers - FF 3.0.10, FF 3.5 beta 4, Safari 4 beta and Chrome 2 beta.

How do I get a pixel wide line ?

Thanks
anjanesh
<h6>
 
Posts: 1
Joined: Thu May 21, 2009 9:34 am

Postby zcorpan » Thu Sep 17, 2009 8:10 am

See "Q: Why did you start x and y at 0.5? Why not 0?" in http://diveintohtml5.org/canvas.html
zcorpan
<article>
 
Posts: 807
Joined: Tue Feb 06, 2007 8:29 pm
Location: Sweden


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 0 guests