Tagged Questions
2
votes
3answers
113 views
Making an Object “transparent” for Mouse Events?
I'm working on a project with HTML5 Canvas and KineticJS. A half-transparent overlay (a KineticJS group or layer) is placed all over the scene. The problem is: Mouse events bound to KineticJS objects ...
0
votes
0answers
99 views
Replacing the innerHTML of an HTML p tag- event not firing
I have the following JS function, which I am using to detect when the cursor is hovering over a particular image on an HTML5 canvas:
function cursorOverAssetsBox(mouseX, mouseY){
if((mouseX >= ...
0
votes
3answers
216 views
HTML5 canvas events not working properly in IE
the below code functions like the pencil tool of MSpaint, the below code work properly for all the browsers except IE, it gives no error in IE as i have included a script file to make canvas tag run ...
0
votes
0answers
60 views
GWT Canvas doesn't fire events
I am trying to register mouse event listeneres to a com.google.gwt.canvas.client.Canvas in my GWT application.
I can see the canvas, when i open the application. I can draw on it programmatically. ...
1
vote
1answer
348 views
mouse-over HTML-5 canvas image in animation to play/pause it
I have a HTML-5 canvas in which there is a circle which is animated. Refer to the following JS code.
function doFirst(){
canvas = document.getElementById('myCanvas');
context = ...
0
votes
2answers
126 views
Multiple set Interval time
Here in this animation I've made two functions for two balls, but there is no second ball i am getting in this canvas.
My code for both balls-
function draw() {
ctx.clearRect(0, 0, 300, 300);
...
2
votes
1answer
86 views
How do i add image to this canvas ball?
I am trying to make a simple game, though if i need an image for my bouncing ball then how do i do this?
I am doing this-
function draw() {
ctx.clearRect(0, 0, 300, 300);
if (ctx.getContext) ...
1
vote
3answers
156 views
remove keydown delay in JavaScript?
Well, when you hold a key on your keyboard, after the first fire there is a 1sec delay.
You can go ahead and open notepad and hold a key (e.x 'x') you'll see after the first fire there is a delay.
...
0
votes
1answer
160 views
Mouse Coords over Multiple Canvases HTML5/Javascript
I'm trying to use 2 canvases, I want them both to accept an image dropped into them and use mouseclicks to manipulate the images. Here is the code i'm working on.
I have it where if I only have the ...
0
votes
1answer
66 views
HTML 5 Canvas Co-Ordinates and browser pixels corelation?
I am trying to get HTML 5 canvas for my application work as a drawing board. The problem I am facing is:
The drawing is happening at some offset from the mouse pointer. I am using the Jquery .offset ...
0
votes
1answer
242 views
Javascript/HTML5 - Making a canvas animation using WASD to move around a rectangle. Trouble implementing A and W keys
I'm making a simple canvas where the user uses WASD to move a rectangle up, left, down, right, respectively. The animation works fine for S and D keys, but when I tried to do the a key it doesn't ...
5
votes
1answer
309 views
JavaScript, using a function to change the text displayed in a HTML <p> tag
I have a HTML5 canvas, which is displaying a number of images and a paragraph of text on the page underneath the canvas. I want the text in the paragraph to be updated to display a different element ...
0
votes
1answer
143 views
How to save an image of size a*a in HTML5 canvas, canvas.toDataURL() and later draw it in different sizes, a*a / 2a*2a?
How to save a single image of size a * a using HTML5 canvas, canvas.toDataURL() and later draw it in different sizes, a * a / 2a * 2a without distortion?
OR
I have a HTML5 / JavaScript web ...
1
vote
1answer
91 views
Make grid half clickable
I am making a crossowrd puzzle in HTML5. For that I have created a grid on canvas using rectangles in javascript. I want only the blue rectangles to be clickable and rest of the rectangles not ...
0
votes
0answers
46 views
How to add event handler for the particals?
function create_map_point()
{
// map points
var runnerTexture = new THREE.ImageUtils.loadTexture('map_pin.png' );
mapi = new THREE.MeshBasicMaterial({map: runnerTexture,overdraw:true});
//mapi = new ...