<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Lethargy Dev - Medium]]></title>
        <description><![CDATA[In this publication, you will find articles on c64 (mostly demo) development. Articles cover coding, pixeling, music-making, cross-platform development, algorithms, etc… - Medium]]></description>
        <link>https://medium.com/c64-dev?source=rss----a55caad0fb91---4</link>
        <image>
            <url>https://cdn-images-1.medium.com/proxy/1*TGH72Nnw24QL3iV9IOm4VA.png</url>
            <title>Lethargy Dev - Medium</title>
            <link>https://medium.com/c64-dev?source=rss----a55caad0fb91---4</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 14:41:08 GMT</lastBuildDate>
        <atom:link href="https://medium.com/feed/c64-dev" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Unfortunate Coincidence]]></title>
            <link>https://medium.com/c64-dev/unfortunate-coincidence-c5c8c46704bf?source=rss----a55caad0fb91---4</link>
            <guid isPermaLink="false">https://medium.com/p/c5c8c46704bf</guid>
            <category><![CDATA[8-bit]]></category>
            <category><![CDATA[demoscene]]></category>
            <category><![CDATA[csdb]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[c64]]></category>
            <dc:creator><![CDATA[Szórádi Balázs]]></dc:creator>
            <pubDate>Fri, 05 Feb 2021 09:45:48 GMT</pubDate>
            <atom:updated>2021-02-08T10:37:46.042Z</atom:updated>
            <content:encoded><![CDATA[<p><a href="https://csdb.dk/release/?id=198919">Unfortunate Coincidence</a> is a <a href="https://en.wikipedia.org/wiki/Commodore_64">c64</a> one file <a href="https://en.wikipedia.org/wiki/Demoscene">demo</a> released on the 14th of Jan. 2021 in a special <a href="https://csdb.dk/event/?id=3003">competition</a> allowing sprites only. In this article, I would like to give you an overview of what&#39;s going on under the hood.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FsEiDKC6f4KY%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DsEiDKC6f4KY&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FsEiDKC6f4KY%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/efe66b94fac1e1b1588844ed41c2ce66/href">https://medium.com/media/efe66b94fac1e1b1588844ed41c2ce66/href</a></iframe><h3>The effect</h3><p>The idea of the main effect is to overlay horizontal raster bars with a layer of sprites representing vertical color bars with alternating on/off pixels to show a “transparent” lattice. The result is a crazy looking plasma-like effect with lots of colors.</p><h3>History</h3><p>I already did a version of this effect in gfx mode for the demo <a href="https://csdb.dk/release/?id=151253">“25 Years Atlantis”</a>. In that demo the overly was a gfx grid instead of sprites therefore I could have 2 colors per vertical char column ($d800 was not used) with two-pixel wide pixels. I used a trick to avoid “bad lines” (Char DMA fetches) so the vertical colors in the gfx had to be updated only for the first char line (40 bytes) instead of the whole screen (1000 bytes). This allowed the effect to run full frame at 50fps. (I&#39;m pretty proud of this effect as I got applause for it during its presentation at <a href="https://csdb.dk/event/?id=2299">X’2016</a>)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/780/1*cLEr1Pdm7CArKaljfR9BPQ.png" /><figcaption>Screenshot from the demo “25 years Atlantis”</figcaption></figure><h3>Sprite only version</h3><p>So when I first heard about Raistlin’s <a href="https://csdb.dk/event/?id=3003">“Sprite Only Compo”</a> at CSDB this effect immediately popped into my mind that this has to be done with sprites and open borders.</p><p>I knew there will be limitations compared to the original effect, but hoped it would look good as well.</p><ul><li>In order to cover the full width of the screen, I need to use all 8 sprites expanded on the x-axis, which doubles the x-axis pixel resolution to 2 pixels.</li><li>I can have only 3 colors for the overlay, as sprites can have only 3 colors two of which are fixed and one freely adjustable. For simplicity, I decided to use 3 fixed colors for all of the sprites. Turning on multicolor doubles the x-axis pixel resolution again so the x resolution will be 4 pixels.</li></ul><p>As I was planning to update the raster bar colors on every 4th raster line having 4 pixel wide vertical bars turns out to be an acceptable restriction.</p><h3>First prototype</h3><p>For starts, I wanted to see how the timing goes with open borders, four pixels high bars, and overlayed x-axis expanded multiplexed sprites. The sprites in the example are in dark grey with all sprite edge pixels set. At this point, I got really excited that I can do this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/715/1*z5RX4z12fdVOpImH1E1-MA.png" /><figcaption>The first prototype of the effect.</figcaption></figure><h3>The problem</h3><p>The problem came up after I added the color animation and sprite update calculations. As you can see below, some lines are displayed twice, and that is because c64 sprites have an odd number of rows. Placing the same sprite underneath one another will cause this as the first and last lines of the sprite are the same.</p><p>Unfortunately, there is no way of stopping the drawing of a sprite once it has been started so VIC will display all lines, and multiplexing a new set of sprites is also not possible before all previous sprite rows have been displayed.</p><p>What can be done is to change the sprite pointer per line so VIC reads different data for even and odd lines. To do this I had to do twice the calculation that I planned originally. Now because of this bug, I had to update 16 sprites instead of 8. One set containing pixel bytes like %10101010 and another one containing %01010101 all the way down from sprite row 1 to 21.</p><p>As I had no raster time left to update 16 sprites per frame I had to put the sprite calculation in the main execution thread and use double buffering (using VIC bank switch) to hide update glitches.</p><p>Then I had to rewrite the timing code to add a $d018 switch per line to alternate between the two sets of spites. (Finally, I had 3 cycles left per line phew…)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*2NYyC2VbeKWi7URENSYI9w.png" /><figcaption>The problem c64 has an odd number of sprite rows…</figcaption></figure><blockquote><strong>Update:</strong> Oswald/Resource pointed out I could have used sprite stretching to solve the problem caused by having odd number of sprite lines. (As I have never used sprite stretching the idea never occured to me.)</blockquote><blockquote>So after looking into the sprite stretching trick I updated my prototype in 15 minutes to use sprite stretching and yes it allows me to remove the multiplexer + only the first line has to be updated in the sprite which is stretched (repeated) for the full height of the effect. This saves 3840 CPU cycles, so now in my new version I have time to update the sprite animation per frame as well.</blockquote><blockquote>A little consolation is that in case I used stretching I could not have placed the “Coincidence” logo right below the effect, because VIC renders the remaining 20 lines of the sprite once the stretching is stopped.</blockquote><h3>The bounce</h3><p>Adding the bounce seemed easy at first as I imagined all I needed to do was updating the raster interrupt position and I&#39;m good. Obviously, I forgot about the sprite y coordinates. So I had to tweak the timing precise code once again to read the y coordinates for the multiplexer from zero-page addresses that I update before the end of the previous frame.</p><pre>//------------------------------------------------------------------<br>irq: {<br>    irqStart<br>        ldy $10                // set y position of first sprite row<br>        ldx sine,y<br>        stx $d012<br>        inx                    // add an offset of two as we need <br>        inx                    // two rasters to get a stable raster<br>        stx $d001<br>        stx $d003<br>        stx $d005<br>        stx $d007<br>        stx $d009<br>        stx $d00b<br>        stx $d00d<br>        stx $d00f</pre><pre>        lda #$00               // acknowledge main thread to <br>        sta mloop.ack          // continue updating sprites</pre><pre>        lda mloop.flp          // set the correct video bank<br>        bne !+                 // (double buffering for sprites)<br>        lda #%00000010         // VIC Bank to $4000-$7fff<br>        sta $dd00<br>        jmp cont<br>!:      lda #%00000001         // VIC Bank to $8000-$bfff<br>        sta $dd00<br>cont:   mw #mainEffect : $fffe // set next irq address<br>    irqEnd</pre><pre>.align $100<br>    mainEffect: {<br>        irqStart_stableRaster<br>            pause_looped #36<br>            ldy #$00           // y holds the raster line counter<br>            jmp cont           // align to $100 memory address<br>            .align $100<br>        cont:<br>            .var rastercnt = 0;<br>            .var spritecnt = 0;<br>            .var step = -1;<br>            // we have 11 sets of 16 pixel high segments              <br>            .for(var j=0;j&lt;11;j++) {<br>                .var num = 4<br>                .if (j == 10) {<br>                    .eval num = 2<br>                }<br>                // each segment but the last has 4 subsegments<br>                // each sub segment is 4 rasters high<br>                .for(var i=0;i&lt;num;i++) {<br>                    // the first line is the most exciting<br>                    // update $d021, $d018, sprite pointers...<br>                    ldx d018tab,y<br>                    lda #0<br>                    dec $d016<br>                    sta $d021<br>                    stx $d018<br>                    // zeropage addresses from $f0 hold the<br>                    // new y coordinates for the multiplexer<br>                    ldx $f0 + spritecnt<br>                    bit $00<br>                    inc $d016<br>                    .if (step &lt; 3) {<br>                        .eval step += 1;<br>                    }<br>                    .if (j&lt;9) {<br>                        stx $d001 + step*4<br>                        stx $d003 + step*4<br>                    }<br>                    else {<br>                        lda $1000  // dummy do nothing<br>                        lda $1000<br>                    }<br>                    iny<br>                    // for the remaing 3 lines I use a cycle<br>                    ldx #3<br>            lp:     nop<br>                    nop<br>                    nop<br>                    nop<br>                    dec $d016<br>                    inc $d016<br>                    bit $00<br>                    lda d018tab,y<br>                    sta $d018<br>                    nop<br>                    nop<br>                    nop<br>                    nop<br>                    iny<br>                    dex<br>                    bne lp<br>                    .if (i&lt;3) {<br>                        bit $00<br>                    }<br>                    else {<br>                        jmp next<br>                        .align $100<br>                    }<br>                    .eval rastercnt += 4;<br>                    .if (floor(rastercnt/21) == 1) {<br>                        .eval rastercnt -= 21;<br>                        .eval spritecnt += 1;<br>                        .eval step = -1;<br>                    }<br>                }<br>                next:<br>            }<br>            nop<br>            nop<br>            lda #$00<br>            dec $d016       // open sideborder for the last line<br>            inc $d016<br>            sta $d021<br>        irqEnd #irqBorder : #[*+25]<br>        irqStart<br>            lda #$00        // screen off 24 rows<br>            sta $d011<br>        irqEnd #irqBorderOff : #[*+25]<br>        irqStart<br>            lda #%00001000  // screen off 25 rows<br>            sta $d011       // (top border gets opened)<br>            inc $10         // calculate sprite y positions for<br>            ldy $10         // the multiplexer of the next frame<br>            ldx sine,y<br>            inx<br>            inx<br>            txa<br>            clc<br>            adc #21<br>            sta $f0<br>            adc #21<br>            sta $f1<br>            adc #21<br>            sta $f2<br>            adc #21<br>            sta $f3<br>            adc #21<br>            sta $f4<br>            adc #21<br>            sta $f5<br>            adc #21<br>            sta $f6<br>            jsr anim_horiz<br>            jsr music.play<br>            dec $d021<br>        irqEnd #irqMusic : #irq<br>    }<br>}</pre><h3>The logos</h3><p>Once the bounce was in place I had the idea to place logos above and below as space opens. Here I had to be careful that the logo does not hit the main effect as otherwise, the timing of the effect would break. To do this I chose a pretty simple solution using a table that tells me for each frame whether or not the logo is safe to display or not. By trial and error, I tweaked the content of this table as long as it was not working as I wanted.</p><h3>The side border scroller</h3><p>Is a relatively simple hires x-axis expanded set of sprites, using the ROL instruction to scroll the content from sprite to sprite. To gain speed I interleaved the horizontal (used for the rasters) plasma calculation code in the border open code. I was lucky this time as the update of one row of plasma is 17 cycles two of which is exactly the amount of free cycles I had in between the opening.</p><pre>// open 11 rasterlines (interleave plazma code inbetween)<br>.for(var i=0; i&lt;11; i++) {<br>    dec $d016<br>    inc $d016<br>    plazma_17c(0+i*2)<br>    plazma_17c(1+i*2)<br>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/715/1*4ujPAULVh_l3L8AdXStcUA.png" /><figcaption>The final production with logo(s) and the scroller.</figcaption></figure><p>As I was afraid that adding this scroller would slow the main effect down way too much I decided to use a charset that is only 5 pixels high, and skipping every second line would still give a reasonable char height. In the end, in my opinion, it looks great with the final prod.</p><h3>The music</h3><p>I didn’t want to put restrictions on the music so I kept the place and raster time for the music in mind during the whole project. Uses sidwizard demo player 20/25 raster lines.</p><blockquote>I love it Vincenzo did an excellent job!</blockquote><h3>Full credits</h3><p>Code: Strepto<br>Music: Vincenzo<br>Graphics: Grass</p><blockquote>Thanks for reading! I had a lot of fun working on this demo, I hope you like it!</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c5c8c46704bf" width="1" height="1" alt=""><hr><p><a href="https://medium.com/c64-dev/unfortunate-coincidence-c5c8c46704bf">Unfortunate Coincidence</a> was originally published in <a href="https://medium.com/c64-dev">Lethargy Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Behind the scenes: 5 Shades Of Grey]]></title>
            <link>https://medium.com/c64-dev/behind-the-scenes-5-shades-of-grey-78ee676056b5?source=rss----a55caad0fb91---4</link>
            <guid isPermaLink="false">https://medium.com/p/78ee676056b5</guid>
            <category><![CDATA[demoscene]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[8-bit]]></category>
            <category><![CDATA[retrocomputing]]></category>
            <category><![CDATA[c64]]></category>
            <dc:creator><![CDATA[Szórádi Balázs]]></dc:creator>
            <pubDate>Fri, 05 Feb 2021 09:28:20 GMT</pubDate>
            <atom:updated>2021-09-28T13:08:10.265Z</atom:updated>
            <content:encoded><![CDATA[<p>5 Shades of Grey is a demo we (<a href="https://csdb.dk/group/?id=612">Lethargy</a>) released at <a href="http://gubbdata.se/">Gubbdata</a> 2020, a special <a href="https://en.wikipedia.org/wiki/Commodore_64">C64</a> retro <a href="https://en.wikipedia.org/wiki/Demoscene">demo</a> party. As the title suggests, this article will walk you through the demonstration giving you part by part details.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FymM1zBwMjwY%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DymM1zBwMjwY&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FymM1zBwMjwY%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/21786640d0e313d60a02e5a7b4263e90/href">https://medium.com/media/21786640d0e313d60a02e5a7b4263e90/href</a></iframe><h3>Concept</h3><p>Our concept was to remember the 90&#39;s when the majority of eastern block families could not afford a color tv/monitor for the c64. In Hungary a cheap black &amp; white TV, the Russian made Yunost was the usual choice.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/512/1*0Ag1ViWRvlM4WaqcHctYXw.jpeg" /><figcaption>Russian made B&amp;W Yunost TV</figcaption></figure><p>Users with such a set had no colors, therefore our demo uses only five colors (3 grey colors plus black and white) of the fixed 16 colors palette.</p><h3>The title</h3><p>The name of the demo comes from Vincenzo, who originally had the idea to call the demo “50 shades of grey” but accidentally mistyped it in our forum as “5 shades of grey”. And as it turned out there are exactly 5 shades of grey on the c64 so the name was set.</p><h3>Intro</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*jM7zhnLluXGNwly0cH00gQ.jpeg" /><figcaption>Lethargy HQ 1991</figcaption></figure><p>The intro screen shows a scener starting up his C64 on a black &amp; white Junoszt TV back in 1991 to watch a demo. Technically there is nothing special in this part, standard <a href="https://www.c64-wiki.com/wiki/Multicolor_Bitmap_Mode">MC</a> picture with hires sprites for the TV screen. Great colored background “real” world by Grass.</p><blockquote>Code: Visage Gfx: Grass</blockquote><h3>Parallax</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*GyBTQJCEWX7L-GuFBLz3rg.jpeg" /><figcaption>Lethargy in parallax</figcaption></figure><p>The first part shows a multi-layer logo swinger creating a parallax effect. The routine uses 4x4 chunky mode in multicolor char mode, allowing 13 dither colors in 80x50 resolution. You will see that we used this mode a lot in this demo. (Note: this mode was not invented by us.)</p><blockquote>Code: EGO Gfx: Grass</blockquote><h3>Presents</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*zTc-Hdeq1P3tIiVXmFzhTw.jpeg" /><figcaption>Presents with the 5 B&amp;W colors</figcaption></figure><p>This part uses a mode called “hyper screen” in which the screen is turned off, but opening the top/bottom borders would in fact leave the screen on with no character fetches. In a mode like this only sprites and rasters can be displayed with the benefit of easy timing, as no cycle stealing character fetches are happening (No bad lines). Opening the side border in this mode is a piece of cake. (Note: this mode was not invented by us.)</p><blockquote>Code: Strepto Gfx: Grass</blockquote><h3>Wave scroll</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*yIbzIhlFkh-TvHN1FlHUog.png" /></figure><p>This part uses normal MC char mode in multi-color char mode with 4x4 size pixels showing the title of the demo on a wawing ribbon.</p><blockquote>Code: EGO Gfx: Grass</blockquote><h3>Gfx part</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/718/1*TxNOCSfXK76pPWS_l41zhA.png" /></figure><p>This part displays an MC bitmap covered with one layer of X expanded hires sprites. This allows a total of 5 colors with no restrictions (4 of which from the bitmap and 1 from the sprite overlay). Drawing with only color restrictions is a rare enjoyment for the c64 artist. Grass for sure enjoyed every minute of it.</p><p>The fade-in/out uses the “bad line elimination” <a href="https://en.wikipedia.org/wiki/MOS_Technology_VIC-II">VIC</a> trick to allow quick updates of colors for the whole picture with minimal raster time. (Normally you would have to update 1000 bytes in color ram and 1000 bytes in screen ram for a full picture. With the trick in place this is reduced to 80 updates)</p><blockquote>Code: Strepto Gfx: Grass</blockquote><h3>Head</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/715/1*vIgOM5tFq-QGnJ6GWL0B5w.png" /></figure><p>The head part started with creating a 100MB 3D voxel scan of EGO’s head, which then was then scaled down to a 10000 poly 3D mesh:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XGOI5IK4X0_sR19brDI8Qg.png" /><figcaption>EGO’s head in 3D mesh view</figcaption></figure><p>Then with a C++ application, this mesh was sliced by 50 horizontal planes. 50 planes were needed because in 4x4 mode we have 50 rows of graphics.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kPuM-y3dOmv2ZcnljRPYvw.png" /><figcaption>EGO’s head intersected by 50 planes</figcaption></figure><p>On each plane, the intersected object’s perimeter consists of 16 sides/segments therefore the whole head consists of 50 x 16 = 800 segments.</p><p>Each segment’s 3D coordinates were transformed to planar 2D polar coordinates plus texture coordinates. Each plane has one specific horizontal row in the texture, therefore the texture is 50 pixels high.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/256/1*4-Na5pYSoX13_KT7gbl8Ww.png" /><figcaption>The texture used in the demo is 256x50 pixels</figcaption></figure><blockquote>Code: EGO Gfx: Grass</blockquote><h3>Chess wave</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/716/1*K0JFqPXflM8q-uwEi_Gy3A.png" /></figure><p>The idea for this part came from the first prototype of the wave scroll which was a waving chessboard. As in the meantime, Strepto came up with using 4x4 FLI in char mode with max. 13 dither colors, EGO had an idea to further improve the base effect by adding a feeling of perspective with shading. EGO pointed out that he loves how the outward progressing wave hides the one behind.</p><blockquote>Code: EGO</blockquote><h3>Grey</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*fPazV85JQu4UFZjQY9RVrA.png" /></figure><p>The grey part was the first piece of work for this demo, originally planned as an intro, finally became the main inspiration for the demo. The background effect is an animating roto zoomer, with a neat PETSCII logo over it.</p><blockquote>Code: EGO, Strepto Gfx: Grass</blockquote><h3>Twister</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*be4JE_Encd7pAeUwMApsSQ.png" /></figure><p>The twister in this demo can both twist and zoom, each twist stage has 16 zoom levels that are cleverly selected and modulated in realtime. The zoom stages are Z shaded, extended with the small shadow on the left side to increase the feeling of depth. The effect needs to do 1600 reads and 1600 writes per frame, running at approximately 25fps.</p><blockquote>Code: Strepto, Gfx: Grass</blockquote><h3>Greetings</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*Ly3ZvGiKOykejjEY2zaMkw.png" /></figure><p>The greetings part features a scroller, a logo, and a zooming chessboard moving independently and blended transparently. Uses the same 4x4 char mode with 13 dither colors like most of the effects in this demo.</p><blockquote>Code: EGO</blockquote><h3>Environment mapping</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/717/1*CGYOBvyFF4CnfY0IKs_fhw.png" /></figure><p>Environment mapping is an old-school demo effect from the nineties. The trick is in fact pretty simple, just use the vertex normals as texture coordinates. The result is a fake but realistic reflective surface, hence the name environment.</p><blockquote>Code: EGO, Gfx: Grass</blockquote><h3>End part</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/718/1*ap8c7KNIitSEZBYC-aIJdw.png" /></figure><p>The end part is an MC bitmap with a set of multiplexed sprites for the scroller. The scroller consists of 56 sprites with double buffering for smoothness.</p><p>In multicolor mode, the bit combinations “00” and “01” belong to the background and “10” and “11” to the foreground. Thus setting the sprites to the background the bitmap bit combinations “10” and “11” will appear on top of the sprites giving a nice bitmap overlay on the sprites.</p><blockquote>Code: Visage, Gfx: Grass</blockquote><h3>Testing</h3><p>d’Avid excelled at putting together our hardware test environment, finally offering side by side comparison of the demo running on different c64 models and peripherals. Thanks to his efforts we hopefully made sure the demo runs in sync and problem-free on your c64. (PAL only sorry.)</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FFkxH5I4io58%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DFkxH5I4io58&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FFkxH5I4io58%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/7b0eff8a84f1c3011a74e77ea1ec23a2/href">https://medium.com/media/7b0eff8a84f1c3011a74e77ea1ec23a2/href</a></iframe><p>To rule out CIA timing issues, we used boards with both CIA chip versions. We used three 1541-II floppy-drives (+JiffyDOS) to see how loading speeds of different drives affect the demo/music sync.</p><h3>The test environment</h3><p>Blackmagic Design Intensity Shuttle USB 3.0 with a MacBook Pro 2015. The Intensity Shuttle was throwing away the video signal of the C64 because it has a non-standard 50.125 Hz refresh rate. Therefore d’Avid had an idea to connect his Sony RDR-HX870 DVD-recorder in between as a TimeBase Corrector. The video output of the DVD-recorder (a 3 component RCA RGB-signal) is then fed to the Intensity Shuttle USB. Apple ProRes 422 HQ was the capture format in SD PAL which is more or less a RAW format, so an instance of each recording was almost 3GB on disk. The 8 recordings totaled almost 24GB of raw data which you finally see scaled-down in the multiview comparison video. For video editing, Adobe Premiere Pro CC was used.</p><h3>Music</h3><p>Vincenzo excelled at creating the soundtrack for the demo. For some demos, we have the soundtrack ahead, then we try to figure out which part of the music suites which effect… This demo was more or less complete before having the soundtrack, so Vincenzo could put his full potential at composing fitting music for the demo. Visage helped Vincenzo master GIT and the build system so he could do on the fly test builds to see how the music fits the parts.</p><h3>The reception</h3><p>The demo finished 4th at the party, which is, in our opinion, a bit off compared to what we believe realistic. On the other hand, we got excellent reception and loving feedback for it which is why we love doing demos for you.</p><h3>Full credits</h3><p>Code: EGO, Strepto, Visage<br>Music: Vincenzo<br>Graphics: Grass<br>Charset: Grass<br>Linking: Visage<br>Loader: Sparta (Genesis Project)<br>Test: d’Avid<br>Dir Art: Grass</p><blockquote>Making this demo was approximately 6 months of our limited spare time…</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=78ee676056b5" width="1" height="1" alt=""><hr><p><a href="https://medium.com/c64-dev/behind-the-scenes-5-shades-of-grey-78ee676056b5">Behind the scenes: 5 Shades Of Grey</a> was originally published in <a href="https://medium.com/c64-dev">Lethargy Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[C64 development today]]></title>
            <link>https://medium.com/c64-dev/c64-development-today-8600310be520?source=rss----a55caad0fb91---4</link>
            <guid isPermaLink="false">https://medium.com/p/8600310be520</guid>
            <category><![CDATA[demoscene]]></category>
            <category><![CDATA[c64]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[retrocomputing]]></category>
            <dc:creator><![CDATA[Szórádi Balázs]]></dc:creator>
            <pubDate>Fri, 05 Feb 2021 08:51:43 GMT</pubDate>
            <atom:updated>2021-02-05T15:02:49.710Z</atom:updated>
            <content:encoded><![CDATA[<h3>C64 Development Today</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6OK8gxwK3fh_hwpbX3xK3A.jpeg" /></figure><p>Hobby software development for the Commodore 64 is regaining its popularity. More and more folks (including myself) are returning to code, write music, and pixel graphics for this vintage instrument. My intention with this article is to get <strong>YOU (</strong>the c64 enthusiast) active again. It’s time to show that you’re still the coder, musician, graphican who you used to be.</p><blockquote>Have you ever thought of returning? There is no better time than now, as you’re probably sitting at home, due to COVID-19 lockdown.</blockquote><p>Development today is a lot easier than it was in the eighties. Using modern computers with cross-platform tools for development is very convenient. There will of course be hardcore enthusiasts who will not agree, clinging on to working on the real hardware as they have in the past. This article is for people like me having nostalgic fun in a sort of modern way.</p><h3>What you need</h3><p>You will need a Windows, Linux, or Mac PC, a cross compiler, an emulator, and a text editor of some kind. And a lot of free time, which you may now have.</p><h3>For coding</h3><p>I suggest using the <a href="https://www.sublimetext.com/">Sublime text</a> (text editor), <a href="http://theweb.dk/KickAssembler/Main.html#frontpage">Kick Assembler</a> (cross-assembler), <a href="https://vice-emu.sourceforge.io/">VICE</a> (c64 emulator) development <a href="https://goatpower.org/projects-releases/sublime-package-kick-assembler-c64/">combo</a> put together by <a href="https://csdb.dk/scener/?id=984">Swoffa/Noice</a>.</p><p>This combo gives you a syntax highlighted editor with a one-click build/execute/debug in VICE, combined with the incredible Kick Assembler. In case you have ever coded for the c64 you <strong>HAVE TO TRY THIS</strong>, this is what brought me back four years ago. (I wasn’t super active over these 4 years, but am playing around with 6510 coding regularly since)</p><blockquote>VICE Tip: use the setting inject to ram (Settings/Autostart settings/PRG autostart mode) to instantly start your program without having to wait for it to load.</blockquote><p>Other complete development bundles you might try:</p><ul><li><a href="http://cc65.github.io/cc65/index.html">CC65</a></li><li><a href="https://github.com/GeorgRottensteiner/C64Studio">C64Studio</a></li><li><a href="http://www.popelganda.de/relaunch64.html">Relaunch64</a></li></ul><h3>For debugging</h3><p>For debugging you can use the built-in monitor in the VICE emulator, and set breakpoints vi an input file. Users of Kick Assembler can generate the breakpoint file on compile time with the help of a simple <a href="https://goatpower.org/projects-releases/sublime-package-kick-assembler-c64/">macro</a>.</p><p>There are some handy disassemblers as well:</p><ul><li><a href="https://csdb.dk/release/?id=100129">Infiltrator</a> (Win only)</li><li><a href="https://csdb.dk/release/?id=149429">Regenerator </a>(Win only)</li></ul><h3>For packing</h3><p>Packing your data is also a piece of cake with these tools:</p><ul><li><a href="https://bitbucket.org/magli143/exomizer/wiki/Home">Exomizer</a></li><li><a href="https://csdb.dk/release/?id=145031">ByteBoozer</a></li><li><a href="https://github.com/mist64/pucrunch">PuCrunch</a></li></ul><blockquote>Tip: using packers has never been easier than now, thanks to a Kick Assembler <a href="https://github.com/p-a/kickass-cruncher-plugins">plugin</a>.</blockquote><h3>For loading</h3><p>Using an IRQ loader has never been easier than today. There are two loader systems out there that have a build tool that builds a complete d64 image for you from a simple to use config script. All you need to do is configure loading blocks in the script that will get loaded sequentially with one simple jsr call. And yes you guessed it with compression included!</p><ul><li><a href="https://csdb.dk/release/?id=149811">Spindle</a> by <a href="https://csdb.dk/scener/?id=16473">LFT</a></li><li><a href="https://csdb.dk/release/?id=188991">Sparkle</a> by <a href="https://csdb.dk/scener/?id=29482">Sparta</a></li></ul><p>Should you need more control over your loading, you can use <a href="https://csdb.dk/scener/?id=1678">Bitbreaker’s</a> loader <a href="https://csdb.dk/release/?id=146211">Bitfire</a> or <a href="https://csdb.dk/scener/?id=8104">Krill’s</a> similarly called <a href="https://csdb.dk/release/?id=189130">Krill’s loader</a>.</p><blockquote>Plus: to edit your disk images try using <a href="http://style64.org/dirmaster"><strong>DirMaster</strong></a><strong> </strong>(Win only).</blockquote><h3>For understanding</h3><p>As a coder, I’m regularly reading the following coding references:</p><ul><li><a href="http://codebase64.org/">codebase64.org</a> the number one source of articles on c64 coding.</li><li><a href="http://unusedino.de/ec64/technical/aay/c64/">Ninja’s reference</a> instructions, registers, and kernel.</li><li><a href="https://csdb.dk/forums/">CSDB forums</a> should you get stuck you are very likely to find an answer in the archives or someone will help you for sure.</li></ul><h3>For learning</h3><ul><li>Examples, tutorials: <a href="http://tnd64.unikat.sk/assemble_it.html">tnd</a></li><li>Nice tutorial: <a href="http://dustlayer.com/news">dustlayer.com</a></li><li>Nice set of tutorials for beginners: <a href="http://www.6502.org/tutorials/">6502.org</a></li><li>Coding tutorials (incl. demo coding): <a href="http://www.antimon.org/code.asp">antimon.org</a></li></ul><h3>For graphics</h3><p>For graphics, you can for sure use any of the popular graphics programs out there, but some ready-made editors include the limitations of the VIC graphics modes.</p><ul><li><a href="https://mcdraw.xyz/">mcDRAW</a> (online)</li><li><a href="http://petscii.krissz.hu/">petscii editor</a> (online)</li><li><a href="https://spritemate.com/">spritemate</a> (online)</li><li><a href="http://multipaint.kameli.net/">Multipaint </a>(recommended by <a href="https://csdb.dk/scener/?id=2189">Grass</a>)</li><li><a href="https://csdb.dk/release/?id=86776">Project One</a> (by <a href="https://csdb.dk/scener/?id=8139">Oswald</a>/Resource)</li><li><a href="https://csdb.dk/release/?id=75871">Timanthes</a> (might not work anymore)</li><li><a href="https://csdb.dk/release/?id=128693">HermIRES</a> (hires editor)</li><li><a href="https://subchristsoftware.itch.io/charpad-free-edition">Charpad</a> (FreeEdition)</li><li><a href="http://www.subchristsoftware.com/spritepad/index.htm">Spritepad</a> (Sprite editor)</li><li><a href="https://csdb.dk/release/?id=110">Cuneiform</a> (Char editor)</li><li><a href="https://nurpax.github.io/petmate/">Petmate</a> (PETSCII editor)</li><li><a href="https://csdb.dk/release/?id=174343">Pixcen</a> (Bitmap editor)</li><li><a href="https://csdb.dk/release/?id=172436">PicCon</a> (Image converter)</li></ul><blockquote>Update: check this <a href="http://tomseditor.com/gallery/browse?platform=commodore&amp;format=&amp;author=&amp;year=&amp;sort=&amp;group=&amp;nsfw=&amp;lang=en">retro gallery</a> for some wonderful artwork.</blockquote><h3>For music</h3><p>For music composing the best cross-platform tools out there are:</p><ul><li>the iPad only <a href="http://sidtracker64.com/">Sidtracker64</a>. (This is the fastest to get productive with)</li><li>the multi-platform <a href="http://deflemask.com/">deflemask</a></li><li>the multi-platform <a href="https://sourceforge.net/projects/goattracker2">Goattracker</a>, <a href="http://retro64.altervista.org/blog/making-commodore-64-music-the-sid-and-goattracker/">tutorial</a>.</li><li>the Win/Mac <a href="https://csdb.dk/release/?id=157512">Cheesecutter</a>.</li></ul><p><a href="https://csdb.dk/scener/?id=626">JCH</a> has created a remarkable side by side comparison of <a href="http://chordian.net/c64editors.htm">c64 music editors</a>. Don’t forget to check out his awesome site: <a href="http://chordian.net/">chordian.net</a>.</p><blockquote>Tip: Our musican <a href="https://csdb.dk/scener/?id=4559">Vincenzo</a> recommends using Hermit’s <a href="https://csdb.dk/release/?id=131846">Sidwizard</a> on a real c64.</blockquote><h3>For the community</h3><p>Yes, there are several platforms where we share our c64 related productions. Most important of which are:</p><ul><li><a href="https://csdb.dk/">CSDB</a> the Commodore Scene Database contains all scene related material ever released. You will be surprised at the number of releases being published there daily. (Check the top demos section to get your dose now)</li><li><a href="http://www.pouet.net/">pouet.net</a> the number one demoscene related website.</li><li>Facebook group <a href="https://www.facebook.com/groups/380392412844808/">c64.com</a></li><li>Facebook group <a href="https://www.facebook.com/groups/AC64SID/">Amiga C64 Scene Intros Demos</a></li><li>Youtube channel <a href="https://www.youtube.com/channel/UCOAS2LRJ9VzWrblDtVljaUA">RetroDemoScene</a></li><li>Youtube channel <a href="https://www.youtube.com/channel/UCzWY2Zq_p43Ww015O9eD3Iw">Demoscene ’n’ Stuff</a></li></ul><p>Diskmags are still being released:</p><ul><li><a href="https://csdb.dk/search/?seinsel=all&amp;search=Vandalism+news+%23&amp;Go.x=0&amp;Go.y=0">Vandalism News</a></li><li><a href="https://csdb.dk/search/?seinsel=all&amp;search=Scene+World&amp;Go.x=0&amp;Go.y=0">Scene World</a></li><li><a href="https://csdb.dk/search/?seinsel=all&amp;search=rapid+news&amp;Go.x=0&amp;Go.y=0">RapidNews</a> by <a href="https://csdb.dk/group/?id=185">Excess</a></li><li><a href="https://csdb.dk/search/?seinsel=all&amp;search=remeta&amp;Go.x=0&amp;Go.y=0">reMETA</a> by <a href="https://csdb.dk/group/?id=612">Lethargy</a></li></ul><h3>For parties</h3><p>Yes, demo parties do still exist, the most exciting of which is the <a href="https://www.facebook.com/events/645903629191011/">X Party</a> held every second year in Someren, Nederland where the greatest teams like Booze, Censor, Oxyron, etc. are expected to release a demo.</p><p>Notable c64 only parties are:</p><ul><li><a href="https://datastorm.party/">Datastorm</a></li><li><a href="https://zooparty.org/">Zoo party</a></li><li><a href="http://gubbdata.se/">Gubbdata</a></li><li><a href="http://arok.intro.hu/2020/">Arok party</a></li></ul><p>A list of recent/upcomming events can be found <a href="https://csdb.dk/upcomingevents.php">here</a>.</p><h3>Recent notable demo releases (latest first)</h3><ol><li><a href="https://csdb.dk/release/?id=187977">Stacked</a> by <a href="https://csdb.dk/group/?id=5">Padua</a> <a href="https://www.youtube.com/watch?v=st6dN4jVVZI">youtube</a></li><li><a href="https://csdb.dk/release/?id=187524">Remains</a> by <a href="http://www.pouet.net/groups.php?which=561">Booze Design</a> <a href="https://www.youtube.com/watch?v=4ViKByWvL_c">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=83232">Out of Contex</a> by <a href="http://www.pouet.net/groups.php?which=5834">Artline Designs</a> <a href="https://www.youtube.com/watch?v=7l6N28O2mZQ&amp;feature=youtu.be">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=82895">Bump Up</a> by <a href="http://www.pouet.net/groups.php?which=7400">Lethargy</a> <a href="https://www.youtube.com/watch?v=Tbgs591qagk">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=82438">Demolution </a>by <a href="http://www.pouet.net/groups.php?which=7400">Lethargy</a> <a href="https://www.youtube.com/watch?v=W8uDURwTo6k">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=82431">The Last Truckstop</a> 3 by <a href="http://www.pouet.net/groups.php?which=44">Fairlight</a> <a href="https://www.youtube.com/watch?v=m0rR2vvVlxg&amp;feature=youtu.be">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=82429">Two Sided</a> by <a href="http://www.pouet.net/groups.php?which=6231">Atlantis</a> <a href="https://www.youtube.com/watch?v=Douz7Aa4tKk">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=81668">The Elder Scrollers</a> by <a href="http://www.pouet.net/groups.php?which=561">Booze Design</a> <a href="https://www.youtube.com/watch?v=wrzgXnTHveo&amp;feature=youtu.be">youtube</a></li><li><a href="http://www.pouet.net/prod.php?which=81014">Rivalry</a> by <a href="http://www.pouet.net/groups.php?which=44">Fairlight</a> &amp; <a href="http://www.pouet.net/groups.php?which=519">Bonzai</a> &amp; <a href="http://www.pouet.net/groups.php?which=1616">Genesis Project</a> <a href="https://www.youtube.com/watch?v=GlVsj_2mB-8&amp;feature=youtu.be">youtube</a></li><li><a href="https://www.pouet.net/prod.php?which=81677">The Dive</a> by <a href="https://www.pouet.net/groups.php?which=1616">Genesis Project</a></li></ol><blockquote>Tip: All time top c64 demos are listed <a href="https://csdb.dk/toplist.php?type=release&amp;subtype=%281%2C2%29">here</a>.</blockquote><h3>Top recent game releases</h3><ol><li>L’abbaye Des Morts <a href="https://youtu.be/Jq0j_jA6Qq8">youtube</a> (RGN GCA 2019 #1)</li><li>Legend of Atlantis <a href="https://youtu.be/AJJ65NqoiyM">youtube</a> (RGN GCA 2018 #1)</li><li>Portal C64 <a href="https://youtu.be/FdxjHjFXvwM">youtube</a> (RGN GCA 2018 #2)</li><li>Super Mario Bros <a href="https://youtu.be/6jIrR9Iqq4Q">youtube</a> (RGN GCA 2019 #3)</li><li>Doc Cosmos <a href="https://youtu.be/UBazWQgdjr4">youtube</a> (RGN GCN 2019 #4)</li><li>Organism <a href="https://youtu.be/-sFXDDxFIHE">youtube</a> (RGN GCA 2018 #5)</li><li>Pains’n’Aches <a href="https://youtu.be/u21xKhGke9g">youtube</a> (RGN GCA 2018 #6)</li><li>Digiloi <a href="https://youtu.be/7UNMSeS5l4k">youtube</a> (RGN GCN 2019 #8)</li><li>Wolfling <a href="https://youtu.be/uMYWehJ_DHU">youtube</a> (RGN GCN 2019 #6)</li><li>Run Demon Run <a href="https://youtu.be/aXFh6YmhPuo">youtube</a> (RGN GCA 2019 #10)</li></ol><blockquote>(Retro Gamer Nation / Gamer’s Chose Awards = RGN GCA)</blockquote><blockquote>Strepto of <a href="http://www.pouet.net/groups.php?which=80&amp;order=release">Astral</a>/<a href="https://braincontrol.org/">Braincontrol</a>/<a href="https://csdb.dk/group/?id=612">Lethargy</a></blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8600310be520" width="1" height="1" alt=""><hr><p><a href="https://medium.com/c64-dev/c64-development-today-8600310be520">C64 development today</a> was originally published in <a href="https://medium.com/c64-dev">Lethargy Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>