Tsparticles: Triangles issues/questions

Created on 6 Oct 2020  路  4Comments  路  Source: matteobruni/tsparticles

Hi, I was playing around with the library using the following options:

tsParticles
  .load("tsparticles", {
    fpsLimit: 30,
    interactivity: {
      detectsOn: "canvas",
      events: { resize: true }
    },
    particles: {
      links: {
        color: "#ff0000",
        distance: 100,
        enable: true,
        opacity: 1,
        width: 0,
        triangles: {
          enable: true,
          color: { 
            value: ['#000000', '#333333', '#666666', '#999999', '#bbbbbb', '#eeeeee']
          },
          opacity: 1
        }
      },
      number: { value: 80 },
      move: {
        enable: true
      },
      opacity: {
        value: 1
      },
      size: {
        value: 0
      }
    },
    retina_detect: true
  });

The goal is to show grayscale triangles and hide particles and links. I'm seeing a few issues, which might be bugs, feature requests or just questions - not sure:

  1. Links are still shown even with width=0. If I use opacity=0, triangles disappear as well. One option is to use opacity=0.0000001, but still feels like there's something wrong.
  2. Sometimes a huge triangle flickers in, connecting particles very far away, just for a frame or so, then disappears. This is likely a bug.
  3. My goal for this test was to smoothly animate the triangles color between #000 and #fff, grayscale only. Is there a way to do it? I wasn't able to do so. With an array of colors (like above) the result is not smooth, they're picked randomly at each frame.

To reproduce you can start from https://codepen.io/matteobruni/pen/QWyGMxZ and just replace JS.

Core Hacktoberfest bug documentation enhancement feature_request good first issue help wanted pinned up-for-grabs

All 4 comments

Issue Label Bot is not confident enough to auto-label this issue. See dashboard for more details.

Hi @natario1,

The color animation on triangles is currently not supported but I can plan it for a future release.

About the far away triangle, I'll have a look as soon as possible, and the width 0 link seems a bug too.

Thanks, and thank you for your work!

Except for color animation now the issues are fixed. 1.18.1 version is available with the fixes

Was this page helpful?
0 / 5 - 0 ratings

Related issues

matteobruni picture matteobruni  路  5Comments

JonasWN picture JonasWN  路  4Comments

BenAOlson picture BenAOlson  路  3Comments

matteobruni picture matteobruni  路  4Comments

matteobruni picture matteobruni  路  5Comments