HISE Logo Forum
    • Categories
    • Register
    • Login

    Learning Hise scripting , my "Journey"

    Scheduled Pinned Locked Moved Scripting
    5 Posts 2 Posters 310 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.
    • lalalandsynthL
      lalalandsynth
      last edited by lalalandsynth

      I thought I would just make one thread where I can ask questions about HISE scripting as I encounter them rather then flood the forum with questions. I am just doing some basic examples from the docs as it is.

      Question 1.

      I am doing the loading images example from the docs https://docs.hise.audio/scripting/scripting-in-hise/scriptpanel.html
      Sometimes things dont work as expected and I am unsure if something has changed with the HISE operates or what is up.

      Right now I am doing this and its throwing up an error Unknown function loadImage
      It will also not autofill the setPaintRoutine ?
      Also should setPaintRoutine and loadImage not have a different color ?

      Content.makeFrontInterface(600, 500);
      
      panel.loadImage("{PROJECT_FOLDER}Bkg Main New 2.png", "Background");
      
      
      panel.setPaintRoutine(function(g)
      
      {
         
         g.fillAll(Colours.white);
         g.drawImage("Background", [0, 0, 200, 200], 0, 0);
         g.drawImage("Background", [200, 0, 300, 200], 0, 0);
         
         
      });
      

      https://lalalandaudio.com/

      https://lalalandsynth.com/

      https://www.facebook.com/lalalandsynth

      https://www.facebook.com/lalalandsynth

      ustkU 1 Reply Last reply Reply Quote 0
      • ustkU
        ustk @lalalandsynth
        last edited by

        @lalalandsynth You haven't declared the panel

        Can't help pressing F5 in the forum...

        lalalandsynthL 1 Reply Last reply Reply Quote 0
        • lalalandsynthL
          lalalandsynth @ustk
          last edited by lalalandsynth

          @ustk oops, that was obvious .. thanks
          Now it says , Image not found , is there a problem with having spaces in the filename ?

          https://lalalandaudio.com/

          https://lalalandsynth.com/

          https://www.facebook.com/lalalandsynth

          https://www.facebook.com/lalalandsynth

          ustkU 1 Reply Last reply Reply Quote 0
          • ustkU
            ustk @lalalandsynth
            last edited by

            @lalalandsynth That's easy to figure out :)
            Although when you modify an image, don't forget to update the Image Pool

            Can't help pressing F5 in the forum...

            lalalandsynthL 1 Reply Last reply Reply Quote 1
            • lalalandsynthL
              lalalandsynth @ustk
              last edited by lalalandsynth

              @ustk Yep , saw it ..:) Now it compiles but no pic shown , lol ....getting there .
              what do you mean by update the image pool ?
              I am assuming I can place it in the images folder and show it via that script ?

              EDIT: It works !

              https://lalalandaudio.com/

              https://lalalandsynth.com/

              https://www.facebook.com/lalalandsynth

              https://www.facebook.com/lalalandsynth

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

              30

              Online

              1.8k

              Users

              12.0k

              Topics

              104.7k

              Posts