HISE Logo Forum
    • Categories
    • Register
    • Login

    .ch1 samples stop working in compiled VSTi (did i miss something?)

    Scheduled Pinned Locked Moved Solved General Questions
    24 Posts 5 Posters 1.3k 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.
    • d.healeyD
      d.healey @Straticah
      last edited by

      @Straticah said in .ch1 samples stop working in compiled VSTi (did i miss something?):

      Does this "Locate Samples" menu work with expanions?

      I'm not sure, it's been a long time since I used expansions. I think each expansion has its own Samples folder and own Link file.

      Libre Wave - Freedom respecting instruments and effects
      My Patreon - HISE tutorials
      YouTube Channel - Public HISE tutorials

      StraticahS 1 Reply Last reply Reply Quote 0
      • StraticahS Straticah has marked this topic as unsolved
      • StraticahS
        Straticah @d.healey
        last edited by

        @d-healey This would make sense, but i have not found anything that confirms that.

        If anybody can shine some light on how users can install/move expansions, this would help a ton.

        creating user interfaces: www.vst-design.com
        founder @prototype.audio https://www.prototype.audio/

        d.healeyD 1 Reply Last reply Reply Quote 0
        • d.healeyD
          d.healey @Straticah
          last edited by

          @Straticah I just checked with Rhapsody and each expansion does have its own Samples folder. I'm not using the encrypted expansions with Rhapsody but I suspect it will be the same.

          Libre Wave - Freedom respecting instruments and effects
          My Patreon - HISE tutorials
          YouTube Channel - Public HISE tutorials

          StraticahS 1 Reply Last reply Reply Quote 0
          • StraticahS
            Straticah @d.healey
            last edited by

            @d-healey Okay that makes sense - where/how does Rhapsody store and recall the locations of the users Expansion Samples? Is it custom or is HISE doing it via the the startup "overlay"?

            creating user interfaces: www.vst-design.com
            founder @prototype.audio https://www.prototype.audio/

            d.healeyD 1 Reply Last reply Reply Quote 0
            • d.healeyD
              d.healey @Straticah
              last edited by

              @Straticah There's a link file in each expansion's Samples folder that points to the location of the samples. I create the link file as part of my expansion install process, I also have scripted a system to allow the user to update it if they move the samples to another location.

              Libre Wave - Freedom respecting instruments and effects
              My Patreon - HISE tutorials
              YouTube Channel - Public HISE tutorials

              Christoph HartC 1 Reply Last reply Reply Quote 1
              • Christoph HartC
                Christoph Hart @d.healey
                last edited by

                @d-healey I think it also looks automatically in the global sample folder when the monolith can‘t be found in the expansion folder but it‘s also been ages that I‘ve used this myself.

                I definitely tried to offer both sample location possibilities so you can decide whats more convenient for you.

                StraticahS LindonL 2 Replies Last reply Reply Quote 1
                • StraticahS
                  Straticah @Christoph Hart
                  last edited by

                  @Christoph-Hart Okay i will try to utilize the linker files and set path with them.

                  If it does not work maybe i can still read it and override HISE expansion search path via API.

                  If you have examples on how to set a custom expansion path for HISE lmk.

                  Will look into Rhapsody path handling aswell. @d-healey

                  creating user interfaces: www.vst-design.com
                  founder @prototype.audio https://www.prototype.audio/

                  bendursoB 1 Reply Last reply Reply Quote 0
                  • bendursoB
                    bendurso @Straticah
                    last edited by bendurso

                    @Straticah What I do is this: when the user opens the plugin for the first time, I ask them where they want to store all the samples and save that path in a JSON file.

                    Then, during each expansion installation, when I call expHandler.installExpansionFromPackage, I always send the samples to that folder inside a new subfolder. The file link is created automatically by this function.

                    If the user later wants to change the location, I provide a master configuration option for relocating samples. So I call Expansion.setSampleFolder for all the expansions and change the path of the json file. This way, the user can simply move all expansions at once.

                    I analyzed different approaches a while back, and this one seemed the most reasonable.

                    StraticahS 1 Reply Last reply Reply Quote 1
                    • LindonL
                      Lindon @Christoph Hart
                      last edited by

                      @Christoph-Hart said in .ch1 samples stop working in compiled VSTi (did i miss something?):

                      @d-healey I think it also looks automatically in the global sample folder when the monolith can‘t be found in the expansion folder but it‘s also been ages that I‘ve used this myself.

                      I definitely tried to offer both sample location possibilities so you can decide whats more convenient for you.

                      Yes I definitely need tthis facility of using the default samples link as we don't use separate folders for expansions, everything goes in the default AppData defined. Lnk folder

                      HISE Development for hire.
                      www.channelrobot.com

                      1 Reply Last reply Reply Quote 0
                      • StraticahS
                        Straticah @bendurso
                        last edited by Straticah

                        Yes an example would be great i still dont understand 100% how it works.

                        @bendurso I have some troubles

                        What works: creating a .json with external samplepath that gets saved in AppData
                        What does not: using Expansion.setSampleFolder to tell HISE the path
                        Link Files: The link are not reliable on mac on my end - I have HISE_DEACTIVATE_OVERLAY=1 and tested/created the link files manually via the stock settings panel:

                        c9d1287f-b1bf-4220-9d71-6dc9b1405d13-image.png

                        LinkOSX file

                        /Volumes/WD_BLACK/Music/Fraction/Samples (all ch1 files go here)
                        
                        <?xml version="1.0" encoding="UTF-8"?>
                        
                        <GLOBAL_SETTINGS DISK_MODE="0" SCALE_FACTOR="1.0" VOICE_AMOUNT_MULTIPLIER="2"
                                         MIDI_CHANNELS="1" SAMPLES_FOUND="0" OPEN_GL="0"/>
                        
                        

                        Sometimes the link file worked (when using the settings panel) but sometimes it does not work...
                        Tested different folders, paths, locations etc. no pattern yet.

                        Edit:
                        I got sound when i removed all expansion content from AppData/Plugin/Expansion and pasted the LinkOSX file in my Expansion folder instead. :o

                        Worked, link file is needed in empty expansion folder and also in AppData root folder.

                        Thanks for the help guys tho this was quite hard as a first timer. :)

                        creating user interfaces: www.vst-design.com
                        founder @prototype.audio https://www.prototype.audio/

                        bendursoB 1 Reply Last reply Reply Quote 0
                        • StraticahS Straticah has marked this topic as solved
                        • bendursoB
                          bendurso @Straticah
                          last edited by

                          @Straticah Yeah, this is my code to install the expansions (i'm actually saving other things on that json file, so that's why I used "SampleFolder" to retrieve it from the json)

                          var CompletePath;
                          
                          inline function InstallPackage()
                          {
                          	local parentFolder = FileSystem.getFolder("../");
                          	local SampleFile = parentFolder.getChildFile("settings.json");
                              local SampleObject = SampleFile.loadAsObject();
                              
                              local DirectoryFile = FileSystem.fromAbsolutePath(SampleObject.SampleFolder);
                              
                              CompletePath = DirectoryFile.createDirectory(InstrumentName);
                                
                              if (CompletePath.isDirectory())
                              {       
                                     expHandler.installExpansionFromPackage(selectedInstrumentFile, CompletePath);  
                              }
                              else
                              {
                                  Console.print("Could not create the installation directory.");
                              }
                          }
                          

                          When I use expHandler.installExpansionFromPackage, it creates the link file on expansion samples folder with the samples path. It always worked for me, and I never received a support ticket.

                          And then I created my own button to change the samples path on settings. This will change the sample paths for all the expansions.

                          inline function onbtnChangeSamplesDirectoryControl(component, value)
                          {
                              if (value)
                              {
                                  FileSystem.browseForDirectory("", function(selectedFolder)
                                  {
                                      if (selectedFolder)
                                      {
                                          if (selectedFolder.hasWriteAccess())
                                          {
                                              var path = selectedFolder.toString(0);
                                              currentSampleFolderPath = path;
                          
                                              var notFound = [];
                          
                                              for (e in expHandler.getExpansionList())
                                              {
                                                  var name = e.getProperties().Name;
                                                  var fullPath = path + "/" + name;
                                                  var folderObject = FileSystem.fromAbsolutePath(fullPath);
                          
                                                  if (folderObject.isDirectory())
                                                  {
                                                      e.setSampleFolder(folderObject);
                                                  }
                                                  else
                                                  {
                                                      notFound.push(name);
                                                  }
                                              }
                          
                                              if (notFound.length > 0)
                                              {
                                                  Console.print("Not found");
                                              }
                                              else
                                              {
                                                  Console.print("All sample folders updated successfully");
                                              }
                                          }
                                          else
                                          {
                                              Console.print("The selected folder can't be accessed due to insufficient write permissions. Please choose a different folder.");
                                          }
                                      }
                                  });
                              }
                          };
                          
                          Content.getComponent("btnChangeSamplesDirectory").setControlCallback(onbtnChangeSamplesDirectoryControl);
                          
                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post

                          12

                          Online

                          2.0k

                          Users

                          12.6k

                          Topics

                          109.4k

                          Posts