GithubHelp home page GithubHelp logo

code's People

Contributors

brighthas avatar corehtml5canvas avatar hakond avatar kmcminn avatar nryoung avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

code's Issues

example-1.4:line 86 the third parameter did not used?

   function drawHand(loc, isHour) {
       // ...
   }

     // ...
   function drawHands() {
       // ...
       drawHand(hour*5 + (date.getMinutes()/60)*5, true, 0.5);
       drawHand(date.getMinutes(), false, 0.5);
       drawHand(date.getSeconds(), false, 0.2);
   }

I cannot find how the third parameter is used? Did it mean the length of the hand?

Brackets missing in Example-1.5

I believe it should have been
return { x: (x - bbox.left) * (canvas.width / bbox.width),
y: (y - bbox.top) * (canvas.height / bbox.height)
};
instead of(missing brackets)
return { x: x - bbox.left * (canvas.width / bbox.width),
y: y - bbox.top * (canvas.height / bbox.height)
};

in windowToCanvas method of example.js in example-1.5.

Upendra

Example 8-20, triangles act like squares

Object approaching the hypotenuse bounce as if it were a square extending the x of the x-most endpoint and the y of the y-most/least(depending on orientation) endpoint of the hypotenuse to an imaginary fourth corner.

Closing the polygon by creating a fourth point equal to the first gives the correct response.

Incorrect collisions detection

In example-8.10, try to update the 1st polygon points to:
[ new Point(25.5, 100), new Point(200.5, 200),
new Point(400.5, 200), new Point(600.5, 160),
new Point(600.5, 300), new Point(16.5, 300) ]
If you dragged any other polygon between the 1st polygon faced edges without real intersection, it will detect collision while there is no collision
detectcollisionissue

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.