optimizations introduced an issue into physics shape generation