public void flameCmb_changed() {
   if (!refreshing && renderThread != null) {
     Flame selFlame =
         flamesCmb.getSelectedIndex() >= 0
                 && flamesCmb.getSelectedIndex() < project.getFlames().size()
             ? project.getFlames().get(flamesCmb.getSelectedIndex())
             : null;
     if (selFlame != null && renderThread != null) {
       int morphFrameCount = Integer.parseInt(morphFrameCountIEd.getText());
       renderThread
           .getFlameStack()
           .addFlame(selFlame, morphFrameCount, project.getMotions(selFlame));
       if (actionRecorder != null) actionRecorder.recordFlameChange(selFlame, morphFrameCount);
     }
   }
 }
 public void startRender() throws Exception {
   stopRender();
   Flame selFlame =
       flamesCmb.getSelectedIndex() >= 0
               && flamesCmb.getSelectedIndex() < project.getFlames().size()
           ? project.getFlames().get(flamesCmb.getSelectedIndex())
           : null;
   renderThread = new RealtimeAnimRenderThread(this, project);
   renderThread.getFlameStack().addFlame(selFlame, 0, project.getMotions(selFlame));
   actionRecorder = new ActionRecorder(renderThread);
   renderThread.setFFTData(project.getFFT());
   renderThread.setMusicPlayer(jLayer);
   renderThread.setFFTPanel(getGraph1Panel());
   renderThread.setFramesPerSecond(Integer.parseInt(framesPerSecondIEd.getText()));
   renderThread.setDrawTriangles(drawTrianglesCbx.isSelected());
   renderThread.setDrawFFT(drawFFTCbx.isSelected());
   renderThread.setDrawFPS(drawFPSCbx.isSelected());
   actionRecorder.recordStart(selFlame);
   new Thread(renderThread).start();
 }