How to create a Snapshot library

Home Forums General Programming How to create a Snapshot library

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #116439
    wildthing
    Participant
      • Topics: 8
      • Replies: 12
      • Total: 20

      Hi guys, I’m trying to improve my panels and I would like to add a tab with a library made of saved snapshots. My idea is to create a kind of midi bank without using sysex but nothing than midi controls.

      The first thing i need to understand is how to get all the modulators values from the panel and pack them into a single file.

      I stress out that i don’t want to translate midi CC into sysex but just create a patch file unsing snapshot values.
      I’ve tried to figure out how to do this thing but it’s too difficult to me so i realy need some help. Do you have any idea about how can i do that? Any hint would be much appreciated!

      • This topic was modified 4 years, 5 months ago by wildthing.
      #116443
      dnaldoog
      Participant
        • Topics: 4
        • Replies: 480
        • Total: 484
        • ★★

        Hi wildthing,

        Have a look at this panel:

        https://github.com/RomanKubiak/Panels/blob/1aaeb12ad9cd96a16cddb37fd2a2c8ca98f87a01/DEMO/DEMO%20-%20Files.panel

        It will show you how to save and reload a set of records as a binary file.

        You would collect your uiSlider values into a lua table and then convert that table into a MemoryBlock using method createFromTable({}) and write to a binary file.

        One way of doing that might be to record value changes using a callback function set in [Called when any modulator changes it’s [sic] value] into a lua table, which is then converted into a file (see function saveContentAsData() in the DEMO file). You can filter which kind of modulator is to be recorded using modulator:getUiType() in that callback function.

        Let me know if this doesn’t make sense.

        Regards,

        #116444
        wildthing
        Participant
          • Topics: 8
          • Replies: 12
          • Total: 20

          Thanks a lot Dnaldoog, I’ll take a look!

        Viewing 3 posts - 1 through 3 (of 3 total)
        • The forum ‘Programming’ is closed to new topics and replies.
        There is currently 0 users and 53 guests online
        No users are currently active
        Forum Statistics
        Threads: 2,495, Posts: 17,374, Members: 77,605
        Most users ever online was 12 on January 22, 2019 3:47 pm
        Ctrlr