HISE Logo Forum
    • Categories
    • Register
    • Login

    Audio thread function variables

    Scheduled Pinned Locked Moved Scripting
    3 Posts 2 Posters 2.6k 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

      I feel like I've asked this before but I can't find it anywhere so apologies if I'm repeating myself. I was re-reading the scripting best practices blog post and at the part where it talks about using inline functions rather than normal function in the audio thread it also mentions local variables.

      Does creating local variables inside an inline function called by an audio thread callback impact efficiency? or are local variables magically handled by the pre-compiler?

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

      1 Reply Last reply Reply Quote 0
      • Christoph HartC
        Christoph Hart
        last edited by

        local variables are fine as long as they are simple data types, bool or numbers. Arrays, Objects and Strings are not supposed to be created there though.

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

          Excellent, I'm at the trimming the fat stage of my project, trying to make it as lean as possible :)

          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

          26

          Online

          1.7k

          Users

          11.7k

          Topics

          102.0k

          Posts