QB64 Phoenix Edition v3.8.0 Released!
#56
I'm sorry for the off-topic (and wrong focused programming language). One concept that is not employed, but that I'm thinking about now is keeping track of song "snippets" into arrays such as:

Code: (Select All)
songsnippet(1, 1) = "L8O4AO5C#"
songsnippet(1, 2) = "L4O3A"

songsnippet(2, 1) = "L16O4AFL8O5C#"
songsnippet(2, 2) = "L8O3FC#"

songsnippet(3, 1) = "L16O4FL8AL16O5C#"
songsnippet(3, 2) = "L4O3F"

and send them together for two-channel sound. (I purposely used PLAY strings expected by the Color Computer 3 in this example.) Also because I'm not very good with traditional musical concepts, especially scales I made a simple process in which a "lowest" note is selected, then four or five other notes are created from an array like this:

Code: (Select All)
scale(1) = 4
scale(2) = 5
scale(3) = 3
scale(4) = 4
scale(5) = 3
basenote = 36: 'two octaves below "middle C"
notes(1) = basenote
for i = 1 to 5
    basenote = basenote + scale(i)
    notes(i + 1) = basenote
next

Then the musak is generated only selecting notes from "notes()" array as indicated in the above example. (In QB64 use "N" command for PLAY.) For each song, of course, the "scale()" array and "basenote" would be initialized differently. However, the Lua script only does one channel at a time. The "1bitr" has a multi-channel mode but I'm unwilling to study it. LOL click drums, I want something better than that after hearing enough chiptunes. Smile
Reply


Messages In This Thread
RE: QB64 Phoenix Edition v3.8.0 Released! - by mnrvovrfc - 06-18-2023, 12:58 PM



Users browsing this thread: 30 Guest(s)