KR100900822B1 - System and method for real-time relighting system - Google Patents
System and method for real-time relighting system Download PDFInfo
- Publication number
- KR100900822B1 KR100900822B1 KR1020070107056A KR20070107056A KR100900822B1 KR 100900822 B1 KR100900822 B1 KR 100900822B1 KR 1020070107056 A KR1020070107056 A KR 1020070107056A KR 20070107056 A KR20070107056 A KR 20070107056A KR 100900822 B1 KR100900822 B1 KR 100900822B1
- Authority
- KR
- South Korea
- Prior art keywords
- light source
- rendering
- image
- specific light
- independent component
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T15/00—3D [Three Dimensional] image rendering
- G06T15/50—Lighting effects
- G06T15/506—Illumination models
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T13/00—Animation
- G06T13/20—3D [Three Dimensional] animation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2213/00—Indexing scheme for animation
- G06T2213/08—Animation software package
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Graphics (AREA)
- Image Generation (AREA)
- Processing Or Creating Images (AREA)
Abstract
본 발명은 실시간 재조명 랜더링 방법 및 시스템에 관한 것으로, 보다 상세하게는 3D 컴퓨터 애니메이션 제작 과정에서 각 장면 또는 캐릭터의 조명 작업을 지원하는 소프트웨어 시스템으로서, 장면 내의 광원 변경에 따라 렌더링된 영상을 실시간으로 업데이트하여 작업자가 시각 효과의 변화를 쉽게 확인할 수 있도록 해 주는 실시간 재조명 랜더링 방법 및 시스템에 관한 것이다. 이를 위해 본 발명은 광원의 변화에 영향을 받지 않는 조명 독립적 성분을 미리 계산하여 저장하는 단계와; 상기 광원 중 특정한 광원을 선택하고, 애니메이션 소프트웨어를 이용하여 상기 선택한 광원을 수정하는 단계와; 광원별로 랜더링을 수행하는 단계와; 상기 랜더링된 영상을 합성하는 단계를 포함하는 것을 특징으로 하는 실시간 재조명 랜더링 방법을 제공한다.The present invention relates to a real-time re-illumination rendering method and system, and more particularly, to a software system that supports the lighting operation of each scene or character in the process of 3D computer animation production, and updates the rendered image in real time according to the change of the light source in the scene The present invention relates to a real-time re-illumination rendering method and system that allows an operator to easily check the change of visual effects. To this end, the present invention includes the steps of calculating and storing an illumination independent component which is not affected by changes in the light source; Selecting a specific light source among the light sources and modifying the selected light source using animation software; Performing rendering for each light source; It provides a real-time re-illumination rendering method comprising the step of synthesizing the rendered image.
재조명(relighting), 캐쉬화, 광원, 3D 애니메이션. Relighting, caching, lighting, 3D animation.
Description
본 발명은 실시간 재조명 랜더링 방법 및 시스템에 관한 것으로, 보다 상세하게는 3D 컴퓨터 애니메이션 제작 과정에서 각 장면 또는 캐릭터의 조명 작업을 지원하는 소프트웨어 시스템으로서, 장면 내의 광원 변경에 따라 렌더링된 영상을 실시간으로 업데이트하여 작업자가 시각 효과의 변화를 쉽게 확인할 수 있도록 해 주는 실시간 재조명 랜더링 방법 및 시스템에 관한 것이다.The present invention relates to a real-time re-illumination rendering method and system, and more particularly, to a software system that supports the lighting operation of each scene or character in the process of 3D computer animation production, and updates the rendered image in real time according to the change of the light source in the scene The present invention relates to a real-time re-illumination rendering method and system that allows an operator to easily check the change of visual effects.
본 발명은 정보통신부 및 정보통신연구진흥원의 IT신성장동력핵심기술개발사업의 일환으로 수행한 연구로부터 도출된 것이다[과제관리번호: 2006-S-045-01, 과제명: 기능 확장형 초고속 랜더러 개발].The present invention is derived from the research conducted as part of the IT new growth engine core technology development project of the Ministry of Information and Communication and the Ministry of Information and Communication Research and Development. .
조명 작업은 장면 내의 모든 기하학적 요소들과 표면 재질 등이 주어진 상황에서 광원의 배치와 방향, 세기, 색상 등을 적절히 결정하여 내용 전달을 극대화하기 위한 화면 분위기 연출을 하는 작업이다. 이 작업에서 조명은 전체 배경에 대한 것과 화면 내의 각 캐릭터에 제한된 조명 모두를 포함한다.The lighting work is to create a screen atmosphere to maximize content transfer by appropriately determining the arrangement, direction, intensity, and color of the light source in a given situation of all geometric elements and surface materials in the scene. In this work, lighting includes both the entire background and the lighting limited to each character in the scene.
화면의 전체 분위기는 광원들의 몇 가지 속성들을 약간만 수정하여도 큰 영 향을 받게 된다. 따라서, 광원 변화에 따른 화면의 시각적인 변화를 올바르게 확인하기 위해서는 정확한 피드백 방법이 필요하다. 기존의 애니메이션 소프트웨어에서는 작업 결과를 미리 확인할 수 있는 프리뷰 렌더링 기능을 제공하는데, 최종 렌더링보다는 빠르지만 실시간에는 못 미치고 영상 품질도 많이 떨어지는 문제가 있다. 이러한 문제는 조명 작업에 많은 시간과 비용을 낭비하는 결과를 초래하게 된다.The overall mood of the screen is greatly affected by some modifications to some of the properties of the light sources. Therefore, in order to correctly identify the visual change of the screen according to the light source change, an accurate feedback method is required. Existing animation software provides preview rendering function that can preview the work result, which is faster than the final rendering, but it is less than real time and the image quality is much lower. This problem is a waste of time and money for lighting work.
본 발명의 상기와 같은 문제점을 해결하여 애니메이션 제작자의 생산성 향상에 기여하는 도구를 제공하기 위한 것으로, 실시간으로 사용자가 조명 작업의 중간 결과를 보면서 광원 속성을 수정할 수 있도록 하는 편리한 인터페이스를 제공하는데 목적이 있다.It is an object of the present invention to provide a tool for contributing to the productivity improvement of animation makers by solving the above problems of the present invention, and to provide a convenient interface that allows the user to modify the light source properties while viewing the intermediate result of the lighting operation in real time. have.
상기 목적을 달성하기 위해, 본 발명은 광원의 변화에 영향을 받지 않는 조명 독립적 성분을 미리 계산하여 저장하는 단계와; 상기 광원 중 특정한 광원을 선택하고, 애니메이션 소프트웨어를 이용하여 상기 선택한 광원을 수정하는 단계와; 광원별로 랜더링을 수행하는 단계와; 상기 랜더링된 영상을 합성하는 단계를 포함하는 것을 특징으로 하는 실시간 재조명 랜더링 방법을 제공한다.In order to achieve the above object, the present invention comprises the steps of pre-calculating and storing an illumination independent component that is not affected by changes in the light source; Selecting a specific light source among the light sources and modifying the selected light source using animation software; Performing rendering for each light source; It provides a real-time re-illumination rendering method comprising the step of synthesizing the rendered image.
또한, 상기 목적을 달성하기 위해, 본 발명은 광원의 변화에 영향을 받지 않는 조명 독립적 성분을 계산하는 조명 독립적 성분 케쉬화 모듈; 상기 광원 중 선택된 특정한 광원을 수정하는 애니메이션 소프트웨어; 상기 광원별로 랜더링을 수행하는 광원별 랜더링 모듈; 및 상기 랜더링된 영상을 합성하는 영상 합성 모듈을 포함하되, 상기 랜더링은 선택된 광원 및 선택되지 않은 광원에 대하여 각각 독립적으로 수행되는 것을 특징으로 하는 실시간 재조명 랜더링 시스템을 제공한다.In addition, to achieve the above object, the present invention provides a lighting independent component cached module for calculating the lighting independent component is not affected by changes in the light source; Animation software to modify a particular light source selected from the light sources; A rendering module for each light source to perform rendering for each light source; And an image synthesizing module for synthesizing the rendered image, wherein the rendering is performed independently with respect to the selected light source and the unselected light source.
본 발명은 광원 변화에 의한 렌더링 결과의 갱신을 조명독립적 성분의 캐쉬화와 하드웨어 그래픽 가속기를 이용한 광원별 렌더링, 그리고 변화가 없는 광원들에 대한 렌더링 결과 재사용을 통해 실시간으로 재조명 렌더링을 구현하도록 하였다. 본 발명의 재조명 시스템 구현 방법은 기존 애니메이션 시스템의 소프트웨어 렌더러를 그대로 사용할 수 있기 때문에 기존 애니메이션 제작 파이프라인에 쉽게 통합되어 개발될 수 있다.The present invention is intended to implement re-illumination rendering in real time by updating the rendering result due to the change of the light source through caching of independent components, rendering by the light source using a hardware graphic accelerator, and reusing the rendering result for the unchanging light sources. The method for implementing the relighting system of the present invention can be easily integrated and developed into the existing animation production pipeline since the software renderer of the existing animation system can be used as it is.
본 발명은 실시간에 재조명 결과를 확인할 수 있도록 해 주기 때문에, 애니메이션 작업자가 불필요하게 중간 결과 확인을 위해 기다려야 하는 불편을 없애주어 제작 시간과 비용을 단축할 수 있다. 또한 실시간 피드백은 작업자의 심리적인 부담감을 없애주어 보다 창의적인 부분에 집중할 수 있도록 해주기 때문에 애니메이션 작품의 질 향상에도 기여할 수 있다.Since the present invention enables the re-lighting result to be confirmed in real time, the production time and cost can be reduced by eliminating the inconvenience that the animation worker has to wait for checking the intermediate result unnecessarily. In addition, real-time feedback can help improve the quality of animation work by eliminating the psychological burden on the worker so that they can focus on more creative parts.
본 발명에서 사용되는 용어는 가능한 한 현재 널리 사용되는 일반적인 용어를 선택하였으나, 특정한 경우는 출원인이 임의로 선정한 용어도 있으며, 이 경우는 해당되는 발명의 상세한 설명 부분에서 그 의미를 기재하였으므로, 단순한 용어의 명칭이 아닌 용어가 가지는 의미로서 본 발명을 파악하여야 한다.The terms used in the present invention are selected as general terms that are widely used at present, but in some cases, the term is arbitrarily selected by the applicant, in which case the meaning is described in the detailed description of the invention, The present invention should be understood as meanings of terms rather than names.
이하 상기의 목적을 구체적으로 실현할 수 있는 본 발명의 바람직한 실시예를 첨부한 도면을 참조하여 설명한다. 본 발명은 모든 미디어 신호를 포함하나, 설명의 편의상 이하에서 오디오 신호를 중심으로 기술된다.Hereinafter, with reference to the accompanying drawings, preferred embodiments of the present invention that can specifically realize the above object will be described. Although the present invention encompasses all media signals, the following description focuses on audio signals for convenience of description.
본 발명의 전체적인 구성은 도 1에 예시되어 있다. 사용자는 애니메이션 시스템을 통해 광원의 수정을 하게 된다(응용 시스템부, 10). 사용자가 조명 작업을 시작하면 조명독립적 성분값의 캐쉬화 모듈이 수행되어 현재 장면에 대해 필요한 성분값들을 계산하여 영상 파일 형태로 디스크에 저장한다. 다음 사용자가 광원들 중 하나의 속성이나 위치, 방향 등을 수정하면 광원별 렌더링 모듈이 실행되어 개별 광원에 의한 렌더링 결과가 계산된다 (재조명 처리부, 20). 광원별로 렌더링된 영상들은 영상합성 모듈로 보내져서 하나의 영상으로 합쳐지게 되고, 최종적으로 영상 출력 장치(영상 출력 모듈)로 보내져서 화면에 출력된다 (결과 출력부, 30).The overall configuration of the present invention is illustrated in FIG. The user modifies the light source through the animation system (application system unit 10). When the user starts the lighting operation, the caching module of the lighting independent component values is performed to calculate necessary component values for the current scene and to store them on the disk in the form of an image file. Next, when the user modifies the property, position, or direction of one of the light sources, the rendering module for each light source is executed to calculate the rendering result by the individual light sources (relighting processor 20). Images rendered for each light source are sent to the image synthesis module to be combined into one image, and finally, the image is output to the image output device (image output module) and output to the screen (result output unit 30).
애니메이션 소프트웨어(애니메이션 모듈)는 사용자가 장면 데이터를 읽어 들이고, 애니메이션을 구성하는 여러 가지 요소들, 즉 등장 캐릭터, 배경, 광원 등을 모델링하고 시간에 따라 움직임을 지정해 주고 최종적으로 렌더링까지 해 주는 소프트웨어이다. 이 소프트웨어는 일반적으로 많이 사용되는 상용 애니메이션 소프트웨어가 가능하다. 본 발명에서 애니메이션 소프트웨어는 사용자가 광원을 배치하고 방향을 정하고 광원의 세기, 색상 등의 속성을 수정하는 인터페이스를 제공하고, 조명독립적 성분값의 캐쉬를 생성하는데 사용된다.The animation software (animation module) is software that allows the user to read scene data, model various elements of the animation, such as characters, backgrounds, and light sources, specify movement over time, and even render finally. . This software is commonly available commercially available animation software. In the present invention, the animation software provides an interface for the user to position and orient the light source, modify the properties of the light source's intensity, color, and the like, and to generate a cache of lighting independent component values.
조명독립적 성분값 캐쉬화 모듈은 영상의 각 픽셀 색상을 계산하는 식에서 광원 변화에 영향을 받지 않는 성분을 미리 계산하여 영상 파일 형태로 하드디스크 및 컴퓨터 메모리 상의 텍스쳐(texture) 객체로 저장한다. 3D 렌더링에서 각 픽셀 색상을 계산하는 식은 쉐이딩 (shading) 모델에 따라 결정된다. 보편적으로 많이 사용되는 쉐이딩 모델은 Lambert, Phong, Blinn 등으로 장면 내의 객체들이 가지는 재질에 따라 선택적으로 사용된다. 이 세 가지 모델들을 가지고 조명독립적 성분들을 예시하겠다.The lighting independent component value caching module calculates a component which is not affected by the light source change in the formula of calculating the color of each pixel of the image and stores it as a texture object on the hard disk and the computer memory in the form of an image file. The equation for calculating each pixel color in 3D rendering is determined by the shading model. Commonly used shading models are Lambert, Phong, Blinn, and so on, depending on the materials of objects in the scene. With these three models, we will illustrate lighting independent components.
Lambert 모델은 광택이 없는 표면을 나타내는 모델로 광택이나 하이라이트가 없다. 가장 기본적인 쉐이딩 모델로 다른 모델에서도 Lambert의 속성을 기본적으로 포함하고 있다. 상기 Lambert 모델을 아래의 [수학식 1]과 같이 표현된다.The Lambert model represents a matte surface with no gloss or highlights. It is the most basic shading model, and other models include Lambert's properties by default. The Lambert model is expressed as
여기서, 은 픽셀의 색상이고, 는 객체 표면이 가지는 색상, 는 주변광의 색상, 는 물체 표면에서 산란되는 빛의 색상, 은 현재 픽셀에 투영되는 물체 표면 점에서의 수직 벡터, 은 물체 표면 점에서 광원으로 향하는 벡터, 그리고 는 광원으로부터 오는 빛의 세기이다. 여기서, 과 를 제외한 나머지 성분들은 광원 변화에 관계없이 일정한 값을 갖기 때문에 조명독립적 성분이 된다.here, Is the color of the pixel, Is the color of the object's surface, Is the color of the ambient light, Is the color of light scattered from the surface of the object, Is the vertical vector at the object surface point projected on the current pixel, Is the vector from the object surface point to the light source, and Is the intensity of light coming from the light source. here, and The other components except for become constant values independently because they have a constant value regardless of light source change.
Phong 모델은 유리 혹은 유리질의 표면(ex: 차, 전화기, 목욕탕 내부시설 등)의 강렬한 광택과 하이라이트를 표현 할 때 유용하게 사용되는 모델이다. 상기 Phong 모델은 아래의 [수학식 2]와 같이 표현된다.The Phong model is useful for expressing the intense gloss and highlights of glass or glass surfaces (ex: cars, phones, bathroom interiors, etc.). The Phong model is represented by Equation 2 below.
상기 식을 보면 Lambert 모델의 식이 포함되어 있는 것을 알 수 있다. 따라서 Lambert 모델의 조명독립적 성분은 Phong 모델에서도 그대로 적용된다. 추가로 나오는 항에서 는 빛이 전반사될 때의 표면 색상, 는 현재 픽셀에 투영되는 물체 표면점에서 카메라로 향하는 벡터, specularity는 물체 표면에서 하이라이트가 퍼지는 정도 또는 난반사율, 그리고 은 광원으로부터 온 빛이 물체 표면점에서 반사되어 나가는 방향이 된다. 여기서 와 , specularity는 광원의 변화에 영향을 받지 않는 성분들이다. 반면에 은 광원으로부터 오는 빛의 방향이 바뀌면 따라서 바뀌기 때문에 조명독립적이라고 할 수 없다.Looking at the above equation it can be seen that the expression of the Lambert model is included. Therefore, the light-independent component of Lambert model is also applied to Phong model. In the additional paragraph Is the color of the surface when light is totally reflected Is the vector from the object surface point projected on the current pixel to the camera, specularity is the extent to which the highlight spreads or diffuse reflectivity from the object surface, and Is the direction in which light from the light source is reflected at the object surface point. here Wow However, specularity is the component that is not affected by the change of light source. On the other hand It is not lighting independent because it changes as the direction of light coming from the light source changes.
Blinn 모델은 금속 표면(구리나 알루미늄 등)을 나타낼 때 유용한 재질로 주로 부드러운 광택과 하이라이트를 가진다. 상기 Blinn 모델은 아래의 [수학식 3]과 같이 표현된다.The Blinn model is a useful material for representing metal surfaces (such as copper and aluminum) and has a soft luster and highlights. The Blinn model is expressed by Equation 3 below.
Phong 모델과 마찬가지로 주변광과 산란광에 대한 항은 Lambert 모델에서 그대로 가져온반면, 전반사항은 Phong 모델과 다르다. 함수 D()는 물체 표면 위를 구성하는 미세면(micro facet)의 방향 분포 함수이다. 함수 G()는 기하학적 감쇄 인자로 미세면이 서로 간에 빛을 가리는 정도를 나타낸다. 함수 는 Fresnel 반사율로 입사광의 방향과 표면 재질의 특성에 따라 결정되는 함수이다. 본 발명에서는 D(), G(), 의 값이 광원에 의존적이므로 캐쉬화하지 않고 렌더링 시에 계산하도록 하였는데, D()와 에서 내부적으로 이심률(eccentricity)와 롤오프(roll-off)값을 계산에 사용하고 있다. 따라서, Blinn 모델에서 캐쉬화할 광원독립적 성분들은 , , 이심률, 롤오프 값들을 선택한다. 구현에 따라 D(), G(), 의 계산식에서 광원 독립적인 부분의 계산값을 추가로 캐쉬화할 수도 있지만, 이 경우 캐쉬 저장 공간이 더 많이 필요하게 된다.As with the Phong model, the terms for ambient and scattered light are taken directly from the Lambert model, while the overall picture is different from the Phong model. The function D () is a direction distribution function of the micro facet constituting the object surface. The function G () is a geometric attenuation factor that represents the extent to which the microsurfaces cover each other. function Is a Fresnel reflectance that is determined by the direction of incident light and the characteristics of the surface material. In the present invention, D (), G (), Since the value of is dependent on the light source, we calculated it at rendering time without caching. Internally, eccentricity and roll-off are used in the calculations. Thus, the light-independent components to cache in the Blinn model , Select the eccentricity, rolloff values. Depending on the implementation, D (), G (), Although the calculation of the light-independent part of the equation can be further cached, this requires more cache storage space.
이렇게 하여 필요한 캐쉬 종류를 모두 모우면 물체 표면 색상(), 쉐이더 모델 종류, 주변광에 대한 표면 색상(), 산란광에 대한 표면 색상(), 전반사광에 대한 표면 색상(), 표면의 법선벡터(), 픽셀의 깊이값, 그리고 난반사율(specularity), 이심률, 롤오프 값들을 하나로 묶은 전반사속성값으로 여덟 가지가 된다. 도2에서는 예제 장면에 대해 계산한 캐쉬값들을 이미지 형태로 예시하고 있다.This way, once you've collected all the cache types you need, the object surface color ( ), Shader model type, surface color for ambient light ( ), The surface color for scattered light ( ), The surface color for total reflection ), The normal vector of the surface ( ), Total depth attribute of the pixel, and specularity , eccentricity, and rolloff values. 2 illustrates cache values calculated for the example scene in the form of an image.
조명 독립적 성분값들을 미리 계산하여 캐쉬화하는 과정은 하드웨어 렌더러 또는 소프트웨어 렌더러를 사용할 수 있다. 하드웨어 렌더러를 사용할 경우 매우 빠르게 계산 결과를 얻을 수 있지만, 정교한 샘플링 기법을 사용할 수 없기 때문에 계산 결과가 깨끗하지 못하고 표면 텍스쳐에서 시각적인 앨리아싱 결함이 나타날 수 있다. 소프트웨어 렌더러를 이용할 경우 계산 시간이 비교적 많이 걸리지만, 앨리아싱 결함은 훨씬 줄일 수 있다. 본 발명에서는 캐쉬 생성에 걸리는 시간보다는 캐쉬값의 정확성이 더욱 중요하기 때문에 소프트웨어 렌더러를 선택하였다.The process of calculating and caching lighting independent component values in advance may use a hardware renderer or a software renderer. Using a hardware renderer yields very fast calculations, but because sophisticated sampling techniques are not available, the calculations are not clean and visual aliasing defects can appear on surface textures. Using a software renderer takes relatively long computations, but can reduce aliasing defects even more. In the present invention, the software renderer is selected because the accuracy of the cache value is more important than the time required to generate the cache.
본 발명에서 소프트웨어 렌더러를 이용한 조명 독립적 성분값을 계산은 주변광 렌더링(ambient rendering)을 이용하였다. 이 것은 장면 내의 모든 광원을 끄고 주변광만을 밝기 1(기준값)로 설정하여 렌더링을 하는 것이다. 이렇게 하면 상기 쉐이딩 모델식을 보면 알 수 있듯이 인 결과를 얻게 된다. 만일 로 설정하면, 렌더링 결과는 주변광에 의한 표면 색상()만이 얻어지게 된다. 따라서, 우리가 얻고자 하는 성분값을 로 연결하고 주변광 렌더링을 수행하면 렌더링된 영상의 각 픽셀에는 투영된 3D 표면점의 성분값이 저장되게 된다. 주변광 렌더링을 이용하는 이유는 기존 소프트웨어 렌더러를 수정없이 쓸 수 있도록 하기 위함이고, 결과적으로 본 발명은 어떤 소프트웨어 렌더러든지 사용할 수 있게 된다.In the present invention, the calculation of the lighting independent component value using the software renderer used ambient rendering. This is done by turning off all light sources in the scene and setting only ambient light to brightness 1 (reference value). This way, as you can see from the shading model Results in if When set to, the rendering result is the color of the surface due to ) Is obtained. Therefore, we want to get the component value When the ambient light is rendered and each pixel of the rendered image is stored, the component values of the projected 3D surface points are stored. The reason for using ambient light rendering is to allow the existing software renderer to be used without modification, and as a result, the present invention can use any software renderer.
이 알고리즘을 간단히 유사코드(pseudocode)로 쓰면 다음과 같다. 1)장면 내의 모든 광원을 끈다. 2)밝기 1.0을 가지는 주변광을 활성화한다. 3)모든 표면 재 질의 속성을 임시 저장 공간에 백업한다. 4)캐쉬화할 각 조명독립적 성분들에 대해 차례로 각 표면 재질의 속성으로 연결한다. 5)장면을 렌더링하여 결과를 파일에 저장한다. 6)원래의 값을 회복시킨다. 7)원래 장면 내의 광원들을 켠다.Using this algorithm simply as pseudocode: 1) Turn off all light sources in the scene. 2) Activate the ambient light with brightness 1.0. 3) all surface quality Back up attributes to temporary storage. 4) each surface material in turn for each lighting independent component to be cached. Link to an attribute. 5) Render the scene and save the result to a file. 6) Original Restore the value. 7) Turn on the lights in the original scene.
다음 광원별 렌더링 모듈은 각 광원이 영상에 기여하는 정도를 계산하는 것으로, 사실상 각 광원만을 켠 채로 렌더링하는 것과 같다. 본 발명에서는 상기 조명독립적 성분값 캐쉬화 모듈에서 계산하여 저장한 캐쉬 이미지들과 하드웨어 그래픽 가속기의 단편 쉐이더(fragment shader) 프로그램을 이용하여 광원별 렌더링 모듈을 구현한다. 단편 쉐이더는 화면에 그려질 각 픽셀의 컬러를 결정하는 계산을 행하는 하드웨어 유닛이고, 단편 쉐이더 프로그램은 계산 과정을 프로그래밍한 것이다.Next, the rendering module for each light source calculates the degree to which each light source contributes to the image, which is actually like rendering each light source on. The present invention implements a rendering module for each light source by using cache images calculated and stored in the lighting independent component value caching module and a fragment shader program of a hardware graphics accelerator. A fragment shader is a hardware unit that performs calculations that determine the color of each pixel to be drawn on the screen, and a fragment shader program is programmed for the computation process.
본 발명의 광원별 렌더링 모듈은 OpenGL API를 이용하여 다음과 같이 구현된다. 먼저 앞서 계산된 조명독립적 성분값을 저장하는 이미지들을 읽어서 각각 하나의 텍스쳐 객체로 만든다. OpenGL의 누적 버퍼(accumulation buffer)를 초기화한다. 다음 각 광원에 대해 OpenGL의 컬러 버퍼(color buffer)를 초기화하고 현재 광원 종류에 맞는 단편 쉐이더 프로그램을 OpenGL에서 바인딩한다. 현재 광원의 속성을 단편 쉐이더에 인수(arguments)로 넘겨준다. 이어서 전체 이미지를 완전히 채우는 직사각형을 그리고, 그 결과를 누적 버퍼에 누적시킨다. 다음 광원에 대한 렌더링을 수행한다.The light source-specific rendering module of the present invention is implemented as follows using the OpenGL API. First, the images that store the lighting-independent component values calculated above are read into each texture object. Initialize the OpenGL accumulation buffer. Next, we initialize OpenGL's color buffer for each light source and bind OpenGL a fragment shader program for the current light type. Pass the properties of the current light source as arguments to the fragment shader. We then draw a rectangle that completely fills the entire image and accumulate the result in a cumulative buffer. Perform rendering for the next light source.
본 발명의 광원별 렌더링을 위한 단편 쉐이더 프로그램의 유사코드는 공통적으로 다음과 같다. 1)텍스쳐로부터 조명독립적 성분값들을 읽어들인다. 2)역 카메라 투영을 통해 현재 픽셀의 깊이값으로부터 3D 위치를 구해낸다. 3)광원 방향 과 광원의 세기 을 구한다. 4)현재 픽셀의 쉐이딩 모델식을 계산한다. 5)계산 결과를 출력한다. 상기에서 광원 종류에 따라 달라지는 부분은 단계 3이다. 단방향(directional) 광원, 점(point)광원, 스팟(spot) 광원에 따라 광원 방향과 광원 세기를 구하는 것이 달라진다.The pseudo code of the fragment shader program for rendering for each light source of the present invention is as follows. 1) Read the lighting independent component values from the texture. 2) The 3D position is obtained from the depth value of the current pixel through the reverse camera projection. 3) light source direction And the intensity of the light source Obtain 4) Calculate the shading model formula of the current pixel. 5) Output the calculation result. The part which depends on the kind of light source in the above is step 3. The direction of the light source and the intensity of the light source vary depending on the directional light source, the point light source, and the spot light source.
도 3은 본 발명의 일실시예에 따른 재조명 렌더링을 할 때, 광원별로 렌더링한 결과를 합성하는 과정을 보여주는 예시도이다. 도 3을 참조하면, 본 발명에서는 각 광원별로 렌더링된 이미지들을 차례로 누적 버퍼에 더하여 최종 이미지를 완성한다. 그런데, 일반적으로 상업용 애니메이션의 한 장면에서 사용되는 광원의 수는 수 십개에서 수 백개에 이르기 때문에 그 만큼의 광원별 렌더링을 매 번 반복해야 한다. 이 정도의 계산량은 하드웨어 그래픽 가속기의 성능에 따라 다르지만 실시간에 끝내지 못할 수도 있다. 이러한 성능 저하를 해결하기 위한 방법으로 본 발명에서는 사용자가 수정하기 위해 선택한 광원에 대해서만 렌더링을 하는 방법을 사용한다.3 is an exemplary view showing a process of synthesizing a result of rendering for each light source when re-illumination rendering according to an embodiment of the present invention. Referring to FIG. 3, the present invention completes the final image by sequentially adding images rendered for each light source to the accumulation buffer. However, in general, the number of light sources used in a scene of a commercial animation ranges from tens to hundreds, so it is necessary to repeat the rendering for each light source as many times. This amount of computation depends on the performance of the hardware graphics accelerator, but may not be complete in real time. As a method for solving such a performance degradation, the present invention uses a method of rendering only a light source selected by a user to be corrected.
처음 사용자가 광원을 선택하면 먼저 선택되지 않은 광원들에 대해서만 광원별 렌더링을 하여 그 결과를 누적 버퍼에 누적시킨다. 이렇게 얻어진 결과는 별도의 예비 버퍼(auxiliary buffer)로 옮겨 계속 유지시킨다. 이 후에 사용자가 광원 을 수정할 때마다, 예비 버퍼의 영상을 누적 버퍼에 복사하고, 다음으로 수정된 광원에 대해서만 렌더링을 하여 누적 버퍼에 누적시킨다. 이렇게 얻어진 결과는 모든 광원에 대해 렌더링하여 얻어진 결과와 같다. 반면에 렌더링 시간은 처음 광원 선택 시점을 제외하고는 전체 광원 수에는 상관없이 하나의 광원에 대한 렌더링 시간만큼만 평균적으로 소요되게 된다.When the user selects a light source for the first time, only light sources that are not selected are rendered for each light source, and the result is accumulated in the accumulation buffer. The result thus obtained is transferred to a separate auxiliary buffer and kept there. After this, whenever the user modifies the light source, the preliminary buffer image is copied to the cumulative buffer, and then only the modified light source is rendered and accumulated in the cumulative buffer. The result thus obtained is the same as the result obtained by rendering for all light sources. On the other hand, the rendering time is averaged only as long as the rendering time for one light source regardless of the total number of light sources except for the first light source selection time.
도 4는 본 발명의 일실시예에 따른 실시간 재조명 랜더링 방법을 나타내는 흐름도이다. 도 4를 참조하면, 먼저 조명독립적 성분값 캐쉬화 모듈은 광원 변화에 영향을 받지 않는 성분을 저장한다(S401). 그 다음에, 사용자는 수정할 광원을 선택하고, 애니메이션 소프트웨어를 이용하여 선택한 광원을 수정한다(S402). 그 다음에, 광원별 랜더링 모듈은 광원별로 랜더링을 수행하는데, 만일 사용자가 선택하지 않은 광원이라면(S403), 즉, 변화가 없는 광원들에 대해서는 렌더링 결과를 재사용하여 누적한다(S404). 누적된 결과는 예비 버퍼에 저장되고(S405), 광원을 수정할 때마다 예비 버퍼의 영상을 누적 버퍼에 복사한다. 만일, 사용자가 선택한 광원이라면(S403), 광원별로 랜더링을 수행(S406)한 후에 누적 버퍼에 누적한다(S407).4 is a flowchart illustrating a real-time relighting rendering method according to an embodiment of the present invention. Referring to FIG. 4, the lighting independent component value caching module first stores components that are not affected by the change in the light source (S401). Next, the user selects a light source to be modified, and modifies the selected light source using animation software (S402). Next, the rendering module for each light source performs rendering for each light source. If the light source is not selected by the user (S403), that is, the rendering results are accumulated and reused for light sources that do not change (S404). The accumulated result is stored in the preliminary buffer (S405), and the image of the preliminary buffer is copied into the preliminary buffer every time the light source is modified. If it is the light source selected by the user (S403), the rendering is performed for each light source (S406) and then accumulated in the accumulation buffer (S407).
지금까지 본 발명에 대하여 몇몇 실시예들을 들어 구체적으로 설명하였으나, 상기 실시예들은 본 발명을 이해하기 위한 설명을 위해 제시된 것이며, 본 발명의 범위가 상기 실시예에 제한되는 것은 아니다. 당업자라면 본 발명의 기술적 사상의 범위를 벗어나지 않고도 다양한 변형이 가능함을 이해할 수 있을 것이며, 본 발명의 범위는 첨부된 특허청구범위에 의해서 해석되어야 할 것이다.Although the present invention has been described in detail with reference to some embodiments, the above embodiments are presented for the purpose of understanding the present invention, and the scope of the present invention is not limited to the above embodiments. Those skilled in the art will understand that various modifications are possible without departing from the scope of the technical idea of the present invention, and the scope of the present invention should be interpreted by the appended claims.
도 1은 본 발명의 일실시예에 따른 소프트웨어 시스템의 구성 예시도.1 is an exemplary configuration of a software system according to an embodiment of the present invention.
도 2는 본 발명의 일실시예에 따른 재조명 렌더링을 할 때, 주어진 3D 장면에 대한 조명독립적 성분값을 캐쉬 이미지로 만든 예를 보여주는 예시도.2 is an exemplary view showing an example in which a light-independent component value for a given 3D scene is generated as a cache image when re-rendering a rendering according to an embodiment of the present invention.
도 3은 본 발명의 일실시예에 따른 재조명 렌더링을 할 때, 광원별로 렌더링한 결과를 합성하는 과정을 보여주는 예시도.3 is an exemplary view showing a process of synthesizing a result of rendering for each light source when re-illumination rendering according to an embodiment of the present invention.
도 4는 본 발명의 일실시예에 따른 실시간 재조명 랜더링 방법을 나타내는 흐름도.4 is a flowchart illustrating a real-time relighting rendering method according to an embodiment of the present invention.
*도면의 주요 부분에 대한 부호의 설명** Description of the symbols for the main parts of the drawings *
10: 응용 시스템부10: Application system part
20: 재조명 처리부20: relight processing unit
30: 결과 출력부30: result output
Claims (8)
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR20060121092 | 2006-12-02 | ||
KR1020060121092 | 2006-12-02 |
Publications (2)
Publication Number | Publication Date |
---|---|
KR20080050303A KR20080050303A (en) | 2008-06-05 |
KR100900822B1 true KR100900822B1 (en) | 2009-06-04 |
Family
ID=39805791
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020070107056A KR100900822B1 (en) | 2006-12-02 | 2007-10-24 | System and method for real-time relighting system |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR100900822B1 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR102077146B1 (en) * | 2016-03-15 | 2020-02-13 | (주)넥셀 | Method and apparatus for processing graphics |
CN110033055A (en) * | 2019-04-19 | 2019-07-19 | 中共中央办公厅电子科技学院(北京电子科技学院) | A kind of complex object image weight illumination method based on the parsing of semantic and material with synthesis |
KR102558643B1 (en) * | 2020-10-26 | 2023-07-24 | 서울과학기술대학교 산학협력단 | Image conversion apparatus and method thereof |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH06301796A (en) * | 1993-04-19 | 1994-10-28 | Matsushita Electric Ind Co Ltd | Method and device for three-dimensional image generation |
JPH08287295A (en) * | 1995-04-19 | 1996-11-01 | Matsushita Electric Ind Co Ltd | Device and method for graphic processing |
US6016149A (en) | 1997-06-30 | 2000-01-18 | Sun Microsystems, Inc. | Lighting unit for a three-dimensional graphics accelerator with improved processing of multiple light sources |
JP2002117413A (en) | 2000-10-10 | 2002-04-19 | Univ Tokyo | Image generating device and image generating method for reflecting light source environmental change in real time |
-
2007
- 2007-10-24 KR KR1020070107056A patent/KR100900822B1/en not_active IP Right Cessation
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH06301796A (en) * | 1993-04-19 | 1994-10-28 | Matsushita Electric Ind Co Ltd | Method and device for three-dimensional image generation |
JPH08287295A (en) * | 1995-04-19 | 1996-11-01 | Matsushita Electric Ind Co Ltd | Device and method for graphic processing |
US6016149A (en) | 1997-06-30 | 2000-01-18 | Sun Microsystems, Inc. | Lighting unit for a three-dimensional graphics accelerator with improved processing of multiple light sources |
JP2002117413A (en) | 2000-10-10 | 2002-04-19 | Univ Tokyo | Image generating device and image generating method for reflecting light source environmental change in real time |
Also Published As
Publication number | Publication date |
---|---|
KR20080050303A (en) | 2008-06-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4945642B2 (en) | Method and system for color correction of 3D image | |
CA2810865C (en) | Streaming light propagation | |
US8217940B2 (en) | Directable lighting method and apparatus | |
US7652666B2 (en) | Hybrid hardware-accelerated relighting system for computer cinematography | |
JP4542153B2 (en) | Flexible anti-aliasing for embedded devices | |
US7583264B2 (en) | Apparatus and program for image generation | |
US20110234587A1 (en) | Method and system for rendering or interactive lighting of a complex three dimensional scene | |
US20170323471A1 (en) | 3D rendering method and 3D graphics processing device | |
JP5731566B2 (en) | Information processing apparatus, control method, and recording medium | |
Knecht et al. | Reciprocal shading for mixed reality | |
US20100265250A1 (en) | Method and system for fast rendering of a three dimensional scene | |
US9183654B2 (en) | Live editing and integrated control of image-based lighting of 3D models | |
US9019268B1 (en) | Modification of a three-dimensional (3D) object data model based on a comparison of images and statistical information | |
KR100900822B1 (en) | System and method for real-time relighting system | |
Pessoa et al. | RPR-SORS: Real-time photorealistic rendering of synthetic objects into real scenes | |
US8942476B1 (en) | Saturation varying and lighting independent color color control for computer graphics | |
Madsen et al. | Real-time image-based lighting for outdoor augmented reality under dynamically changing illumination conditions | |
Happa et al. | Studying illumination and cultural heritage | |
Pessoa et al. | Illumination techniques for photorealistic rendering in augmented reality | |
Dal Corso et al. | Interactive directional subsurface scattering and transport of emergent light | |
Schwandt | High-Quality Illumination of Virtual Objects Based on an Environment Estimation in Mixed Reality Applications | |
Moura et al. | RPR-SORS: an authoring toolkit for photorealistic AR | |
Rosu et al. | EasyPBR: A lightweight physically-based renderer | |
Lindsay | Programmable Image-Based Light Capture for Previsualization | |
DiVerdi et al. | Combining dynamic physical and virtual illumination in augmented reality |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A201 | Request for examination | ||
E902 | Notification of reason for refusal | ||
E701 | Decision to grant or registration of patent right | ||
GRNT | Written decision to grant | ||
LAPS | Lapse due to unpaid annual fee |