My works for Outline 2020

On May 22-24, an online voting of demopati 2020 takes place. The event was planned for May of this year, but was postponed to October for all known reasons.
I will talk about my work


I don’t remember when I drew attention to the 128 byte tiny intro contest, but every year I try to participate. Preparation for the competition is carried out in advance, for the year 2020 the plans were work for the ZX Spectrum and Atari XE, but later the plans changed. I'll start with Apple II:

HiRes Walk




I like this computer, it is attractive because it will take a lot of effort to solve simple problems. Tasks were: sound reproduction, disk operations, graphics, SWEET-16 interpreter.
The graphics for Apple II are two modes - LoRes with a resolution of 40x48, 16 colors and Hires with a resolution of 280x192 6 colors.

Studying the structure of the screen will seem strange, probably this format is due to the fact that Wozniak, when designing a computer, saved on all available chips. Dealing with text mode and LoRes was easy for me, but HiRes mode was a dead end. Any operations with the screen will require sections of code that will not allow the intro to fit into the size of 128 bytes. So I decided to cheat using the available proceduresand try your hand. The idea was simple: draw a line that will leave a mark.

Anyone who wrote something similar to a pong game knows the algorithm. For the intro, you need the data X1, dx1, dxe / Y1, dy1, dye. X1, Y1 - the current coordinate, dx1, dy1 determine the direction of movement, dxe, dye - set the coordinate boundary. With this data set, you can use one procedure for coordinates (X1, Y1), (X2, Y2), or for the first white line.

It remains to make a trace. The idea came about by itself: I wrote a program, ran it 16 times with the debugger and took the ready data - a pair (X3, Y3) and (X4, Y4) will serve to draw a black line. It turns out that the points (X1, Y1), (X2, Y2) move along a given trajectory, and (X3, Y3), (X4, Y4) follow them, but with a certain delay. The final work - transferred the necessary data to address 0, so the size of the code is saved due to the addressing of the zero page.

The perfectionists will grumble that the line does not touch the right corner, but I will get the prepared excuse. The screen resolution is 280 points, so the code has changed to manipulate 16-bit data and the intro has grown from 128 bytes to 256 bytes.

Halfton




This is a remake of the previous work , I decided to change the input of attributes by texture. 47 bytes increased to 128, the remainder was occupied by texture generation and display. There is one drawback - the intro is slow, but you can’t jump beyond 128 bytes.

Sparx




The idea of ​​an intro came by itself, I decided to write code and see what happens. The intro is made simple - a standard text mode with additional settings is used. Atari has a graphics mode GTIA, it is called GRAPHICS 9. By the way, in BASIC you can use the same mode. It is turned on by setting bit 6 in the GRIOR memory location (address 623). In this mode, the high and low bytes of the byte are interpreted as the value of the color brightness (0-15)
An example is the program (Turbo BASIC)
image

The result of work
image

And in text mode, after writing POKE 623.64, the screen looks like this
image

For text mode, characters that look like rectangles of brightness 0-15.

For Atari there is ATASCII character encoding, the order on the table
image

But, in addition to the encoding, there is also an Internal characters code:
image

Type in TurboBasic
POKE DPEEK(88),1
in the upper left corner appears "!"

This numbering is used to describe the font - 8 bytes for space, the next 8 bytes for "!". In BASIC, the font address is stored in cell 756 (CHBAS), you need to multiply the value by 256. In addition, address 756 is the shadow value for $ D409.

Fonts were formed for the selected mode: 8 values ​​$ 00, 7 values ​​$ 11..8 values ​​$ FF. We got characters with codes 0-15 and with a brightness of 0-15.

The action algorithm turned out to be simple: line-by-line copying and decreasing the value by 1 if a code is encountered that is not equal to 0.

Smalevi4




Work is a joke. I read the Serepindipitous Circles article in BYTE Magazine, Aug 1977, vol.2 N8, and decided to try the code. And again, a small intro of 48 bytes turned out. I didn’t want to show the finished work, so I changed the code and the drawing options so that a similar figure was drawn with a square in the center. Total 128 bytes.

Ufff. If the presentation of the principles of the intro took as much time as the work on the intro? Coming up with effects is very fun, and optimizing the code to size is also fun. Try your hand, what if it works out?

All Articles