nextFrame() {
    const { length } = this.materials;

    this.index++;
    if (this.index >= 1) {
      this.index = 0;
      this.frameIndex++;

      if (this.loop && this.frameIndex >= length) {
        this.frameIndex = 0;
      }
    }
  }
draw the next frame of video
@private