ac.tomo Posted August 2, 2021 Share Posted August 2, 2021 Many years ago I remember seeing something that I've always wanted to do but not sure how. Can anyone remember those polish or german demos that 'when putting a picture on the screen', it was displayed in some fashion such-like 'a fan' or other way of drawing up the picture different to the standard methods, or filling (in a circular fashion) from the centre of the screen to the edges. I recall several different methods other than the basic/easy methods. Anyone know? Quote Link to comment Share on other sites More sharing options...
_The Doctor__ Posted August 2, 2021 Share Posted August 2, 2021 1 hour ago, ac.tomo said: Many years ago I remember seeing something that I've always wanted to do but not sure how. Can anyone remember those polish or german demos that 'when putting a picture on the screen', it was displayed in some fashion such-like 'a fan' or other way of drawing up the picture different to the standard methods, or filling (in a circular fashion) from the centre of the screen to the edges. I recall several different methods other than the basic/easy methods. Anyone know? do you mean screen wipes / swipes and transition effects ? Quote Link to comment Share on other sites More sharing options...
ac.tomo Posted August 3, 2021 Author Share Posted August 3, 2021 not sure what screen-wipes are, but transition effects sounds about right, yh, i remember 1 used to fan across the screen like a chinese fan opening and closing but I'm not sure how they were accomplished, any help? Quote Link to comment Share on other sites More sharing options...
Wrathchild Posted August 3, 2021 Share Posted August 3, 2021 (edited) Approaches are going to vary based upon whether you have a bitmap or char based screen layout. e.g. with char based you can simply erase a cell by poking a zero (assuming that's the 'blank' character) to the screen. With a bitmap however get get better granularity at a slightly greater price, e.g. erasing a pixel requires reading the byte, masking out the bit or bit pair required, writing it back. Also note that a common way of doing things will be to have a visible and non-visible screen buffer. So for a 'fade in' you have already prepared things with the target in the non-visible buffer and the visible buffer cleared. The you copy across in the manner of your choosing, e.g. for a 4 colour picture you could do something along the lines off: unsigned char mask = 0xC0; unsigned char *vis_adr, non_vis_adr; for (pass=0; pass<4; pass++) { for (outer=0; outer<40; outer++) { vis_adr = visible_screen_base + outer; non_vis_adr = non_visible_screen_base + outer; for (inner=0; inner<192; inner++) { *vis_adr |= (*non_vis_adr & m); vis_adr += 40; non_vis_adr += 40; } } mask >>= 2; } To go from one picture to another would be a tweak to the copy: *vis_adr = (*vis_adr & !m) | (*non_vis_adr & m); Or to wipe a picture could be: *vis_adr &= !m; Play around. e.g. start with the mask as 0x03 and then left shift instead of right shift. Or change the mask to 0x80 and the pass limit to 8 for a single pixel, gr.8 version. For what you want to do with a 'fan' effect is effectively use a line drawing algo to say plot from the bottom centre and draw going around from bottom left to top left, then to top right, then to bottom right. But instead of a plot to colour zero (for a wipe) it would instead copy the equivalent pixel from the non visible screen. You can do a similar thing with fonts too. E.g. take a copy of the font and switch to that. Then use some loops to slowly eat away pixels from the character data. E.g. in an 8x8 cell, dissolve from the top left corner. unsigned char mask= 0x7F, *fnt; for (pass=0; pass<8; pass++) { for (outer=0; outer<128; outer++) { fnt = fontbase + (outer * 8); for (inner=0; inner<pass; inner++) { *fnt++ &= mask; } } mask /= 2; } (caveat: these code snippets have only been run in my head ) Edited August 3, 2021 by Wrathchild fixed font example Quote Link to comment Share on other sites More sharing options...
Irgendwer Posted August 4, 2021 Share Posted August 4, 2021 On 8/3/2021 at 12:34 AM, ac.tomo said: Anyone know? I guess you mean "Silly Things": 4 Quote Link to comment Share on other sites More sharing options...
ac.tomo Posted August 5, 2021 Author Share Posted August 5, 2021 Thats a great demo, wish I understood algorythms. But, yes, thats exactly what I mean. Most of the transition effects there are relatively easy, but the one I don't understand how to do is the circular wipe where the line rotates bringing in the 1 picture from the other, exactly how would this be achieved? Quote Link to comment Share on other sites More sharing options...
Wrathchild Posted August 5, 2021 Share Posted August 5, 2021 Need to go under the hood and get your hands dirty, Altirra has great debugger. Quote Link to comment Share on other sites More sharing options...
Irgendwer Posted August 6, 2021 Share Posted August 6, 2021 (edited) 18 hours ago, ac.tomo said: but the one I don't understand how to do is the circular wipe where the line rotates bringing in the 1 picture from the other, exactly how would this be achieved? It's not easy. Some background info here: https://atariage.com/forums/topic/173733-jacs-sillyventure-contribution/?do=findComment&comment=2156593 (and following posts) Edited August 6, 2021 by Irgendwer 1 Quote Link to comment Share on other sites More sharing options...
pfeuh Posted August 7, 2021 Share Posted August 7, 2021 Awesome! O_o Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.