motion-point-blur.js

total 0
used 0
limit 0
/* title: Motion Blur Class categories: blur files: head point pointlist stage mouse dragging ../point_src/random.js ../point_src/arc.js ../point_src/motion.js --- */ class MainStage extends Stage { // canvas = document.getElementById('playspace'); canvas = 'playspace' mounted(){ let p = this.point = this.center.copy() p.color = 'purple' this.dragging.add(p) this.tick = 0 } firstDraw(ctx) { ctx.lineCap = 'round' } randomMove(p=this.point, c=this.center, v=200){ if(this.tick % random.int(20, 50) == 0) { p.x = c.x + random.int(-v, v) p.y = c.y + random.int(-v, v) p.radius = random.int(1, 20) } } draw(ctx){ this.tick++; this.clear(ctx) this.randomMove() this.point.motion.linear(ctx) } } stage = MainStage.go(/*{ loop: true }*/)
Run
Meta Data
title Motion Blur Class
imports ()
files ('head', 'point', 'pointlist', 'stage', 'mouse', 'dragging', '../point_src/random.js', '../point_src/arc.js', '../point_src/motion.js')
unused_keys ()
unknown_keys ('categories',)
categories ['blur']
filepath_exists True
path motion-point-blur.js
filepath motion-point-blur.js
clean_files ('../point_src/core/head.js', '../point_src/pointpen.js', '../point_src/compass.js', '../point_src/center.js', '../point_src/point-content.js', '../point_src/pointdraw.js', '../point_src/relative-xy.js', '../point_src/pointcast.js', '../point_src/point.js', '../point_src/pointlistdraw.js', '../point_src/pointlistgradient.js', '../point_src/pointlistshape.js', '../point_src/pointlistgenerator.js', '../point_src/unpack.js', '../point_src/pointlist.js', '../point_src/pointlistpen.js', '../point_src/stage-hooks.js', '../point_src/stage-resize.js', '../point_src/functions/resolve.js', '../point_src/stage.js', '../point_src/events.js', '../point_src/automouse.js', '../point_src/functions/clamp.js', '../point_src/distances.js', '../point_src/protractor.js', '../point_src/text/beta.js', '../point_src/dragging.js', '../point_src/random.js', '../point_src/arc.js', '../point_src/motion.js')
markdown {'html': '', 'content': 'title: Motion Blur Class\ncategories: blur\nfiles:\n head\n point\n pointlist\n stage\n mouse\n dragging\n ../point_src/random.js\n ../point_src/arc.js\n ../point_src/motion.js\n---'}