Page 1 of 1

Extra Drumkit for programmable speaker music

Posted: Fri Jun 20, 2025 10:51 am
by mmmPI
What is this about ?
This is about this mod : https://mods.factorio.com/mod/PMI-Drumkit

It adds 2 additionnals "Drumkits" instruments to the programmable speakers ! ( and some kicks )
What does it look like in game ?
It look like additionnal options in the dropdown menu :
drumkit recap.jpg
drumkit recap.jpg (145.02 KiB) Viewed 534 times
What does it sound like ?
1)Funk

Here is a video of a machine that has a few "Funk" pattern encoded with the Drumkit Funk :



Here is a blueprint of the machine that contain a few explanations ( require the mod ! ) :



Here is also a savegame with only this mod active and the blueprint on it, to make it easier to hear for yourself and make sure there's no conflict with other instruments :
Demo Funk box 6.zip
(4.83 MiB) Downloaded 30 times
2)House

Here is another machine that plays a little house loop using the "Drumkit House" and a melody using other modded instruments ( all links below the video :) )



blueprint ( requires few mods ) :

Save map with the blueprint on it to "sync" the mod easily :
House machine 7.zip
(4.74 MiB) Downloaded 21 times
Inspiration for the loop and melody : Oliver $ & Jimi Jules - Pushing On

Extras :
It was made similar to a previous mod which has more detailed explanations : viewtopic.php?t=129359

But contrary to the other musical instruments that have many notes ( 88 or 96 + ) which can last up to 8 second each , here a full drumkit of 16 sounds has a total duration of 8 seconds or so, which means the mod is very very small, less than 2 MB !

It was also much more difficult to make the samples sounds "good" in the game, the compression to "max quality" .ogg was used, but even then, some alterations occurs, and also when the sound are played in the game, they sound a little further distorted, especially the kicks in the additionnal instruments, those are WIP, different EQ and mastering where attempted to try and mitigate such effects.

This mod will possibly be extended with some more sounds or maybe even a full drumkit, as i see fit when trying to make musical machines, if you have any suggestions feel free to let me know !
House machine 7.zip
(4.74 MiB) Downloaded 21 times

Re: Extra Drumkit for programmable speaker music

Posted: Fri Jun 20, 2025 11:12 am
by Donion
mmmPI wrote: Fri Jun 20, 2025 10:51 am It was also much more difficult to make the samples sounds "good" in the game, the compression to "max quality" .ogg was used ...
You could give the Opus codec a go. Although I don't think it will make a difference since the bitrate in your files is so high (for most of them at least).

Re: Extra Drumkit for programmable speaker music

Posted: Fri Jun 20, 2025 12:00 pm
by mmmPI
Donion wrote: Fri Jun 20, 2025 11:12 am You could give the Opus codec a go. Although I don't think it will make a difference since the bitrate in your files is so high (for most of them at least).
Thanks for the tip, i can indeed do this, i see this and it opens many new settings i never heard of in audacity, i didn't know "opus codec" was a thing nor that it was supported. Will proceed to more experiments ! x) I like the current result for the way it sound, but it may sound closer to the originals then !

I'm not blaming the game in any way for the distortion btw ! I think it's that drumkits are particularly sensible to compression or change of audio format, for some instruments they sound exactly like in FL studio, but those no ( even when cranking up the quality to levels beyond what my ear could distinguinsh or the spectrogram).

I thought it could also be maybe an EQ in game similar to what differs when selecting "global" or "local" and unzooming maybe there is a "default" one which is noticeable or some necessary mastering between the different audio source, things that are bound to be there. Made the challenge for myself to try and learn how to deal with it. Will report on that :)

Re: Extra Drumkit for programmable speaker music

Posted: Fri Jun 20, 2025 12:39 pm
by Donion
mmmPI wrote: Fri Jun 20, 2025 12:00 pm i didn't know "opus codec" was a thing nor that it was supported.
The support was added in 2.0.24. Opus codec is supposed to perform better than Vorbis in lower bitrate scenarios, at high bitrates there shouldn't be much perceptible difference.
mmmPI wrote: Fri Jun 20, 2025 12:00 pm I thought it could also be maybe an EQ in game similar to what differs when selecting "global" or "local" and unzooming maybe there is a "default" one which is noticeable or some necessary mastering between the different audio source, things that are bound to be there. Made the challenge for myself to try and learn how to deal with it. Will report on that :)
You could use .wav to check if it's the compression or the mixing in game. The game decodes samples into unsigned 16 bit depth (down from 32 bit float Vorbis uses), that will play (some) role in it too.

Re: Extra Drumkit for programmable speaker music

Posted: Sat Jun 21, 2025 1:25 pm
by mmmPI
Donion wrote: Fri Jun 20, 2025 12:39 pm You could use .wav to check if it's the compression or the mixing in game. The game decodes samples into unsigned 16 bit depth (down from 32 bit float Vorbis uses), that will play (some) role in it too.
I had not taken this into consideration. I think that the compression is responsible for most of what my ears were able to distinguish as when i turn the samples from original .wav into "16 bit PCM" first in Audacity, then it sound the same in game and outside. The new version now contains those .opus file of the "highest bitrate" but made from 16 bit PCM Wav files, it took a bit of time to document about how it works and what are all the settings for. They are from a environment at 48KHz and not 44.1KHz too i think, just in case.

It sound the same as before in game to me :lol: . At least I can't hear if it's now slightly "better" due to the maximum bitrate being seemingly higher for .opus than .ogg ( the files are twice as big from 1.5 MB to 3MB) , recordings show something a bit different on the spectrograms so maybe other players with better ears and more powerful gears can notice something if played very loud or something, but those are not meant to be material for professionnal music creation so i'm not too worry :)

It will be easier to make the sound design in an 16-bit enviromnent in the future to put in the game, rather than doing so in 32-bit, and having this alteration sometimes noticeable at export or in game when starting with high quality sounds, i have already noticed on some vocals x).

Re: Extra Drumkit for programmable speaker music

Posted: Tue Jul 01, 2025 2:50 pm
by Donion
mmmPI wrote: Sat Jun 21, 2025 1:25 pm It will be easier to make the sound design in an 16-bit enviromnent in the future to put in the game, rather than doing so in 32-bit, and having this alteration sometimes noticeable at export or in game when starting with high quality sounds, i have already noticed on some vocals x).
Note that in 2.1 (probably) audio mixing and decoding will be done in 32bit floats, to keep you on your toes :D

Re: Extra Drumkit for programmable speaker music

Posted: Thu Jul 03, 2025 9:00 pm
by mmmPI
Donion wrote: Tue Jul 01, 2025 2:50 pm Note that in 2.1 (probably) audio mixing and decoding will be done in 32bit floats, to keep you on your toes :D
That is good to hear ! For all the instruments of this mod it's already done, it will just "sound better" when it update :) I was considering remaking them 16bits to save 1.5MB but i can safely postpone it forever now :D I had spent time to make a special template for the drumkits as they are not like the other instruments with notes so just in case it wouldn't take much to re-do the files and their label and everything :)

And for the other instrument mod it should increase fidelity and similarly not take much work to redo the samples !

For anything related to vocals though, after further testing, i realized it doesn't work easily because just having some sample means the person using them need to recognize the note/pitch used, which i can't do, i need the spectrogram or the tuner to recognize the notes between C5 and C#5 for example, when it's just a word of 1 syllabus. And it's even worse when there's more, because then they can be "said" or "sung" by the AI onto severals notes which require the person trying to make music to recognize those several notes, AND then to compose on a scale that contain those notes. It does sound better in 32 bits, but in both cases i found it very difficult to use. ( at least for me the way i tried so far ).

Will try to make a little video of the least terrible attempt when i'm sure which one it is x)

Re: Extra Drumkit for programmable speaker music

Posted: Thu Jul 10, 2025 9:51 am
by mmmPI
I have started to work on other mods, so i don't think i'm going to improve the previously mentionned talking-house-machine , i'm still planning on adding additionnal drumkits on this mod , and some unsorted percussion when i need them in the future, the mod is there to make it easier and i'm if there is any suggestion for additionnal sample, i'll gladly accept, but for the vocals i will pass for now.

Here is the least unsatisfying version i could come up with :





Also a map, since the blueprint requires several mods installed to work propely, it's easier to just sync :
FACTORY PEOPLE demo.zip
(5.21 MiB) Downloaded 9 times
This is meant as a demo for the drumkits and an attempt at using voice sample ( i wouldn't recommend x) ) , only that can be heard, but if the other mods that i couldn't manage to use to make the instrumental are not present, it will mess with the blueprint.