Mapping Camera Settings

This section shows how to map the Softimage camera settings to the corresponding mental ray settings.

Projection plane on:

    // Convert from inches to cm (Softimage units)
    ppwidth = 2.54 * cam.projplanewidth
    ppheight = 2.54 * cam.projplaneheight
    ppoffsetx = 2.54 * cam.projplaneoffx
    ppoffsety = 2.54 * cam.projplaneoffy

    mr.aspect = cam.projplanewidth / cam.projplaneheight
    mr.aperture = cam.focal * ( cam.projplanewidth / projplanedist )
    mr.x_offset = ( render_res.x * ppoffsetx ) / ppwidth
    mr.y_offset = ( render_res.y * ppoffsety ) / ppheight

Projection plane off:

    mr.aspect = cam.aspect
    mr.aperture = cam.aperture
    mr.x_offset = mr.y_offset = 0

Orthographic off:

    mr.orthographic = miFALSE
    mr.focal = cam.focal

Orthographic on:

    mr.orthographic = miTRUE
    mr.focal = 1.0

Autodesk Softimage v7.5