Dwitter | snydej (298)

+ New dweet
function u(t) {
} //
122/140


Please log in (or register) to post a dweet (copy-paste the code somewhere safe to save it meanwhile)


u(t) is called 60 times per second. t: Elapsed time in seconds. S: Shorthand for Math.sin. C: Shorthand for Math.cos. T: Shorthand for Math.tan. R: Function that generates rgba-strings, usage ex.: R(255, 255, 255, 0.5) c: A 1920x1080 canvas. x: A 2D context for that canvas.
show FPS hide FPS share fullscreen
remix of d/7060 by u/snydej

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • snydej: Golfed this one better and added a few details, like differing star sizes.
  • Load older comments...
  • snydej: Nope, that's what I thought too. The image data within the canvas is initially transparent (this affects the rendering of dweets that call x.drawImage(c, ... ) but there is also a background css property on the canvas that is set to white and this causes transparent areas of the canvas to show up as white regardless of what's behind them. You can try this out by locally tweaking the css for the body element that contains the canvas. On most dweets you don't see any part of this element unless the dweet is fullscreened but there are exceptions like d/7084 . I don't know what the best way to handle that would be.
  • donbright: :)
  • iverjo: #stars

Please log in (or register) to comment.

show FPS hide FPS share 1 remix fullscreen

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
127/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
141/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • snydej: This looks WAY cooler if you add x.filter='blur(4px)';
  • akm: woah, thats an awesome dweet and some crazy codegolfing!!
  • joeytwiddle: If I add that filter, flames start coming out of my laptop!

Please log in (or register) to comment.

show FPS hide FPS share fullscreen

function u(t) {

}//
146/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • snydej: Mostly an accident, but it looks cool anyway
  • Load older comments...
  • DirtyDan: Pretty sure most dweets are, lol
  • artfarnaa: Every artist from every domain says same thing. Nothing great emerges without the author saying it was just an accident.
  • Lazy1337: Not always true in creative coding/demoscene tbh

Please log in (or register) to comment.

show FPS hide FPS share 1 remix fullscreen
remix of d/6995 by u/snydej

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • snydej: I think I've squeezed all I can out of this one.

Please log in (or register) to comment.

show FPS hide FPS share 1 remix fullscreen
remix of d/6994 by u/snydej

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

remix of d/6990 by u/snydej

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

Please log in (or register) to comment.

show FPS hide FPS share 1 remix fullscreen
remix of d/6988 by u/snydej

function u(t) {

}//
140/140


Please log in (or register) to post as a new dweet (copy-paste code somewhere safe to save it meanwhile).

  • snydej: I used a different strategy for the transform and managed to salvage enough characters to animate it.

Please log in (or register) to comment.

Loading...
Next page