Peripheral drift illusion: Difference between revisions
m
syntax highlighting fixup automation
m (Ada: Comment) |
Thundergnat (talk | contribs) m (syntax highlighting fixup automation) |
||
Line 12:
=={{header|Action!}}==
<
BYTE i
Line 78:
DO UNTIL CH#$FF OD
CH=$FF
RETURN</
{{out}}
[https://gitlab.com/amarok8bit/action-rosetta-code/-/raw/master/images/Peripheral_drift_illusion.png Screenshot from Atari 8-bit computer]
Line 85:
{{trans|Wren}}
{{libheader|APDF}}
<
procedure Drift is
Line 184:
Draw_Squares;
PDF.Close;
end Drift;</
=={{header|Julia}}==
Line color tables taken from the Wren example. See the output [https://imgur.com/jKqIgbe on imgur].
<
function CodepenApp()
Line 250:
CodepenApp()
</syntaxhighlight>
=={{header|Nim}}==
Line 259:
See window screenshot [https://github.com/lscrd/Rosetta/blob/main/Images/Peripheral_drift_illusion-Nim.png here.]
<
const
Line 353:
let app = newApplication(Application, "Rosetta.Illusion")
discard app.connect("activate", activate)
discard app.run()</
=={{header|Perl}}==
<
use warnings;
Line 386:
open my $fh, '>', 'peripheral-drift.svg';
print $fh $svg;
close $fh;</
See [https://github.com/SqrtNegInf/Rosettacode-Perl5-Smoke/blob/master/ref/peripheral-drift.svg offsite SVG image]
Line 392:
{{libheader|Phix/online}}
You can run this online [http://phix.x10.mx/p2js/Peripheral_Drift_Illusion.htm here].
<!--<
<span style="color: #000080;font-style:italic;">--
-- demo\rosetta\Peripheral_Drift_Illusion.exw
Line 475:
<span style="color: #008080;">end</span> <span style="color: #008080;">procedure</span>
<span style="color: #000000;">main</span><span style="color: #0000FF;">()</span>
<!--</
=={{header|Raku}}==
<syntaxhighlight lang="raku"
my @blocks = (1..15 X 1..10).map: -> ($X, $Y) {
Line 501:
|@blocks,
]
)</
See [https://github.com/thundergnat/rc/blob/master/img/peripheral-drift-raku.svg offsite SVG image]
Line 508:
This reproduces the codepen image and does indeed appear to move although it's static.
See the output [https://imgur.com/xyVcnif on imgur]
<
import "graphics" for Canvas, Color
Line 577:
}
var Game = PeripheralDrift.new()</
|