Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in 
CSDb User Forums


Forums > CSDb Entries > Release id #116340 : Time Machine
2022-01-22 01:04
Shadow

Registered: Apr 2002
Posts: 355
Release id #116340 : Time Machine

Multiplexers are cool, and multiplexed DYSPs are of course even cooler!
I started thinking about the record here (32 sprites, 100 pixels y-movement) and when I calculate it, it seems mathematically impossible.
Taking 32 evenly distributed points along a 50-radius sine wave, I end up with at least 9 coordinates that are within 21 y pixels of each other, which would mean lines with 9 sprites on them.
Now, this demo uses added sines, and maybe it's here I'm messing up, because when experimenting with this, no matter what I try with two added sines, I always end up with worst-cases that are even worse than the original single sine.
Am I missing some simple math, or is this just a case of good old demo magic cheating somehow? :)
 
... 2 posts hidden. Click here to view all posts....
 
2022-01-22 02:31
Groepaz

Registered: Dec 2001
Posts: 10353
What i have done here and there... if there is some "impossible" combination of coordinates/sprite sprite positions - just skip it, move some sprite a line up or down. noone will notice it =)
2022-01-22 05:06
Raistlin

Registered: Mar 2007
Posts: 378
Quote: What i have done here and there... if there is some "impossible" combination of coordinates/sprite sprite positions - just skip it, move some sprite a line up or down. noone will notice it =)

I think that’s the point here though… “no-one will notice it” is fine for regular demos… ones that are going for world records, though, can’t really do that.. it would be “cheating” ;-)
2022-01-22 11:40
Groepaz

Registered: Dec 2001
Posts: 10353
Wow cheating in demos? WTF
2022-01-22 12:40
JackAsser

Registered: Jun 2002
Posts: 1909
Quote: Wow cheating in demos? WTF

Hahaha indeed WTF. :)
2022-01-23 01:33
Raistlin

Registered: Mar 2007
Posts: 378
Quote: Hahaha indeed WTF. :)

You know what I mean though… I’m sure in HCL’s scrolltext somewhere he mentioned that the records were achieved without cheating on the sinuses. Like, it would be something like:-

Y = A * Sin(B) + C * Sin(D)

Without any further modification.

While (!bSpriteFits) Y++

would be “cheating”. I know most people wouldn’t see it - but if that was happening, it would be hard to say “I beat you, Crossbow!” (Or whoever).
2022-01-23 02:05
Groepaz

Registered: Dec 2001
Posts: 10353
Reminds me of the scrolltext where crossbow explained the vertical rasters =)
2022-01-23 08:07
ChristopherJam

Registered: Aug 2004
Posts: 1206
The first couple of harmonics of a triangle wave will get you there.

cos(th)*45+cos(th*3)*5 ranges from -100 to 100, and the closest gap in a sorted sprite list of 32 evenly distributed phases never drops below 21.5

You get a slightly more comfortable function from cos(th)*44.13+cos(th)*5.87. Minimum gap for that is around 22.9. Bump the overall range to 100.9 and you'd increase the gap to a touch over 23.
2022-01-23 11:40
Shadow

Registered: Apr 2002
Posts: 355
Thanks CristopherJam, cool to see that there was a mathematical solution to this!
In my very non-mathematical try-different-values-and-see-what-happens I never stumbled upon this since I never tested with two waves with so large difference in amplitude.
The resulting wave btw. is very triangular-looking, but it still is the result of two correct waves added, so not at all cheating.
A satisfying end to this little mystery!
2022-01-24 09:20
HCL

Registered: Feb 2003
Posts: 698
Oh yeah.. i'm the subject of another deep discussion *again* ;)..

Haha, i actually found the bunch of c-programs that i used for generating those sinuses, ending up with almost one program specialized for the properties of each part in the demo.. I will save you from that mess, but yes they loop through some million sinuses, first finding the best angular offsets for the purpose, and then trying a bunch of fraction offsets to the results to see if the quantization (float -> integer) accidentally generates a better result..

Simply rocket science at its best :D.
2022-01-24 14:49
Groepaz

Registered: Dec 2001
Posts: 10353
As always, if you can't make it work using brute force, use a bigger hammer :=)
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Tom/TRS
Steel/SCS&TRC/G★P
Didi/Laxity
iAN CooG/HVSC
Alakran_64
DeMOSic/StArZ^HF^BCC
Mason/Unicess
Marq/Fit^Lieves!Tuor..
Dwangi/Fairlight
Scooby/G★P/Light
Guests online: 59
Top Demos
1 Edge of Disgrace  (9.6)
2 Coma Light 13  (9.6)
3 Bromance  (9.6)
4 Memento Mori  (9.6)
5 Uncensored  (9.6)
6 Comaland 100%  (9.6)
7 Lunatico  (9.5)
8 Unboxed  (9.5)
9 Wonderland XII  (9.5)
10 Christmas Megademo  (9.5)
Top onefile Demos
1 Copper Booze  (9.6)
2 Daah, Those Acid Pil..  (9.5)
3 Cityscape 2730  (9.5)
4 Plasma Ninja  (9.5)
5 Dawnfall V1.1  (9.5)
6 Lovecats  (9.5)
7 Barry Boomer - Trapp..  (9.5)
8 Square Booze  (9.5)
9 Elite Code Mechanics  (9.5)
10 To Norah  (9.4)
Top Groups
1 Booze Design  (9.4)
2 Oxyron  (9.3)
3 Crest  (9.2)
4 Lethargy  (9.2)
5 Censor Design  (9.2)
Top Graphicians
1 Mirage  (9.8)
2 Archmage  (9.7)
3 Electric  (9.7)
4 Razorback  (9.6)
5 JonEgg  (9.6)

Home - Disclaimer
Copyright © No Name 2001-2022
Page generated in: 0.059 sec.