Forum

    • Register
    • Login
    • Search
    • Categories

    Post init callback

    Feature Requests
    3
    7
    417
    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.healey
      d.healey last edited by d.healey

      I have need to trigger some components in my secondary scripts from my main interface script at init. The problem is the init function of the main script triggers before all of the other scripts are initialiased. My current solution is to use a timer in the main script to delay this action but this is imprecise.

      A better way I think would be to have a post init callback that triggers after everything (not just the main script) is ready.

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

      ustk 2 Replies Last reply Reply Quote 2
      • ustk
        ustk @d.healey last edited by ustk

        @d-healey That would be nice to have indeed...

        In the waiting, what if you do the opposite? check from the secondary scripts the state of the interface script components?

        Or even a script at the end of the "script chain", so it is the last one to be triggered and checks for everything that you need? I never tried such a thing...

        I can't help pressing F5 in the forum...

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

          @d-healey It should work. I just tested and the component's CBs are called before the init of the next script begins...

          I can't help pressing F5 in the forum...

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

            @ustk said in Post init callback:

            what if you do the opposite? check from the secondary scripts the state of the interface script components?

            The timer is fine for me for now until we have a proper solution.

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

            ustk d.healey 2 Replies Last reply Reply Quote 1
            • ustk
              ustk @d.healey last edited by ustk

              @d-healey I have kind of the same issue with the samplerate. It is not ready at init so I use a timer that sets all the depending variables.
              Not a neat solution because I cannot use const variables since they cannot be updated later.

              I can't help pressing F5 in the forum...

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

                @d-healey said in Post init callback:

                The timer is fine for me for now until we have a proper solution.

                Problem with the timer. If you reopen a saved session in the DAW it will run the timer and reload the default preset. I think the same problem will exist with a post init callback too...

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

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

                  Did this ever get implemented? I seem to recall @Christoph posting something about it recently but I cant find anything with a forum search.

                  HISE Development for hire.
                  www.channelrobot.com

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

                  10
                  Online

                  1.2k
                  Users

                  7.0k
                  Topics

                  64.7k
                  Posts