class LogoFactory {

    public Node createLogoAnimated(Stage stage) {
        final double preferredHeight = stage.getHeight() * 0.1d;
        log.info("preferredHeight = {}", preferredHeight);

        GazePlayAnimatedLogo gazePlayAnimatedLogo = GazePlayAnimatedLogo.newInstance((int) preferredHeight);

        Thread t = new Thread(() -> {
            try {
                Thread.sleep(2 * 1000);
            } catch (InterruptedException e) {
                throw new LogoCreationException(e);
            }
            SequentialTransition animation = gazePlayAnimatedLogo.createAnimation();
            animation.setCycleCount(-1);
            animation.play();
        });
        t.start();
        return gazePlayAnimatedLogo.getLetters();
    }

}