js1024

js1024

Annual JavaScript Golfing Competition

CLOSED. Starts on 1 July

Mirror 1k
by TomCat
1024/1024 bytes - HTML project

Run Demo Minified code Readable code

W2hdV0FTTUVSWy9oXQ0KDQpXQVQgdG8gSFRNTCBmcmFtZXdvcmsgZm9yIHNpemVjb2RlcnMNCg0KTGV0J3MgYmVjb21lIGEgd2FzbWVyIDopIFdyaXRlIHlvdXIgc2luZ2xlLWZpbGUtaW50cm8gaW4gcHVyZSBXZWJBc3NlbWJseS4NCg0KW2JdIFJlcXVpcmVtZW50cyBbL2JdDQoNCiAgICAtIHdhdCAyIHdhc20gdHJhbnNsYXRvciBsaWtlIFdBQlQgLSBbbGlua11odHRwczovL2dpdGh1Yi5jb20vV2ViQXNzZW1ibHkvd2FidFsvbGlua10NCiAgICAtIGJpbmFyeSAyIGJhc2U2NCB0ZXh0IGNvbnZlcnRlcg0KDQpbYl0gVXNhZ2UgWy9iXQ0KDQpHaXZlIHRoZSBuYW1lIG9mIHlvdXIgd2F0IGZpbGUgdG8gdGhlIG1ha2VyICh3aXRob3V0IGV4dGVuc2lvbikgYW5kIGl0IHdpbGwgbGluayB0b2dldGhlciB0aGUgaGVhZCZ0YWlsIG9mIGh0bWwgd2l0aCB0aGUgYmFzZTY0IGNvZGVkIHdhc20gYmluYXJ5Lg0KDQpJZiB5b3UgZ2l2ZSBhIDJuZCBwYXJhbWV0ZXIgYXMgYW4gb3B0aW9uIChsaWtlICJtaW4iKSwgdGhlbiBpdCB3aWxsIHVzZSB0aGUgbWluaW1hbCB2ZXJzaW9ucyBvZiBoZWFkJnRhaWwgaW5zdGVhZCBvZiB0aGUgc3RhbmRhcmQgb25lcy4NCg0KRm9yIG1vcmUgaW5mb3JtYXRpb24gb24gd2FzbSBjb2RpbmcgY2hlY2sgdGhlIHNhbXBsZTEud2F0IGZpbGUuDQoNCltiXSBBdXRob3IgWy9iXQ0KDQpJdCB3YXMgd3JpdHRlbiBieSBUYW3DoXMgS2Fwcm9uY2FpIGFrYSBUb21DYXQvQWJhZGRvbi4NCg0KW2JdIENvbnRhY3QgWy9iXSANCg0KRS1tYWlsOiBrYXBvckBkaXQuaHUgR2l0SHViOiBLYXByb25jYWkNCg0KW2JdIFVzZWQgcmVmZXJlbmNlcyBbL2JdIA0KDQogICAgLSBNaWNyb1c4IFdBU00gU2l6ZWNvZGluZyBTZW1pbmFyIGJ5IEV4b3RpY29ybiAvIEljZWJpcmQgW2xpbmtdaHR0cHM6Ly95b3V0dS5iZS91LU92c2JEcUxBWVsvbGlua10NCiAgICAtIHAwMSBIZW5yaSdzIGJsb2cgW2xpbmtdaHR0cDovL3d3dy5wMDEub3JnL1svbGlua10NCiAgICAtIEFzc2VtYmx5U2NyaXB0IGV4YW1wbGVzIFtsaW5rXWh0dHBzOi8vd3d3LmFzc2VtYmx5c2NyaXB0Lm9yZy9leGFtcGxlcy5odG1sWy9saW5rXQ0KICAgIC0gQmVuIFNtaXRoJ3MgUmF3IFdlYkFzc2VtYmx5IERlbW9zIFtsaW5rXWh0dHBzOi8vZ2l0aHViLmNvbS9iaW5qaS9yYXctd2FzbVsvbGlua10NCg==

Ratings

Anonymous participant 87/100: Interesting approach!
Anonymous participant 83/100: no comment
Anonymous participant 89/100: Insightful demo!
Anonymous participant 70/100: no comment
Anonymous participant 85/100: Webassembly, cool! Could you make balls reflect in each others too?
Anonymous participant 80/100: impressive tech! will be interesting to see how this is used in future competitions
Anonymous participant 89/100: A ray tracer, but also probably the first JS1024 submission with WebAssembly! It is well known that it is hard to embed a binary into JS1024 submission and you lose a lot of efficiency, so this is actually a mere 555 bytes! Not really the best choice but may be handy for some future submissions.
Anonymous participant 77/100: How about a WebAssembly category with bespoke shim next year?? Well executed, but the 3D seems impossible?: red and blue balls move in a plane parallel to the screen, but the drawing order suggest something like the Penrose triangle. And the mirror should show a side view of the scene, not an horizontally inverted image.
Anonymous participant 89/100: no comment
Anonymous participant 85/100: I haven't tried WebAssembly. This looks nice.

Public comments

Anonymous the reflections are here :) https://www.shadertoy.com/view/WtsfDX 1659297014


Leave a comment