HISE Logo Forum
    • Categories
    • Register
    • Login

    A couple of expansion questions

    Scheduled Pinned Locked Moved General Questions
    expansionspaint routinepreset browser
    50 Posts 4 Posters 372 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.
    • R
      rzrsharpeprod @d.healey
      last edited by

      @d-healey ok I'll give that a go once I go back up to the laptop in a little while.

      Presumably the type of expansion I have chosen won't have made a difference? I just chose encrypted with the standard 1234 encryption.

      Presuming that the images then load correctly, how do I go about making the clickable so be that the correct expansion loads when clicked?

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

        @rzrsharpeprod said in A couple of expansion questions:

        Presumably the type of expansion I have chosen won't have made a difference?

        Yeah pretty sure encrypted is the correct one - been a while since I used it.

        @rzrsharpeprod said in A couple of expansion questions:

        Presuming that the images then load correctly, how do I go about making the clickable so be that the correct expansion loads when clicked?

        You can assign a mouse callback to each child panel.

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

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

          @d-healey I just encoded each expansion so there was a .hxi file for each of them, closed HISE and reopened the project but still getting the same error unfortunately

          Image {EXP::ExpansionName}Icon.png not found
          

          I really don't know why it isn't working? I have tried various different codes but get the same outcome.
          Is this the same method you have used in the past for Rhapsody or have I done something differently to you?

          @d-healey said in A couple of expansion questions:

          You can assign a mouse callback to each child panel.

          Even with this though I am going to be back to my original issue I think where I am unable to directly load a preset from an expansion aren't I?
          I can use set expansion when something is clicked as I was doing that further up, but if I don't load a preset directly then the BG, control repaint etc doesn't change and it just shows whatever the last BG & control colour scheme was until the user clicks a preset which looks wrong/bad.
          When the expansion is clicked I would like it to also load the correct BG, paint routine etc but I was struggling with it for a few days before I posted and can't find a way to do it.
          I can do it easily from regular presets but not from expansions.

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

            @rzrsharpeprod said in A couple of expansion questions:

            Is this the same method you have used in the past for Rhapsody or have I done something differently to you?

            I'm not using encrypted expansions with Rhapsody so probably not useful.

            @rzrsharpeprod said in A couple of expansion questions:

            I really don't know why it isn't working?

            I suspect that within HISE it reads the files, and once you export it will read the hxi from the app data folder. Test this.

            @rzrsharpeprod said in A couple of expansion questions:

            where I am unable to directly load a preset from an expansion aren't I?

            Yep, this is still bugged. You'll need a different workflow until it's fixed.

            @rzrsharpeprod said in A couple of expansion questions:

            but if I don't load a preset directly then the BG, control repaint etc doesn't change

            We can work on this later, I think we can make it load based on the expansion rather than the preset.

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

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

              @d-healey said in A couple of expansion questions:

              I suspect that within HISE it reads the files, and once you export it will read the hxi from the app data folder. Test this.

              Oh do you mean build it and test it in DAW? I only encrypted and then tested again in HISE so I misunderstood if you meant test in DAW.

              Regarding the mouse events for the child panels, as I can't individually set the child panel to allow callbacks if I set the main panel to allow callbacks do the child panels then inherit those same properties?

              What is the best way to distinguish which of the child panels is being hovered over/clicked etc? Presumably I can do it dynamically somehow (how) rather than coding the x & y values for each to say if x & y = this then load exp 1, if x & y = that then load exp 2 etc

              @d-healey said in A couple of expansion questions:

              We can work on this later, I think we can make it load based on the expansion rather than the preset.

              I hope so but I tried the methods that were obvious to me and I think a lot of the issues were whatever I tried would end up clashing with other parts of the code that were working fine before that.
              I am not sure if it is making it worse because I am using radio buttons to control the background selection and to drive which paint routine is used?
              I did this to reduce the amount of code, but it seems if you call a radio button in more than 1 function it doesn't like it and stops one or both from working.

              Otherwise I could leave the preset selecting the relevant radio buttons which is working fine and then have the when x is clicked to load the expansion from the grid also set the radio buttons values but it didn't seem to like that at all and just stopped the presets working as an example.

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

                @rzrsharpeprod said in A couple of expansion questions:

                Oh do you mean build it and test it in DAW? I only encrypted and then tested again in HISE so I misunderstood if you meant test in DAW.

                Don't get a DAW involved it just adds complexity. Make a standalone build of the test project.

                @rzrsharpeprod said in A couple of expansion questions:

                I can't individually set the child panel to allow callbacks

                Why not?

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

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

                  @d-healey said in A couple of expansion questions:

                  Why not?

                  Because I don't know how to essentially. I don't know much about child panels as I have never even come across the concept until a couple of days ago and when I did I tried to research on the forum etc first as I always do as I like to try and solve issues myself if I can. There doesn't seem to be that much info on them and the bit there are mainly threads with specific issues.

                  I have no idea what you can do with them really, other than they seem to be the only way to get this grid working.

                  I have been spinning my wheels for nearly a week now and have made little to no progress which is very unlike me and it has me extremely frustrated.
                  Whenever I do anything with expansions it never goes smoothly due to the added complexity. The grid on top is just a whole different beast in this case

                  What I have to figure out in order to get the project back on track is the following. :

                  • How to get the images loaded onto the child panels in the grid
                  • How to add a drop shadow to the child panels
                  • How to add a dynamic label to the child panels for the name. I could include the text in the image to get around this but I would rather not but it isn't as clean looking
                  • How to change the child panel colour slightly when it is being hovered over.
                  • How to load the expansion AND change all of the elements that should be displayed for that expansion (BG, control paint routine etc)

                  1 & 5 are proving particularly difficult as you know so I haven't even attempted 2,3 or 4 yet and at least 2 of those are going to require me to reference the child panels individually I assume which brings me back to the start of this reply...

                  I even just did a quick callback test on the main panel and even that didn't go smoothly. The hover event worked fine but the click event only registered if you click somewhere where there wasn't a child panel. So even something as simple as that isn't going smoothly so I am starting to question my own sanity.
                  Admittedly part of that is my lack of understanding of the child panels so it's all feeding into each other and slowly chipping away to make me feel dumber by the day

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

                    @rzrsharpeprod said in A couple of expansion questions:

                    I don't know much about child panels

                    They are just the same as any old regular panel, the only difference is they are created dynamically.

                    Any property you can set for a panel also applies to a child panel - you have to do it through code though instead of the interface designer.

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

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

                      @d-healey ok first off I didn't see your reply before I started building it so I ended up testing it in DAW as it was built. Still the same result with the XXX placeholders/missing images.
                      If I delete the expansion folders in AppData and open it in DAW they are gone and it's just a blank background so it is reading them. If I put them back and reopen it reads the correct amount so that part is working, it just won't load the images in HISE or in DAW. Something must be wrong with the code surely? Or it is a bug but I wouldn't be confident saying that.

                      @d-healey said in A couple of expansion questions:

                      They are just the same as any old regular panel, the only difference is they are created dynamically.

                      Any property you can set for a panel also applies to a child panel - you have to do it through code though instead of the interface designer.

                      But that is the part that I can't quite get my head around. Because they are dynamic how do I code/tell HISE what to do for a specific one? In some cases there may only be 1, others there could be 5 or more expansions installed so the tiles are on different rows etc. I know I don't have to code every possible example using if elses and xy references as that would be bonkers, but I don't know how to reference them dynamically as they may or may not be there.

                      It just isn't making sense to me. I can do all of the children as I did last night with the images and I can do stuff to the parent panel but I do not know how to reference child 1, child 2 etc and have actions specific to them

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

                        @rzrsharpeprod said in A couple of expansion questions:

                        Something must be wrong with the code surely?

                        Maybe, is the Icon.png in the expansion's images folder?

                        @rzrsharpeprod said in A couple of expansion questions:

                        how do I code/tell HISE what to do for a specific one?

                        The parent panel has an array that contains all the children. You can access any one of them individually by their index and set the properties you want.

                        Or the simplest way is to do it in the creation loop because at that point you have each individual child stored in the cp variable as it's created. So you can enable mouse callbacks and stuff at that point.

                        The great thing is you don't need to treat them all separately. Thing of this, when you create the child panel you store the expansion name associated with it in its data property.

                        Then in the generic mouse click callback which you apply to all children, you just check which expansion this particular panel is associated with and load the expansion. One function to rule them all :)

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

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

                          @d-healey said in A couple of expansion questions:

                          Maybe, is the Icon.png in the expansion's images folder?

                          Yes, each expansion has an image called Icon.png in the images folder. The case is correct Icon with a capital I.
                          I even added a preset browser as a test and used the code I got from your tutorial to check and the images loaded just fine in the expansions column of that preset browser so everything is where it should be .

                          @d-healey said in A couple of expansion questions:

                          Or the simplest way is to do it in the creation loop because at that point you have each individual child stored in the cp variable as it's created. So you can enable mouse callbacks and stuff at that point.

                          The great thing is you don't need to treat them all separately. Thing of this, when you create the child panel you store the expansion name associated with it in its data property.

                          Then in the generic mouse click callback which you apply to all children, you just check which expansion this particular panel is associated with and load the expansion. One function to rule them all :)

                          To be honest, I know this is solid advice but as I said I have spent days on this and reading it just made me genuinely sad that I probably understand it less now than I would have done last week. It has properly scrambled my brain trying to figure this out. I'm so close to just throwing in the towel as it is stressing me out more than it should do at this point as I feel I am no further forward, possibly even less so than I was at this point a week ago

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

                            @rzrsharpeprod said in A couple of expansion questions:

                            Yes, each expansion has an image called Icon.png in the images folder.

                            Ok, we'll investigate that later. Probably a simple fix.

                            @rzrsharpeprod said in A couple of expansion questions:

                            To be honest, I know this is solid advice but as I said I have spent days on this and reading it just made me genuinely sad that I probably understand it less now than I would have done last week. It has properly scrambled my brain trying to figure this out. I'm so close to just throwing in the towel as it is stressing me out more than it should do at this point as I feel I am no further forward, possibly even less so than I was at this point a week ago

                            Take a break, come back to it in a couple of days. If I find some time I'll try and make a video about child panels. I think you need one of those moments that triggers something and it will suddenly all click into place.

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

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

                              @d-healey said in A couple of expansion questions:

                              Ok, we'll investigate that later. Probably a simple fix.
                              Thankyou, do you need another snippet or is the one further up here ok? Nothing much has changed so I think it probably will be ok.

                              @d-healey said in A couple of expansion questions:

                              Take a break, come back to it in a couple of days. If I find some time I'll try and make a video about child panels. I think you need one of those moments that triggers something and it will suddenly all click into place.

                              You're right but that's exactly what I did when I couldn't crack this after a couple of days. That has just ended up ramping up the pressure on me to get this done as now I have less time to get it built due to the days spent basically idling.

                              Yeah I agree re a trigger moment. You have done so much already and I appreciate it but would you be able to post a snippet of how you would add a label or the hover to the child panels so I can at least get my head around it and see how it should be done. I can at least then extrapolate it out to try and get some other parts of the project ticked off. Right now the only thing that is ticked off is me haha

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

                                @rzrsharpeprod said in A couple of expansion questions:

                                You have done so much already and I appreciate it but would you be able to post a snippet of how you would add a label or the hover to the child panels

                                Do you know how to do it for a panel - a regular panel?

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

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

                                  @d-healey said in A couple of expansion questions:

                                  @rzrsharpeprod said in A couple of expansion questions:

                                  You have done so much already and I appreciate it but would you be able to post a snippet of how you would add a label or the hover to the child panels

                                  Do you know how to do it for a panel - a regular panel?

                                  Yes, I was messing with hovering the other day when I was toying with using panels as buttons.

                                  With the label I would either add it via code the correct way or sometimes just create a label and attach it to the panel in the component list for speed.

                                  But this goes back to me just not getting it when it comes to the child panels and the fact that they are dynamic, can be 1 or many and all have different positions etc. I am just not understanding how it works hence me asking for the example. I just don't get it and the more I try the more I get annoyed with myself for not getting it.
                                  I don't think the penny is going to drop until I see it working and can pull apart the code to understand it...and then I am going to feel like a fool for not getting it sooner. But at least then I will get it.
                                  I'll happily take being a fool who understands it over a frustrated fool who doesn't

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

                                    @rzrsharpeprod I've updated the snippet and added some more comments that might help

                                    HiseSnippet 1718.3ocsWs0aaaCEVJMZaxaEXcXOtGHB1vja7braaRJVVQyklzZrbwnN8xaEzRzVbQlTPjNNFEc6OxdX+D2+fsygTxR1wsqHX0OHXxyE9ctxC6lICYJkLyws14SSYNtekWuoBc7AwTtvoySbb+NutTAKgjRyXBMgJhHgw7jHxq5z0Y+ooTkhE435dqmhR35upi42e+38oITQHqbKGmWJ4gri4i35xc6t6uxSRNhFwNmOpB2OX2NgRwAxD4X.c2xqkSJM7B5P1oTjsU7bdFUE63dWO58ZytWzl8u+1au4.VqM2rEay1a2ht0fVOHZvC2Zy62ue6H1VNte1gQbsLqmlpYJG2U2WFMsWrbhvd.ujq38SX3h1N8fS1t8QxjHzDwccN.s8tEtMkCnktkNwaYcheq2I7H9r8Kclesg.oThpNP2UlGd2ZN30tJ7ZUAdKARtUfzpVHcGudgY7TcIEDOeoWGglkMfBwopPwxqyJM88NPBbHzMGQufcTFrXlDAa0pUCB7o9N0pAwJklb5KN4MG95t6cZuNmcZOxi.p6P1XCx4wbEYBDmI8YDcLiHFOpOKiHGPXWkREJNHdEcbvYGiR+.ivmNi2PYx3QyX7j8d9S6bJvVa6gzCRPXvAnmvXhBdMIrYxIpBHdIMijJRdZFOBDsv5FxzGHGkJEvhf0xouFZXargMcOEqBpwEIbAiLXrHTCXlDlwffkMBfLnBpW6sD3WM7ShLjl.1cjNFNqfb0hG1qv8BpS9obqnNYiRCuXycpnDvg8bvJ.0bBUG2LjwSBVvaWpg5UkLlwGFqAAM3XGDaFpCjYj.NrO383jeYgXGr25qW2v3aMeKUXXJHTgsPihJs9f5l.wdZHFCA7TIG5X.rC++2FC99D9ELHfLkHgbf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ey8hIO4PIOwsJTbbp.k1K.k+52WDJO6O209dnJGXoI5b8wugA+kQiSn54eM.9lobBP90bifiiYCyEqmV8MU+u8DgOVHdGutbcX7xw3JKAiPFzmBLl+vpa6cHLkWntDfq5czq+z7JJG6.KCglpYbHUwCdGRO395PnaDUfshf8bWAqDsqagqQOPOlHxr3efe4DaiqcyI1tfnyHJjQ+lPa8K9zsuvrCfIg4Yt9dmfqIsudI6H3kjuILbdUcMAu2MUv6eSE7A2TA27lJ3V2TA29lJ3C+uEDen+di0xQ1xFGmS5dnoEqq6gloxMYqN+KXFU+GF
                                    

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

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

                                    19

                                    Online

                                    1.9k

                                    Users

                                    12.4k

                                    Topics

                                    107.7k

                                    Posts