HISE Logo Forum
    • Categories
    • Register
    • Login

    How to build SNEX Playground?

    Scheduled Pinned Locked Moved General Questions
    38 Posts 4 Posters 1.7k 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.
    • ustkU
      ustk @Casmat
      last edited by

      @Casmat So I imagine a is your gain, right?
      What do you get as a result? Is it at least sounding "something"?
      Does the level need to be tamed a bit perhaps?

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

      CasmatC 1 Reply Last reply Reply Quote 0
      • CasmatC
        Casmat @ustk
        last edited by

        @ustk as far as I know when looking at it, I thought that x was the input signal and a was the saturation amount

        i make music

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

          @Casmat said in How to build SNEX Playground?:

          Edit: so the gain factor is x?

          f(x) means the it's the output, so a should be the gain

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

          CasmatC 1 Reply Last reply Reply Quote 0
          • CasmatC
            Casmat @ustk
            last edited by Casmat

            @ustk ohh yeah! Polynomials (or maybe not)!

            i make music

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

              @Casmat At first, does it look the way you want?

              ![Screenshot 2023-08-18 at 20.47.17.png](Imgur is temporarily over capacity. Please try again later.)

              EDIT @Christoph-Hart @Dominik-Mayer Apparently there's still this Imgur over capacity issue that prevents us to see images...

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

              CasmatC 1 Reply Last reply Reply Quote 0
              • CasmatC
                Casmat @ustk
                last edited by Casmat

                @ustk why was there an float s in the arguments? And I should be declaring a as a variable, right? I put the code you gave

                if (x < a)
                   out = x;
                else if (x > a)
                   out = a + (x - a) / (1.0 + Math.sqr((x - a) / (1.0 - a)));
                else if (x > 1)
                   out = (a + 1.0) / 2.0;
                

                In the get sample func?

                Edit: didn’t see your post yet, the img seems broken

                i make music

                Christoph HartC 1 Reply Last reply Reply Quote 0
                • CasmatC
                  Casmat @ustk
                  last edited by Casmat

                  @ustk try using imgbb.com

                  i make music

                  ustkU 2 Replies Last reply Reply Quote 0
                  • Christoph HartC
                    Christoph Hart @Casmat
                    last edited by

                    @Casmat if imgur is over capacity then there‘s nothing we can do except for stop uploading images :)

                    ustkU 1 Reply Last reply Reply Quote 2
                    • ustkU
                      ustk @Christoph Hart
                      last edited by

                      @Christoph-Hart Yeah I though it was somehow related to the forum... Or use another provider 😛

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

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

                        @Casmat

                        SOS image provider

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

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

                          @Casmat You definitely need to declare a
                          At first, make it 0.0
                          Then add a parameter to control it

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

                          CasmatC 2 Replies Last reply Reply Quote 0
                          • CasmatC
                            Casmat @ustk
                            last edited by Casmat

                            @ustk shouldn’t the a be from 0-1? And there were some comments under that music dsp post, do we have to do normalization or am I yapping away at nothing?

                            i make music

                            CasmatC 1 Reply Last reply Reply Quote 0
                            • CasmatC
                              Casmat @Casmat
                              last edited by Casmat

                              @Casmat and as for the image, isn’t that how the saturation should look like

                              i make music

                              1 Reply Last reply Reply Quote 0
                              • CasmatC
                                Casmat @ustk
                                last edited by

                                @ustk hmm, seems like im missing part of the picture, im not really understanding the whole use of the soft saturation function vs other common saturation functions like a tanh function, have you got any resources that can help me learn more about saturation dsp or dsp in general a bit more? I feel like getting a better understanding would help me ease my way into Snex cause I have little clue what all this dsp does. Thanks for your help so far, opened my eyes to the vastness amount of info I’m missing and I’m pretty eager to learn more! After taking some time to research, it may be right to jump back at this, right?

                                i make music

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

                                  @Casmat A good sounding distortion unit is much more than just the saturation function. It needs clever filtering, oversampling to remove aliasing, etc... Tanh is a good starting point, but you need to understand if you want more or less of the odd or even harmonics, or asymmetric distortion. And this is only the beginning, as a "true analog sounding" algorithm is much more... You might find some literature about this in your fav search engine. The first steps you've made is a good start! Just go for a simpler equation until you know what it does 😉

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

                                  CasmatC 3 Replies Last reply Reply Quote 0
                                  • CasmatC
                                    Casmat @ustk
                                    last edited by

                                    @ustk Thanks! Will definitely take a look!

                                    i make music

                                    1 Reply Last reply Reply Quote 0
                                    • CasmatC
                                      Casmat @ustk
                                      last edited by Casmat

                                      @ustk Think I'm ready to try again with the saturator, did some research on the topics and I feel much more confident going forward! Seriously, thank you haha! Instead of going for that other formula, i found a more simpler cubic formula: https://www.hackaudio.com/digital-signal-processing/distortion-effects/soft-clipping/

                                      So with the formula, would the equation in snex look something like this?

                                      out = in - a * (1.0 / 3.0) * Math.pow(in, 3);
                                      

                                      Edit: All the filtering/oversampling should be done with other nodes in scriptnode, right? or is it within the snex shaper node itself?

                                      HiseSnippet 1321.3oc2X0sSbaDEdLvPxRRpZhRT6k9hdAQJEsKMMsR8h.rvlrpYAKLkj6PSrmkczNdFKOiA1V066iUeD5iPeDxaP643wK1FVQgsoIsEjf87yLy24+CDjoi3FiNi305fIobh2cogST1QcGwDJR+sIdeBc.yX4Y9NVaMIkYL7Xhm2hu.Y30ZIRwWu64awjLUDuhEgbnVDwekHQXq3Frw2KjxdrX9AhjZZ+zM5GoUc0RcNfmEosIornwri46xP0VfR7VdmXgUmEZYVtAzYKc7jvQ5SUN8OTXDuUxQhNjP3hbrIcGIjwASsUCg3QCpr7EcV9CoCDwhy4W4A9zBA9UmntOvagqBRctAPxqFjVxAo6SCixDo1JIHdtCsuBBHCYfqtNTb5R79UZWMnfxtVBaLuWFPb9AV8Ysa+De3GO96FlqhrBsxWq1Ua46oV8wq7SqzZkedE+KJZ3vYJCelLsTxyloXL5lcUGbUUdxa4YOw+DlLmethf42zmt70ymF4r5ZJpU8UB6do7R5dZYL5qvOe4H.ozsAe5G5uMyxvfRIOPuTdlUfvwaa9IPVsKD0htM2L1pSg75KE+fLGcbtjYal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ha6EJt+MIAFWbTTDlu9kvzmYel0miy7UywYd5bbludNNyyliy7MywY91q7L3j5Mys5DWNOvHXG2JxdtMWJR+I+I5asV1C
                                      

                                      Thanks!

                                      i make music

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

                                        @Casmat for these simple one liners you can also use the math.expr node, just rename your variables to input and value and you can use the single parameter as drive parameter:

                                        output = input - value * (1.0f / 3.0f) * Math.pow(input, 3.0f);
                                        

                                        and yes, the filtering and oversampling can be done with dedicated nodes.

                                        CasmatC 2 Replies Last reply Reply Quote 0
                                        • CasmatC
                                          Casmat @Christoph Hart
                                          last edited by

                                          @Christoph-Hart ooh! That's definitely useful! Thanks Christoph!

                                          i make music

                                          1 Reply Last reply Reply Quote 0
                                          • CasmatC
                                            Casmat @Christoph Hart
                                            last edited by

                                            @Christoph-Hart Oops tried it, but it seems to not make a distorting sound, am I supposed to do more than adding the math.expr node?

                                            HiseSnippet 1591.3oc0X0sTaaDEdkMKDbn+jNIS6zqzjoWP5PnVNo.o4hvuNgIwfGDgvMcxrHs1dGj1UizJ.2L499XkGg9HzGg7FPO6tRHIvCAbSosjYB97yt642uywzMV3QSRDwHqo2cXDEYMC1cHWNXsADFGs45HquD2gjHow1FVqNLhjjP8QVV0ethg0zSfz+7wmsJIfv8nErPn8DLO5qXgLYA2tK+RVPPahOcWVXIse7xa5I3qIBDof8TG2DEQ7NjzmtEQoVMLxZxM7YRQrqjHoIfNqJ7G5NPbL2n+drD1AATEgCxEtHCazZCXA9cy80DDxB2svyqa776h6v7YmwuHB70ZA1EmnbLvp1kYRNWCSxpjIMgwjtC10KlEIKjnrmai2jCIjdDHTW1TL5hr9.dMAn.WNeH4PZ6Xf3rCL6BMaNmM7eO3o8R4dRlfaK3aIjzs4y9fFuqwzMdeC6yKpWuQJS8Lwhf.Z7HEqxtwW1AmkmFd.MdN6iHAozyTDb+pwzIuZwTOiWWRQAeSNStcDMits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UpgVUHNLjnqkGqcSJCGdOivaieCLjVurutF6dZ5dh3P6mSgxOEVtykrt+ebUW2O5JutuYugcg46IQhDXqnR274j0prr0oxTdU0Mrpnkx8ZCtmS4TSNyRZdqk6R3UtLftxM0gUZcs+7YavI.7mKE7F+sS7.mkTo5.tfTXW.81RNkOXA6VkY+BXABHu3UYvX8pXvSb0vfqtiPI8GwHqI+m5qDMwUaJ5mX47+6uWTkg9SmaitL0v5M3GQCf1TsM9M3r0Yy4VsOqifKxGmTTArCEFZ1uOsJrynbnUjRXe3BN2c4cnATRRodueX4WAiXHwczC.FqXw0+ayNx702gMlqsBbv9uSd6FsL6R2ss9UZ21O6163um6MbGJfe9+mL82hAL8V15zs8+946ahUnuIdiPhWr3sdlu4gBv3VZNfey0+09lF2QQa6fNxrEDVsGNJDF67VOOUM8Cg3ynOSqw3LOZLNyiGiy7yiwYVXLNyhiwYV5ROiZh+JoRQno9GXzcC8lnVVlMfzsBn+BToL8JA
                                            

                                            i make music

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

                                            25

                                            Online

                                            1.7k

                                            Users

                                            11.8k

                                            Topics

                                            102.7k

                                            Posts