为了解决动态参与介质场景连续帧的实时绘制问题,提出了一种基于光流场动态参与介质场景的绘制算法。首先,采用区域匹配的方法计算关键帧之间的光流场;然后,通过插值的方法计算中间帧之间的光流场,采用帧间光流连贯性函数表示帧与帧之间光流一致性的度量,保证帧与帧之间介质运动不会发生突变;最后,按照所产生的光流场,绘制连续动态变化的参与介质场景。在连续5帧动态参与介质场景绘制中,所提算法比基于径向基函数模型(RBF)参与介质的光子映射算法效率提高了近3倍,能够达到连续帧的实时绘制,且绘制质量比较高。
In order to achieve the real-time rendering of continuous frame for participating media scene,a rendering algorithm based on optical flow was proposed. First,the regional matching method was used to calculate the field of optical flow between key frames. Then the field of optical flow between intermediate frames was calculated by the interpolation method,and the optical coherence function between frames was used to denote the consistency of optical flow to guarantee that the media motion won't be suddenly changed. Finally,the dynamic scene of continuous frames was rendered according to the field of optical flow. In the participating media scene rendering for 5 continuous frames,the efficiency of the proposed algorithm increase nearly five times than that of based on Radial Basis Function( RBF) model,real-time rendering of consecutive frames is implemented and rendering quality is relatively high.