Forum
    • Categories
    • Register
    • Login
    1. Home
    2. daniel_101
    D
    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 8
    • Groups 0

    daniel_101

    @daniel_101

    0
    Reputation
    1
    Profile views
    8
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    daniel_101 Unfollow Follow

    Latest posts made by daniel_101

    • RE: What’s the correct way to send an audio file from a HISE plugin to a backend server?

      @David-Healey said in What’s the correct way to send an audio file from a HISE plugin to a backend server?:

      Built from the develop branch?

      To be honest, I do not know much about how the HISE github repo is structured, but I do not think its from the develop branch, because I downloaded from the Download Installer page on the HISE website. url: https://github.com/christophhart/HISE/releases

      posted in Scripting
      D
      daniel_101
    • RE: What’s the correct way to send an audio file from a HISE plugin to a backend server?

      @David-Healey said in What’s the correct way to send an audio file from a HISE plugin to a backend server?:

      The function is File.loadAsBase64String(); It's still in the API.

      Yes the File.loadAsBase64String() function used to exist on HISE but I did not seem to return a valid base64 string. And as of the HISE version I installed today, the File.loadAsBase64String(); no longer exists. Here's a screenshot picture from the HISE API interface:
      alt text

      posted in Scripting
      D
      daniel_101
    • RE: What’s the correct way to send an audio file from a HISE plugin to a backend server?

      @dannytaurus Thanks Danny, Yes sending it as a base64 string seemed to the best approach and I've tried using the "File.loadAsBase64()" function to do that but the function on HISE did not return a valid base64 string, As I explained in a previous post and as of the latest update, isn't part of the "File" API anymore.
      I would be very grateful if there is any other way to convert a file to base64 in HISE.

      posted in Scripting
      D
      daniel_101
    • RE: What’s the correct way to send an audio file from a HISE plugin to a backend server?

      @David-Healey Thanks david, Using cURL sounds nice. Can I use cURL within HISE while in production?
      I am currently using the Server.callWithPOST function but I can only send the file in a string format (in base64) or as a multipart/form-data format.

      posted in Scripting
      D
      daniel_101
    • RE: What’s the correct way to send an audio file from a HISE plugin to a backend server?

      @David-Healey Okay, How do you mean? I don't see how I can do that because unless the backend server is also running on a users device, it can't access the file using its system path and my backend server is hosted on vercel

      posted in Scripting
      D
      daniel_101
    • What’s the correct way to send an audio file from a HISE plugin to a backend server?

      I’m working on a simple workflow: a HISE plugin that sends a text prompt and optionally, an audio file to a backend. The backend uses both as input for a MusicGen model, then returns the generated audio for the plugin to download and insert into the DAW.

      Everything is working, except that I haven’t been able to send an audio file from the HISE plugin to the backend. I previously attempted this using File.loadAsBase64String() function but like I discussed in a recent forum topic, it didn’t seem to return a valid base64 string and in the latest update, this function also appears to be missing from the File API.

      I’ve made good progress on the rest of the plugin, but I’m still stuck on this final step. I would really appreciate any guidance or clarification on whether sending a file this way is currently supported in HISE.

      posted in Scripting
      D
      daniel_101
    • File.loadAsBase64String() seem not to return valid a base64 string?

      Hi, I am newbie to HISE, and I want to implement a feature where a file (selected by a user) would be converted to a base64 string and sent as part of a JSON to a backend server using the Server.callWithPOST function.
      In my python backend, I try to validate that the base64 string is valid base64 but it never passes. Given that the length of the string never changes between HISE and the backend, I think suggests that the string doesn't get corrupted when converted to JSON.
      Also taking a look at the string returned from the loadAsBase64String, (In my case):

      var base64AudioData = f.loadAsBase64String();
      Console.print(base64AudioData); // 1048558.RkjQFY9+O.vUAYUQl0Fcf.A...P..H..DwJ...QrB..A..A.jEF...<CONTINUES>
      Console.print(base64AudioData.length); // 1398086
      

      I noticed that it doesn't quit have the characteristics of a base64 string (I think).

      1. The length of the string is not a multiple of four, even though it's always a multiple of two.
      2. It is always prefixed with a number. in this case 1048558 (The size of the file.)
      3. Makes use of multiple periods (.) which I do not expect in a base64 string.
        Is there a step I am missing before loading the file as a base64 string or is there a way to convert it into one in the backend, probably using zstd or does loadAsBase64String function not return a base64 string representation of the file?
      posted in Scripting
      D
      daniel_101