Navigation

    Fuze Arena Logo
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Users
    • Groups
    • Help
    • Discord

    Moiré Demo

    Creation share codes
    4
    9
    350
    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.
    • vinicity
      vinicity F last edited by


      Download ID: 1L743MND5C

      1 Reply Last reply Reply Quote 5
      • spt games
        spt games last edited by

        Mesmerising! Wait...what was I going to say? ...

        vinicity 1 Reply Last reply Reply Quote 0
        • vinicity
          vinicity F last edited by

          How is it done? Let me tell you:

          I draw two images with lots of concentric circles on them, and then I would like to XOR them while moving them around in Lissajous curves.
          It would have been so much easier if setBlend() had an XOR mode, but alas, it does not.

          So I knew that a XOR b can be described as (a AND NOT b) OR (b AND NOT a), and I didn't want to do this operation for each pixel.
          Solution:

          1. Use setBlend(3), meaning subtraction, to subtract image b from image a. This represents the (a AND NOT b) part of the formula.
          2. Use setBlend(3) again, to subtract image a from image b. This corresponds to (b AND NOT a).
          3. Lastly, just draw the resulting images on each other using the mix mode, setBlend(1), This is the OR part of the formula.

          So I just do this for each frame, and also update the positions by adding some cos() and sin() to get smooth movement curves.

          1 Reply Last reply Reply Quote 3
          • Jonboy
            Jonboy Fuze Team last edited by

            If there was one thing I hoped for at the very beginning of FUZE, it was that a 'scene demo' community would develop. With this and the Plasma demo, we are on our way.

            Hmm.. I feel a competition coming on!

            vinicity 1 Reply Last reply Reply Quote 2
            • vinicity
              vinicity F @spt games last edited by

              @spt-games said in Moiré Demo:

              Mesmerising! Wait...what was I going to say? ...

              You are beginning to feel very sleepy... So very sleepy...

              spt games 1 Reply Last reply Reply Quote 1
              • spt games
                spt games @vinicity last edited by

                @vinicity said in Moiré Demo:

                @spt-games said in Moiré Demo:

                Mesmerising! Wait...what was I going to say? ...

                You are beginning to feel very sleepy... So very sleepy...

                Zzzzz.

                1 Reply Last reply Reply Quote 1
                • vinicity
                  vinicity F @Jonboy last edited by

                  @Jonboy said in Moiré Demo:

                  If there was one thing I hoped for at the very beginning of FUZE, it was that a 'scene demo' community would develop. With this and the Plasma demo, we are on our way.

                  Hmm.. I feel a competition coming on!

                  I would love that!

                  Martin 1 Reply Last reply Reply Quote 0
                  • Martin
                    Martin Fuze Team @vinicity last edited by

                    @vinicity said in Moiré Demo:

                    I would love that!

                    So would I but I'd have no idea how to write one. I have spent many, many hours just watching Amiga demos.

                    1 Reply Last reply Reply Quote 2
                    • vinicity
                      vinicity F last edited by

                      I just re-shared a new version (2.0) of this. It is now much smoother and better optimised than before...

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