Equalizer logo
Collage logo
GPU-SD logo

Dynamic Near and Far Plane support

Author: eilemann@gmail.com
State: Implemented in 0.2.0

Overview

This features adds support for updating the near and far plane from Channel::draw. Updating the near and far plane changes the channel's current frustum, which is acquired by Channel::getFrustum or applied to the current OpenGL context by Channel::applyFrustum.

Implementation

The current implementation, introduced in Equalizer 0.2, updates the current rendering context by setting the frustum's near and far value and by adjusting the left, right, bottom and top value according to the near plane change.

API

    void eq::Channel::setNearFar( const float near, const float far );

Open Issues

Only the current context is modified, subsequent rendering tasks are not affected. Future implementations will have to retain the near and far values set for the following operations, e.g., from Channel::cull to Channel::draw.

Potential rounding problems due to use of float values.

The application has to set the same near/far on all channels, otherwise z-based DB composition does not work.