HISE Logo Forum
    • Categories
    • Register
    • Login

    LorisManager synthesise returns stereo buffer for mono file

    Scheduled Pinned Locked Moved Scripting
    4 Posts 2 Posters 99 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
      last edited by d.healey

      Just want to check if I'm doing something wrong here.

      I call lorisManager.analyse(f, rootFreq); with f being a mono file.

      Then I call

      local buffer = lorisManager.synthesise(f);		
      local isMultiChannel = isDefined(buffer[0].length);
      

      And isMultiChannel is returning 1, but it should be 0. What am I missing? Or does Loris always return stereo?

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

      A 1 Reply Last reply Reply Quote 0
      • A
        aaronventure @d.healey
        last edited by

        @d-healey isn't buffer[0] the first channel? So in that case, whatever the buffer array is (not zero), isMultichannel always returns 1?

        Should you be checking for buffer[1] instead?

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

          @aaronventure I'm copying it from the loris toolbox example.

          Except that check is on the original file (not the synthesised buffer). I'm going through the toolbox example now to see if I can figure out where I'm going wrong.

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

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

            Well I didn't answer the title question but using the original audio file rather than the synthesised buffer to get the number of channels solves the problem I was having.

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

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

            23

            Online

            1.8k

            Users

            12.0k

            Topics

            104.8k

            Posts