SGFrame frame = program.getFrame();
frame.clearGraphics();
try{
synchronized(backgroundObjects){
for(SGObject object : backgroundObjects){
frame.addObject(object);//no origin specified, so add it
}
}
}catch(ConcurrentModificationException e){
System.err.println("Encountered a ConcurrentModificationException while drawing background objects.");
//JOptionPane.showMessageDialog(null, "ConcurrentModificationException!");