376

(2 replies, posted in General Discussion)

I think everyone who tried to record rock guitar these days are familiar with the impulses, used to simulate cabinets, reverbs, and stuff. Now here is a fun idea: if you can record impulse response of a guitar cabinet to catch its signature sound, why not to do it with an old computer? We can easily record sound of Spectrum's internal speaker, and get a very similar frequency response in a DAW, and potentially in a emulator too.

I did this with various lo-fi devices just recently, but I don't have an original ZX to try. So maybe someone could do it? All that is needed is just to record one singular click (like, OUT (254),16 with reasonable quality (better-than-karaoke mic, 44100, 24-bit, minimized ambient noise).

By some reason, PC speaker music most often was limited to the basic square wave. The common best tricks were to interleave a few channels with quite horrible buzz (Lotus III, or occasionally interrupt one channel of sound with another (Monkey Island 2). Rarely a game attempted to put at least some expression into music, like Ski or Die! (slides and vibrato).

There were rare attempts to go beyond this, with true synthesizers/multichannel engines, though, which is totally possible (there is WAV/MOD/MP3 players for PC Speaker, after all), and always interesting to see. Thought to list a ones that I managed to find so far, while I'm researching this field.

Moon Patrol (1983) - a weird one, has three kinds of music, look for end stage and game over
Digger (1983)
Rollo and the Brush Brothers (1984)
Styx (1984) - no music, but unusual sounds
Music Construction Set (1984?)
Karateka (1986)
Saboteur II (1987)
Sid Meier's Pirates (1987)
Blockout (1989)
Budokan (1989)
F-15 Strike Eagle II (1989)
Fantasy World Dizzy (1989)
Hard Drivin' (1989)
Turbo Outrun (1990)
Knightmare (1992)

Should be noted that many of these videos has been made using DosBox, and it does not emulate PC Speaker well enough, introducing noticeable sound distortions in such complex routines. Saboteur II and Hard Drivin' suffered a lot.

378

(166 replies, posted in Sinclair)

I have 64-bit PC with Win7, but always compiled into 32 bit, because of compatibility issues - with Windows 32 bit programs runs fine at 64 bit, but not vice versa; performance gain for this program is neglible anyways.

The tracker called 1tracker because it has potential to support lots of platforms sharing the same front end and user interface, which in turn can be remade separately without need to adapt older engines. So that's not a question of 1tracker supporting other chips - it supports everything that GameMusicEmu supports out of the box. It is up to an engine to support some chip. I.e. you can make an engine for AY-3-8910 music, for SN76489 music, etc. At the moment I don't have plans to make engines for other platforms, as I got them all covered with other software, unlike all our countless beeper engines. Maybe sometime later.

379

(135 replies, posted in Sinclair)

Music in these games is the same indeed, pitched a bit differently, and with different drums.

I didn't look too much into Rally Cross, but by the sound and quick glance at the code it is the same engine as in Zanthrax and other games, i.e. the first version. You can guess some sampling process has been involved into making these drums, but they're not really sound like normal samples (actually pretty cool, unlike anything else).

Bubble Dizzy version of engine has clearly defined traditional samples. The code is very different, not a small tweak, but a complete overhaul. Music data format is the same, though. This and the fact that sound tone is the same, makes me sure it is indeed a second version of the engine.

380

(166 replies, posted in Sinclair)

Both AngelScript and GameMusicEmu giving me tons of warnings under MSVC 2008, 2010, 2015, and gcc. Seems it is just the way they has been made. So I guess that shouldn't be the issue.

381

(166 replies, posted in Sinclair)

In meanwhile, another fresh engine called Squat has been added.

382

(7 replies, posted in Sinclair)

Made a new engine, inspired and highly influenced by Squeeker and various utz's developments.

- 4 channels of tone, each channel has its own duty cycle
- Noise mode for the last tone channel
- Noise percussion, 9 pitches of noise at 4 volumes
- 7 non-interrupting sampled drums

It is implemented in 1tracker (silent update, please redownload), complete with drum samples importing.

383

(166 replies, posted in Sinclair)

Tracker does not use any TTF fonts, only raster ones. Yes, resources is not included into the source archive, sorry. Will change it later.

The second error is weird. Looks like something related to AngelScript internals.

384

(1 replies, posted in Sinclair)

Just in case anyone will need it, came up with a kind of universal noise routine. It is strongly based on utz's noise generator with rlc h. Allows to control pitch, volume, and duration of a noise burst.

    ld hl,0                ;noise accumulator
    ld de,#2174            ;utz's rand seed
    ld bc,#0101            ;noise pitch, #01 highest, #ff (#00 actually) lowest
    exx
    ld bc,1000            ;noise duration

noise_loop

    exx                    ;4
    dec c                ;4
    jr nz,noise_skip    ;7/12
    ld c,b                ;4
    add hl,de            ;11
    rlc h                ;8        utz's noise generator idea
    inc d                ;4        improves randomness
    jp noise_next        ;10
    
noise_skip

    jr $+2                ;12
    jr $+2                ;12
    nop                    ;4
    nop                    ;4
    
noise_next

    ld a,h                ;4
    
noise_volume=$+1
    cp #80                ;7    noise 'volume' here, #80 max, less is lower volume
    
    sbc a,a                ;4
    out (#fe),a            ;11
    exx                    ;4

    dec bc                ;6
    ld a,b                ;4
    or c                ;4
    jp nz, noise_loop    ;10=106t

385

(166 replies, posted in Sinclair)

Reverse enginereed and added the other Lyndon Sharp's engine, from Bubble Dizzy. Also reworked support for the first one, renamed it to lyndon89.1te (if you have modules made with the old version, just edit the module text, replace engine name there).

Thought to make a note on the row transition noise. There is a way to minimize it. The idea is to avoid row transitions as is. Rather than storing song as a set of rows, with constant skipping of empty fields, store delays between any actual changes that is taking place. This should keep the sound loop tight, and longer gaps when actual changes happens will be masked by the fact that these changes actually change/restart a note, or trigger a drum, i.e. introduce a major change in the sound anyway.

I.e., rather than:

C-1 ...
... ...
... ...
... ...
... C-2
... ...
C-1 E-2

have:

C-1 ... > run sound loop for four rows without parsing anything
... C-2 > run sound loop for two rows
C-1 E-2

387

(135 replies, posted in Sinclair)

Wow, totally missed it too. Really cool one. Seems to be next version of the Lyndon Sharp's engine. Thanks a lot for pointing out.

388

(166 replies, posted in Sinclair)

v0.26 is up. Much faster Z80 assembler (in AngelScript), still not as fast as any native would be, but work gets more comfortable. Many minor fixes as well.

389

(135 replies, posted in Sinclair)

There is a few games with seemingly unique engines that weren't used anywhere else. What they has in common is the strong vibrato on the tone channel, which I think is underexplored area in modern engines.

Saboteur and Sigma 7 engines has one tone channel and noise drums, Sigma 7 also has phasing effects going on the tone channel.

Galaxy Force has as two channels of tone noise drums. The second channel sounds somewhat like ZX-10.

Maybe we could somehow exploit the saw/triangle generator for vibrato? Triangle should be good enough for this use. Should be easier than FM, too.

390

(166 replies, posted in Sinclair)

v0.25 is out of WIP. Now powered with SDL2, which supposedly solves some issues. For one, it now switches to the fullscreen and back blazing fast under Windows, unlike the old version. It also brings separate files for fonts (which is now 1-bit) and color schemes, and a pile of the font and color scheme files to look pretty and provide flexibility regarding screen sizes. It seemignly compiles fine under Ubuntu without editing the code, just by 'make' command (given SDL2 installed, not sure about AngelScrpit). I accidentally Pytha engine, too.

391

(166 replies, posted in Sinclair)

The window can be of any resolution.It is kind of a pseudo text mode, customizeable through the config file (width and height in text characters), and the font.bmp. Smaller font graphics, smaller window; different aspect ratio of the characters also takes effect. The defaults is done for 1920x1080.

Actually, I probably should add a few fonts and selection through the config file, for better convinience.

392

(166 replies, posted in Sinclair)

No, the idea of the changes in file structure and makefile was to compile and link AngelScript as part of the program, directly through object files, not as a lib.

Migrating to SDL2 is actually a good idea, I had a few SDL2 projects done, so will put it to plans. It just happened that the program does not really needed things that SDL2 has to offer, so I kept it plain SDL so far.

The display issue is really weird, as I don't have it neither under Windows nor under Linux. The construct is for normal view, it aligns the scrolling for blocks properly. My only guess is that it is some unitialized variable or getting out of bounds, althogh considering proper results in two very different environments, I'd expect the issue to be more exposed. Also, row < 24 means it is somehwere in the scrolling logic, as it is half of the pattern view height, the position to keep cursor line once scrolling starts. I'll think more about it.

393

(166 replies, posted in Sinclair)

So, tried to mess up with Ubuntu under VirtualBox, and got really weird results. Here is WIP source for 0.25: http://shiru.untergrund.net/temp1/1tracker_src.zip

I tried to reogranize files to simplify build process. Just 'make' it, and it should be enough (I only had to also 'sudo apt-get install libsdl-dev').

Weirdities:

- The program does not start if JIT is enabled in the config file (closes window right away)
- The program works without JIT, but produces no sound and occasionally reports missing data
- File dialog allows me to browse everywhere, just like under Windows. No changes has been made to the code

Please take a look, is the behaviour the same on your system?

394

(166 replies, posted in Sinclair)

The first = is a bug, I normally don't use such unsafe constructions (apart from a piece related to dirent code).

Yes, I think it going to work if the line will be disabled in the chopped view. I'm trying to compile it under Linux at the moment, to look into directory navigation issue. Not sure if I'll be able to fix that part, but will put an updated version soon anyway, with the display fix at least.

395

(166 replies, posted in Sinclair)

What does the filebrowser show at the bottom of the screen, where full current path is supposed to be displayed? Is the directories above executable actually seen there? I don't know much of Linux, maybe some permissions/security stuff is involved?

The second bug is very weird, definitely don't have anything like that here. Will think over it. Maybe I need to setup a virtual machine and see it by myself, after all.

396

(166 replies, posted in Sinclair)

1tracker got an update. No new engines this time, sorry. Instead, I tried another improvement to the 'single pattern' concept, that is called 'chopped view'. When it is enabled through the new alternative menu (hold Ctrl to see it), only current block is displayed starting from the top of the screen, like a separate pattern. I hope that obstructing visibility of other blocks should help to focus attention on current block, and make it more comfortable to work in case of short blocks (less scrolling). If you split your song into blocks of 16 or 32 lines, it will work similar to the traditional pattern/order list view in a way.

Linux users, please let me know what changes this version needs in order to compile it. Hopefully less changes will be needed this time. I also just noticed that dirent.h had a wrong include path, docs say it should be there, so file dialogs should work properly.

Thanks a lot for the write-up, now I get how it works. Pretty clever and cool stuff. 1-bit synthesis findings still able to amaze me, after so many engines and years.

398

(22 replies, posted in Sinclair)

Now that's some black magic is going on here.

399

(10 replies, posted in Sinclair)

I didn't have enough time yet to devote it to this idea, but I'm definitely want to work on it sometime.

You would need to spend most of the CPU time on both machines to run the MIDI protocol, as Spectrum does not have hardware serial I/O.