Forum
    • Categories
    • Register
    • Login

    Store values in ScriptPanel data object

    Scheduled Pinned Locked Moved General Questions
    51 Posts 6 Posters 6.8k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • toxonicT
      toxonic
      last edited by

      @d-healey @ustk i'm not at home at the moment, but i'll try your example tomorrow. Indeed i want to store knob values , but in my project i use a sequencer, and when i try to use the preset browser, the sequencer will stop running on each preset change, so i can't use that option.
      What could be another approach?

      David HealeyD 1 Reply Last reply Reply Quote 0
      • David HealeyD
        David Healey @toxonic
        last edited by

        @toxonic You could write the values to a file. Using a panel also relies on the preset system BTW.

        Free HISE Bootcamp Full Course for beginners.
        YouTube Channel - Public HISE tutorials
        My Patreon - HISE tutorials

        toxonicT 1 Reply Last reply Reply Quote 3
        • toxonicT
          toxonic @David Healey
          last edited by

          @d-healey okay, that's a good point!

          1 Reply Last reply Reply Quote 0
          • toxonicT
            toxonic
            last edited by

            Saving values in a file works fine so far, this seems to be the way to go for me.
            Just a quick question: which directory would i have to specify in the code, that the compiled plugin can find the preset files in it's own directory (or maybe a subdirectory)? is there a wildcard for that?

            David HealeyD 1 Reply Last reply Reply Quote 0
            • David HealeyD
              David Healey @toxonic
              last edited by

              @toxonic I'm not entirely sure of the question but I think your answer might be here - https://docs.hise.audio/scripting/scripting-api/filesystem/index.html#special-locations

              Free HISE Bootcamp Full Course for beginners.
              YouTube Channel - Public HISE tutorials
              My Patreon - HISE tutorials

              toxonicT 1 Reply Last reply Reply Quote 1
              • toxonicT
                toxonic @David Healey
                last edited by

                @d-healey ahh, okay! Is there a way to embed the textfiles with the stored parameter values in the compiled binary? I mean, i don't want the end user needing to care about the correct location for the files in order to get the compiled plugin working properly.

                David HealeyD 1 Reply Last reply Reply Quote 0
                • David HealeyD
                  David Healey @toxonic
                  last edited by David Healey

                  @toxonic Just include them as scripts

                  Free HISE Bootcamp Full Course for beginners.
                  YouTube Channel - Public HISE tutorials
                  My Patreon - HISE tutorials

                  toxonicT 1 Reply Last reply Reply Quote 1
                  • toxonicT
                    toxonic @David Healey
                    last edited by

                    @d-healey Okay, i didn't know, that this works. Actually, the files are saved in the UserPresets Directory.

                    1. Do the files need a special filexetension, like .js?
                    2. Can i pass the path in the include statement? Soemthing like
                    include ("./UserPresets/filename");
                    

                    or do the files then need to be stored in the Scriptssubfolder in order that HISE can find them?

                    1. Can the content of the files be modified, when the the plugin is compiled, so that the user can change the "presets" ?

                    Sorry for all these questions, but i never used includes for anything other than external scripts...

                    David HealeyD 1 Reply Last reply Reply Quote 0
                    • David HealeyD
                      David Healey @toxonic
                      last edited by

                      @toxonic They will need to be js files and they need to be in the Scripts folder. The content can't be changed because they are part of the plugin. If you want the files to be separate then you need to find a way of including in one of the appData folders.

                      Free HISE Bootcamp Full Course for beginners.
                      YouTube Channel - Public HISE tutorials
                      My Patreon - HISE tutorials

                      toxonicT 1 Reply Last reply Reply Quote 0
                      • toxonicT
                        toxonic @David Healey
                        last edited by

                        @d-healey Okay,thank you for your quick response! 😊
                        How will the AppData folder be created? When i compile a plugin i usually only find the compiled binary. Is there any information on that topic out there?

                        David HealeyD 1 Reply Last reply Reply Quote 0
                        • David HealeyD
                          David Healey @toxonic
                          last edited by

                          @toxonic That folder is created automatically when the plugin/standalone runs the first time. If you want to put files in it then you'll need to build an installer that creates the folder and puts the files there.

                          Free HISE Bootcamp Full Course for beginners.
                          YouTube Channel - Public HISE tutorials
                          My Patreon - HISE tutorials

                          toxonicT 1 Reply Last reply Reply Quote 0
                          • toxonicT
                            toxonic @David Healey
                            last edited by

                            @d-healey uhh, that sounds complicated... 🤔

                            David HealeyD 1 Reply Last reply Reply Quote 0
                            • David HealeyD
                              David Healey @toxonic
                              last edited by

                              @toxonic Yup :)

                              Free HISE Bootcamp Full Course for beginners.
                              YouTube Channel - Public HISE tutorials
                              My Patreon - HISE tutorials

                              1 Reply Last reply Reply Quote 0
                              • David HealeyD
                                David Healey
                                last edited by

                                If these are standard HISE preset files though (.preset) then they will automatically be in the appData/User Presets folder.

                                Free HISE Bootcamp Full Course for beginners.
                                YouTube Channel - Public HISE tutorials
                                My Patreon - HISE tutorials

                                toxonicT 1 Reply Last reply Reply Quote 0
                                • toxonicT
                                  toxonic @David Healey
                                  last edited by

                                  @d-healey so, could i just change the file extension to .preset ? 😏

                                  David HealeyD 1 Reply Last reply Reply Quote 0
                                  • David HealeyD
                                    David Healey @toxonic
                                    last edited by

                                    @toxonic I doubt it

                                    Free HISE Bootcamp Full Course for beginners.
                                    YouTube Channel - Public HISE tutorials
                                    My Patreon - HISE tutorials

                                    toxonicT 1 Reply Last reply Reply Quote 0
                                    • toxonicT
                                      toxonic @David Healey
                                      last edited by

                                      @d-healey Mhh, i compiled the plugin for testing purposes, but i cannot find the appData directory. Where is the place, i should search for?
                                      I build a vst3 fxplugin and put the dll to my standard vst3 folder. It works fine so far in the DAW (except the preset issue), but i there's no appData directory created after the first launch.

                                      LindonL 1 Reply Last reply Reply Quote 0
                                      • LindonL
                                        Lindon @toxonic
                                        last edited by

                                        @toxonic
                                        appdata (in windows) is at

                                        C:/Users//AppData

                                        HISE Development for hire.
                                        www.channelrobot.com

                                        toxonicT 1 Reply Last reply Reply Quote 1
                                        • toxonicT
                                          toxonic @Lindon
                                          last edited by

                                          @Lindon Well, I'm on Linux, but I'd assume, that it should be in my home directory (analogue to windows) - but there's no AppData directory.... do I need to check any options in the HISE settings?

                                          LindonL David HealeyD 2 Replies Last reply Reply Quote 0
                                          • LindonL
                                            Lindon @toxonic
                                            last edited by

                                            @toxonic David is your UNIX guy...

                                            HISE Development for hire.
                                            www.channelrobot.com

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            28

                                            Online

                                            2.1k

                                            Users

                                            13.0k

                                            Topics

                                            112.5k

                                            Posts