canvas

clear pixels under a shape in HTML canvas

I am using an HTML canvas and javascript and I need to clear all of the pixels underneath a shape created by closing a path (for example, I am using flot, and I want to make rounded corners, and to do this, I first need to remove the square corners by drawing a curve on top of the corner to remove the desired pixels). Right now, I am do...

Is there a full implementation of the HTML5 Canvas object for GWT?

I'm looking to perform some dynamic charting based on a model via GWT on HTML5 compliant browsers. I know that the following library exists : GWT Canvas The problem is that this library does not support drawing text within the canvas so I can draw lines but no write text on my charts. I haven't been able to find any other plugin tha...

How to Draw a shape or bitmap into another Bitmap , Java/android

I want to draw a shape(many circles particularly) into a Specific Bitmap. I have never used canvas / 2D graphs etc. Anyone that can point me to the right direction to do what i want.? # As i see it i create a Drawable put the bitmap in it then "canvas-it" to the shapes i want etc but i really need some guideline ...

image buffer implementation in delphi

Context I am drawing to a canvas, this is updated regularly and it flashes. Logically thinking I assumed this is because my redraw method clears the Canvas then draws one element at a time to the canvas. so my idea was to write to a Timage then set the picture to the Timage. Information here is my code procedure Tmainwindow.Button3...

Capture Signature using HTML5 and iPad

Anyone know how this can be done? Would you use a canvas object, svg, jQuery, etc? ...

Draw image from pixel data arrays

If I have an array of pixel data in JavaScript, is there a good way to display it on an HTML page? On recent versions of Safari and Firefox, I can make a <canvas> element and use putImageData to display the pixels, but ideally a solution could work on older versions as well and more importantly, work on Internet Explorer. Another solut...

HTML5 Canvas Question

I have a Sketching app done in all HTML5 and Javascript, and I was wondering how I would create an Undo Button, so you could undo the last thing you drew. Any idea? Thanks! ...

clearRect question in Canvas

I am looking to create an Eraser for a drawing app in Canvas, and I have this code canvas.clearRect(x, y, width, height); How would i implement it? ...

SIlverlight: Can't find Image on Canvas

In my Canvas, I have an image object. I haven't set a source in it, but it has coordinates and a size. The tag is: <Image Canvas.Top="50" Canvas.Left="20" Height="68" Width="110" HorizontalAlignment="Left" Name="image1" Stretch="Fill" VerticalAlignment="Top" /> Here's the problem: When I move the mouse over it, I want to find it. With ...

How to do proper bounds checking for drawing on HTML5 canvas?

When drawing on a canvas in firefox, if you attempt to draw at or move to a point beyond the bounds of the canvas, an error will be thrown (this is copied/pasted directly from Firebug): An invalid or illegal string was specified" code: "12 Other browsers won't throw the error. This is for both the drawing methods (lineTo, arc, etc), ...

Is it possible to change the size of a dash of a line?

Hello, I am drawing a dashed line on the TImage Canvas and found out that the size of dashes is way too big for the drawing area. Is there a way to change the size of dashes of lines drawn on canvas? This is what i do to be able to draw dashed lines. Canvas.Pen.Style := psDash; Canvas.Polyline(myPoints); And i didn't find any Pen pro...

is Raphaël using canvas or svg?

I've been looking for a good vector solution, and have heard good things about Raphaël. But all over its docs it talks about defining canvases, which just made me confused. Is Raphaël a canvas or SVG library? ...

Flex - objects floating at the top of a canvas?

Hi, I want to have a canvas with some "floating" property. Basically when I add child to it, the child should float at the top. When I add the second child, it should float above the previous one. For example the canvas width is 100, and I have two VideoDisplay with width 100 and height 75. canvas.addChild(video0); // Or canvas.addChi...

How to flip images horizontally with HTML5

In IE, I can use: <img src="http://bit.ly/acuv47" style="filter:FlipH"> to implement a image flip horizontally, any way to flip horizontally in HTML5? (maybe use canvas?) thanks all :) ...

How to draw crosshatches on a TCanvas and specify the background color

I'm trying to make a "blank" background to place an image on top of. It's not too difficult to create crosshatches by placing a TImage on a form and doing the following: image1.Canvas.brush.Style := bsDiagCross; image1.canvas.brush.color := clWhatever; image1.canvas.FillRect(image1.clientrect); This works, and I get a crosshatch patt...

Raphael JS resize Canvas

Hi there I'm programming a debate-graph for my bachelor thesis with Raphael JS. point is, users can add nodes to the graph. eventually the graph gets really big and the canvas is still the same size. the canvas (in raphael js: paper) is inside another div with "overflow: scroll;", so lets ignore screen real estate so is there a way tha...

HTML5 Canvas Tag

Hi Everyone, I'm working with the Canvas Tag to draw stuff to the screen, I have like 3 different shapes on the screen, and I want to make them linkable, they could be at different coordinates depending on the users interaction, is this possible with this? Thanks! ...

HTML5 canvas hittesting

I have some images drawn on a HTML5 Canvas and I want to check if they are hit on mouse click. Seems easy, I have the bounds of the images, however the images are transformed (translated and scaled). Unfortunately, the context does not have a method to get the current transform matrix, and also, there is no API for matrices multiplicatio...

How do you access the children of a WPF Canvas class?

How do you access the children of a WPF Canvas class? It is a cool class and I like how you are able to add children. But once they are there, how to you look at them for reading their state and content. I know it is easy if you put the children in XAML. But what if you have added children to the canvas dynamically at run time? ...

Choosing right technology (SVG vs Canvas)

I'm writing an app for shape manipulation, such that after creating simple shapes the user can create more complex ones by clipping the shapes against each other (i.e. combining two circles together into a figure 8 stored using a single path rather than a group, or performing intersection of two circles to create a "bite" mark), and am t...