Forum
    • Categories
    • Register
    • Login

    Macros - Clear All?

    Scheduled Pinned Locked Moved General Questions
    28 Posts 3 Posters 2.8k 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.
    • DanHD
      DanH @David Healey
      last edited by DanH

      @d-healey said in Macros - Clear All?:

      BackendComponents.cpp

      Isn't that more for Midi Controls? What about MacroControlledComponents.cpp?

      Line 193 ish?

      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
      https://dhplugins.com/ | https://dcbreaks.com/
      London, UK

      David HealeyD 1 Reply Last reply Reply Quote 0
      • David HealeyD
        David Healey @DanH
        last edited by

        @DanH When you right-click on one of the macro knobs it says "Clear MacroControls". I searched the source code for that string and it appears in the place I mentioned. So that's where I would start, take the functionality that's already there and wrap it into a script function. If you find another way of doing it then go for it!

        Free HISE Bootcamp Full Course for beginners.
        YouTube Channel - Public HISE tutorials
        My Patreon - HISE tutorials

        1 Reply Last reply Reply Quote 0
        • DanHD
          DanH @David Healey
          last edited by

          @d-healey Interesting, I've found the option you referred to. It clears the assigned controls but also resets the name of the macro which was defined in LAF so.... hmmmm!

          DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
          https://dhplugins.com/ | https://dcbreaks.com/
          London, UK

          David HealeyD 1 Reply Last reply Reply Quote 0
          • David HealeyD
            David Healey @DanH
            last edited by David Healey

            @DanH Looking in the source you'll see the control does those things separately, so you don't have to wrap all of the functionality in the scriptable function, just the part you want.

            Free HISE Bootcamp Full Course for beginners.
            YouTube Channel - Public HISE tutorials
            My Patreon - HISE tutorials

            DanHD 2 Replies Last reply Reply Quote 0
            • DanHD
              DanH @David Healey
              last edited by

              @d-healey yep I'm searching now, thanks! :) 🤓

              DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
              https://dhplugins.com/ | https://dcbreaks.com/
              London, UK

              1 Reply Last reply Reply Quote 1
              • DanHD
                DanH @David Healey
                last edited by

                @d-healey Ok so how does one wrap stuff into a script function?! 😂

                DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                https://dhplugins.com/ | https://dcbreaks.com/
                London, UK

                David HealeyD 1 Reply Last reply Reply Quote 0
                • David HealeyD
                  David Healey @DanH
                  last edited by

                  @DanH

                  https://www.youtube.com/watch?v=PT0N99yBhIg

                  Free HISE Bootcamp Full Course for beginners.
                  YouTube Channel - Public HISE tutorials
                  My Patreon - HISE tutorials

                  DanHD 1 Reply Last reply Reply Quote 0
                  • DanHD
                    DanH @David Healey
                    last edited by

                    @d-healey Thanks, I had a play with the code and couldn't find a way to prevent the name resetting.

                    I was commenting out lines from this bit at 206, but it was all or nothing. Perhaps it's elsewhere in the script. The function here is for one Macro at a time, but I guess it could be tweaked to apply to all.

                    	if(result == -1)
                    		{
                    			synthChain->getMainController()->getMacroManager().setMacroControlMidiLearnMode(synthChain, index);
                    			synthChain->getMainController()->getMacroManager().setMidiControllerForMacro(-1);
                    
                    			synthChain->clearData(index);
                    
                    			macroNames[index]->setText("Macro " + String(index + 1), dontSendNotification);
                    
                    		}
                    

                    DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                    https://dhplugins.com/ | https://dcbreaks.com/
                    London, UK

                    David HealeyD 1 Reply Last reply Reply Quote 0
                    • David HealeyD
                      David Healey @DanH
                      last edited by David Healey

                      @DanH said in Macros - Clear All?:

                      synthChain->clearData(index);

                      So now you need to dig deeper and find out what the clearData function does.

                      Free HISE Bootcamp Full Course for beginners.
                      YouTube Channel - Public HISE tutorials
                      My Patreon - HISE tutorials

                      DanHD 1 Reply Last reply Reply Quote 0
                      • DanHD
                        DanH @David Healey
                        last edited by

                        @d-healey Hmmm... need a hint, where to look perhaps? To me it looks like it clears the data collected in the lines above.

                        DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                        https://dhplugins.com/ | https://dcbreaks.com/
                        London, UK

                        David HealeyD 1 Reply Last reply Reply Quote 0
                        • David HealeyD
                          David Healey @DanH
                          last edited by

                          @DanH Find the function definition and see what it's doing

                          Free HISE Bootcamp Full Course for beginners.
                          YouTube Channel - Public HISE tutorials
                          My Patreon - HISE tutorials

                          DanHD 1 Reply Last reply Reply Quote 0
                          • DanHD
                            DanH @David Healey
                            last edited by

                            @d-healey I'm getting confused. Is it defined in the the file, or is it a more general c++ thing?

                            DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                            https://dhplugins.com/ | https://dcbreaks.com/
                            London, UK

                            David HealeyD 1 Reply Last reply Reply Quote 0
                            • David HealeyD
                              David Healey @DanH
                              last edited by

                              @DanH clearData is a function, so somewhere in the HISE sourcecode there must be a place where that function is defined, it will look something like (but not exactly the same as):

                              function clearData()
                              {
                              }
                              

                              Free HISE Bootcamp Full Course for beginners.
                              YouTube Channel - Public HISE tutorials
                              My Patreon - HISE tutorials

                              DanHD 1 Reply Last reply Reply Quote 0
                              • DanHD
                                DanH @David Healey
                                last edited by

                                @d-healey gotcha

                                DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                https://dhplugins.com/ | https://dcbreaks.com/
                                London, UK

                                DanHD 1 Reply Last reply Reply Quote 0
                                • DanHD
                                  DanH @DanH
                                  last edited by DanH

                                  @d-healey searched the SC for clearData... Nothing pertinent coming up :/

                                  DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                  https://dhplugins.com/ | https://dcbreaks.com/
                                  London, UK

                                  ulrikU 1 Reply Last reply Reply Quote 0
                                  • ulrikU
                                    ulrik @DanH
                                    last edited by

                                    @DanH is it this you're looking for?

                                    Skärmavbild 2021-07-15 kl. 13.13.56.png

                                    Hise Develop branch
                                    MacOs 15.6.1, Xcode 16.2
                                    http://musikboden.se

                                    DanHD 1 Reply Last reply Reply Quote 0
                                    • DanHD
                                      DanH @ulrik
                                      last edited by

                                      @ulrik Thanks, I honestly don't know 😂

                                      Does it define the function of clearData

                                      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                      https://dhplugins.com/ | https://dcbreaks.com/
                                      London, UK

                                      ulrikU 1 Reply Last reply Reply Quote 0
                                      • ulrikU
                                        ulrik @DanH
                                        last edited by

                                        @DanH Yes I think this is where the function is defined, better ask David :)

                                        Hise Develop branch
                                        MacOs 15.6.1, Xcode 16.2
                                        http://musikboden.se

                                        David HealeyD 1 Reply Last reply Reply Quote 0
                                        • David HealeyD
                                          David Healey @ulrik
                                          last edited by

                                          @ulrik Looks like a function definition to me, of course there could be more than one clearData function so make sure it's in the right class (what ever object type synthChain is).

                                          Free HISE Bootcamp Full Course for beginners.
                                          YouTube Channel - Public HISE tutorials
                                          My Patreon - HISE tutorials

                                          DanHD 1 Reply Last reply Reply Quote 0
                                          • DanHD
                                            DanH @David Healey
                                            last edited by

                                            @d-healey it never ends! 😂

                                            DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                                            https://dhplugins.com/ | https://dcbreaks.com/
                                            London, UK

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

                                            16

                                            Online

                                            2.1k

                                            Users

                                            13.0k

                                            Topics

                                            112.6k

                                            Posts