Just include opengl software in the first line of code as a comment to remind the user that he needs to switch opengl use of matlab to software, otherwise the program crashes