Added option to deal with rotation to the SES3D writer.
Added bounds checking to the SES3D 4.0 writer.