CN116402878A - Light field image processing method and device - Google Patents
Light field image processing method and device Download PDFInfo
- Publication number
- CN116402878A CN116402878A CN202310410075.6A CN202310410075A CN116402878A CN 116402878 A CN116402878 A CN 116402878A CN 202310410075 A CN202310410075 A CN 202310410075A CN 116402878 A CN116402878 A CN 116402878A
- Authority
- CN
- China
- Prior art keywords
- image
- light field
- foreground
- viewpoint
- background
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/50—Depth or shape recovery
- G06T7/55—Depth or shape recovery from multiple images
- G06T7/557—Depth or shape recovery from multiple images from light fields, e.g. from plenoptic cameras
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/50—Image enhancement or restoration using two or more images, e.g. averaging or subtraction
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/194—Segmentation; Edge detection involving foreground-background segmentation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/70—Determining position or orientation of objects or cameras
- G06T7/73—Determining position or orientation of objects or cameras using feature-based methods
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/10—Image acquisition modality
- G06T2207/10052—Images from lightfield camera
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20212—Image combination
- G06T2207/20221—Image fusion; Image merging
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20228—Disparity calculation for image-based rendering
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Studio Devices (AREA)
Abstract
Description
技术领域technical field
本公开涉及图像处理技术领域,具体涉及一种光场图像处理方法及装置。The present disclosure relates to the technical field of image processing, and in particular to a light field image processing method and device.
背景技术Background technique
光场(Light Field)可以记录更高维度的光线数据,从而获得比传统二维成像及以双目立体视觉为代表的传统三维成像更高精度的三维信息,光场视频可以准确感知动态环境,使得用户感受到身临其境的观看体验。Light Field (Light Field) can record higher-dimensional light data, so as to obtain higher-precision 3D information than traditional 2D imaging and traditional 3D imaging represented by binocular stereo vision. Light field video can accurately perceive dynamic environments, Make users experience an immersive viewing experience.
但是,光场视频的数据量大、处理速度慢,难以实现实时性的光场视频呈现,导致光场视频的应用场景受限。However, light field video has a large amount of data and slow processing speed, and it is difficult to realize real-time light field video presentation, which limits the application scenarios of light field video.
发明内容Contents of the invention
为提高光场图像的数据处理效率,从而实现实时性的光场视频呈现,本公开实施方式提供了一种光场图像处理方法、装置、电子设备、视频通信系统以及存储介质。In order to improve the data processing efficiency of light field images and realize real-time light field video presentation, embodiments of the present disclosure provide a light field image processing method, device, electronic equipment, video communication system, and storage medium.
第一方面,本公开实施方式提供了一种光场图像处理方法,应用于显示设备,所述方法包括:In a first aspect, an embodiment of the present disclosure provides a light field image processing method, which is applied to a display device, and the method includes:
获取目标视点信息以及由采集设备发送的光场图像组;所述目标视点信息表示所述显示设备的观察者眼睛的位置信息,所述光场图像组包括所述采集设备中每个目标光场相机所采集的光场图像;Obtain target viewpoint information and a light field image group sent by the acquisition device; the target viewpoint information represents the position information of the observer's eyes of the display device, and the light field image group includes each target light field in the acquisition device The light field image collected by the camera;
基于所述目标视点信息对各个光场图像中的前景图像进行视点融合,得到所述目标视点信息所对应的前景视点图像;performing viewpoint fusion on foreground images in each light field image based on the target viewpoint information, to obtain foreground viewpoint images corresponding to the target viewpoint information;
基于所述目标视点信息以及预先生成的每个视点位置的背景视差图,对各个光场图像中的背景图像进行视点融合,得到所述目标视点信息所对应的背景视点图像;所述视点位置表示与每个目标光场相机相对应的位置;Based on the target viewpoint information and the pre-generated background disparity map of each viewpoint position, perform viewpoint fusion on the background images in each light field image to obtain the background viewpoint image corresponding to the target viewpoint information; the viewpoint position represents A location corresponding to each target light field camera;
根据所述前景视点图像和所述背景视点图像生成目标光场图像。A target light field image is generated according to the foreground viewpoint image and the background viewpoint image.
在一些实施方式中,所述基于所述目标视点信息对各个光场图像中的前景图像进行视点融合,得到所述目标视点信息所对应的前景视点图像,包括:In some implementation manners, performing viewpoint fusion on the foreground images in each light field image based on the target viewpoint information to obtain the foreground viewpoint image corresponding to the target viewpoint information includes:
对所述光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像;performing image segmentation on each light field image in the light field image group to obtain a foreground image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,对所述第一光场图像对应的第一前景图像以及所述第二光场图像对应的第二前景图像进行视差估计,得到所述第一前景图像对应的第一前景视差图以及第二前景图像对应的所述第二前景视差图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, the first foreground image corresponding to the first light field image and the first foreground image corresponding to the second light field image Performing disparity estimation on the second foreground image to obtain a first foreground disparity map corresponding to the first foreground image and a second foreground disparity map corresponding to the second foreground image;
基于第一前景视差图对所述第一前景图像进行视差映射得到第一前景映射图,基于第二前景视差图对所述第二前景图像进行视差映射得到第二前景映射图;performing parallax mapping on the first foreground image based on the first foreground disparity map to obtain a first foreground map, and performing parallax mapping on the second foreground image based on the second foreground disparity map to obtain a second foreground map;
基于所述目标视点信息对所述第一前景映射图和所述第二前景映射图进行图像融合处理,得到所述前景视点图像。performing image fusion processing on the first foreground map and the second foreground map based on the target viewpoint information to obtain the foreground viewpoint image.
在一些实施方式中,所述对所述光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像,包括:In some implementation manners, performing image segmentation on each light field image in the light field image group to obtain a foreground image corresponding to each light field image includes:
对于所述光场图像组中的每个光场图像,基于预先生成的与所述光场图像相同视点位置的预设背景图像,对所述光场图像进行图像差分,得到所述光场图像对应的前景图像和背景图像。For each light field image in the light field image group, based on a pre-generated preset background image at the same viewpoint position as the light field image, image difference is performed on the light field image to obtain the light field image Corresponding foreground and background images.
在一些实施方式中,所述对所述第一光场图像对应的第一前景图像以及所述第二光场图像对应的第二前景图像进行视差估计,得到所述第一前景图像对应的第一前景视差图以及第二前景图像对应的所述第二前景视差图,包括:In some embodiments, the parallax estimation is performed on the first foreground image corresponding to the first light field image and the second foreground image corresponding to the second light field image to obtain the first foreground image corresponding to the first foreground image A foreground disparity map and the second foreground disparity map corresponding to the second foreground image include:
基于预设降采样系数对所述第一前景图像进行降采样得到第一降采样图,对所述第二前景图像进行降采样得到第二降采样图;performing downsampling on the first foreground image based on a preset downsampling coefficient to obtain a first downsampling image, and performing downsampling on the second foreground image to obtain a second downsampling image;
对所述第一降采样图和所述第二降采样图上相同像素的位置进行匹配,得到第一降采样图对应的第一视差图,以及第二降采样图对应的第二视差图;matching the positions of the same pixels on the first downsampled image and the second downsampled image to obtain a first disparity map corresponding to the first downsampled image and a second disparity map corresponding to the second downsampled image;
根据所述第一视差图和所述预设降采样系数确定第一视差搜索范围,根据所述第二视差图和所述预设降采样系数确定第二视差搜索范围;determining a first disparity search range according to the first disparity map and the preset downsampling coefficient, and determining a second disparity search range according to the second disparity map and the preset downsampling coefficient;
基于所述第一视差搜索范围对所述第一前景图像进行视差估计得到所述第一前景视差图,基于所述第二视差搜索范围对所述第二前景图像进行视差估计得到所述第二前景视差图。Performing disparity estimation on the first foreground image based on the first disparity search range to obtain the first foreground disparity map, and performing disparity estimation on the second foreground image based on the second disparity search range to obtain the second foreground image Foreground disparity map.
在一些实施方式中,所述基于第一前景视差图对所述第一前景图像进行视差映射得到第一前景映射图,基于第二前景视差图对所述第二前景图像进行视差映射得到第二前景映射图,包括:In some implementations, the first foreground map is obtained by performing disparity mapping on the first foreground image based on the first foreground disparity map, and the second foreground image is obtained by performing disparity mapping on the second foreground disparity map. Foreground maps, including:
根据所述第一前景视差图将所述第一前景图像上的每个像素匹配至映射图上的对应像素位置,得到所述第一前景映射图;根据所述第二前景视差图将所述第二前景图像上的每个像素匹配至映射图上的对应像素位置,得到所述第二前景映射图;matching each pixel on the first foreground image to a corresponding pixel position on the map according to the first foreground disparity map to obtain the first foreground map; according to the second foreground disparity map matching each pixel on the second foreground image to a corresponding pixel position on the map to obtain the second foreground map;
所述基于所述目标视点信息对所述第一前景映射图和所述第二前景映射图进行图像融合处理,得到所述前景视点图像,包括:The performing image fusion processing on the first foreground map and the second foreground map based on the target viewpoint information to obtain the foreground viewpoint image includes:
根据所述目标视点信息与所述任意两个相邻的目标光场相机的位置信息,确定第一权值和第二权值;determining a first weight and a second weight according to the target viewpoint information and the position information of any two adjacent target light field cameras;
基于所述第一权值和所述第二权值,对所述第一前景映射图和所述第二前景映射图进行图像融合处理,得到所述前景视点图像。Based on the first weight and the second weight, image fusion processing is performed on the first foreground map and the second foreground map to obtain the foreground viewpoint image.
在一些实施方式中,所述基于所述目标视点信息以及预先生成的每个视点位置的背景视差图,对各个光场图像中的背景图像进行视点融合,得到所述目标视点信息所对应的背景视点图像;所述视点位置表示与每个目标光场相机相对应的位置,包括:In some embodiments, based on the target viewpoint information and the pre-generated background disparity map of each viewpoint position, viewpoint fusion is performed on the background images in each light field image to obtain the background corresponding to the target viewpoint information A viewpoint image; the viewpoint position represents a position corresponding to each target light field camera, including:
对所述光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的背景图像;performing image segmentation on each light field image in the light field image group to obtain a background image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,基于预先生成的与所述第一光场图像相同视点位置的第一背景视差图,对所述第一光场图像的第一背景图像进行视差映射得到第一背景映射图,基于预先生成的与所述第二光场图像相同视点位置的第二背景视差图,对所述第二光场图像的第二背景图像进行视差映射得到第二背景映射图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, based on the pre-generated first background disparity map at the same viewpoint position as the first light field image, the performing parallax mapping on the first background image of the first light field image to obtain a first background map, and based on the pre-generated second background parallax map at the same viewpoint position as the second light field image, performing parallax mapping on the second background image of the image to obtain a second background map;
基于所述目标视点信息对所述第一背景映射图和所述第二背景映射图进行图像融合处理,得到所述背景视点图像。performing image fusion processing on the first background map and the second background map based on the target viewpoint information to obtain the background viewpoint image.
在一些实施方式中,所述获取目标视点信息,包括:In some implementation manners, the acquiring target viewpoint information includes:
通过设于所述显示设备上的图像采集装置采集场景图像;collecting scene images through an image collection device arranged on the display device;
根据所述场景图像进行图像检测,得到场景图像中观察者眼睛的位置信息;performing image detection according to the scene image to obtain position information of the observer's eyes in the scene image;
基于所述位置信息生成所述目标视点信息。The target viewpoint information is generated based on the position information.
在一些实施方式中,获取由采集设备发送的光场图像组的过程,包括:In some implementations, the process of acquiring the light field image group sent by the acquisition device includes:
将所述目标视点信息发送至所述采集设备,以使所述采集设备根据所述目标视点信息从多个光场相机中确定一个或多个所述目标光场相机;sending the target viewpoint information to the acquisition device, so that the acquisition device determines one or more target light field cameras from a plurality of light field cameras according to the target viewpoint information;
接收所述采集设备发送的所述光场图像组。The light field image group sent by the acquisition device is received.
在一些实施方式中,本公开所述的光场图像处理方法,还包括:In some embodiments, the light field image processing method described in the present disclosure further includes:
接收所述采集设备发送的每个视点位置的背景视差图并存储。The background disparity map of each viewpoint position sent by the collection device is received and stored.
第二方面,本公开实施方式提供了一种光场图像处理方法,应用于采集设备,所述方法包括:In a second aspect, the embodiment of the present disclosure provides a light field image processing method, which is applied to a collection device, and the method includes:
通过设于所述采集设备上的多个光场相机分别采集当前场景图像,得到每个光场相机对应的视点位置的场景图像;Collecting the current scene image respectively by a plurality of light field cameras arranged on the collection device, to obtain the scene image of the viewpoint position corresponding to each light field camera;
对于任意相邻的两个光场相机,根据两个光场相机分别采集的场景图像,生成每个光场相机的视点位置的背景视差图;For any two adjacent light field cameras, according to the scene images collected by the two light field cameras respectively, a background disparity map of the viewpoint position of each light field camera is generated;
将每个视点位置的背景视差图发送至显示设备,以使所述显示设备存储每个视点位置的背景视差图。The background disparity map of each viewpoint position is sent to the display device, so that the display device stores the background disparity map of each viewpoint position.
在一些实施方式中,本公开所述的光场图像处理方法,还包括:In some embodiments, the light field image processing method described in the present disclosure further includes:
接收所述显示设备发送的目标视点信息;receiving target viewpoint information sent by the display device;
根据所述目标视点信息,从所述采集设备包括的多个光场相机中确定一个或多个目标光场相机;determining one or more target light field cameras from the plurality of light field cameras included in the acquisition device according to the target viewpoint information;
通过所述目标光场相机采集光场图像得到光场图像组,并将所述光场图像组发送至所述显示设备。Collecting light field images by the target light field camera to obtain a light field image group, and sending the light field image group to the display device.
第三方面,本公开实施方式提供了一种光场图像处理装置,应用于显示设备,所述装置包括:In a third aspect, an embodiment of the present disclosure provides a light field image processing device, which is applied to a display device, and the device includes:
获取模块,被配置为获取目标视点信息以及由采集设备发送的光场图像组;所述目标视点信息表示所述显示设备的观察者眼睛的位置信息,所述光场图像组包括所述采集设备中每个目标光场相机所采集的光场图像;An acquisition module configured to acquire target viewpoint information and a light field image group sent by the acquisition device; the target viewpoint information represents the position information of the observer's eyes of the display device, and the light field image group includes the acquisition device The light field image collected by each target light field camera in ;
前景融合模块,被配置为基于所述目标视点信息对各个光场图像中的前景图像进行视点融合,得到所述目标视点信息所对应的前景视点图像;The foreground fusion module is configured to perform viewpoint fusion on the foreground images in each light field image based on the target viewpoint information, to obtain the foreground viewpoint image corresponding to the target viewpoint information;
背景融合模块,被配置为基于所述目标视点信息以及预先生成的每个视点位置的背景视差图,对各个光场图像中的背景图像进行视点融合,得到所述目标视点信息所对应的背景视点图像;所述视点位置表示与每个目标光场相机相对应的位置;The background fusion module is configured to perform viewpoint fusion on the background images in each light field image based on the target viewpoint information and the pre-generated background disparity map of each viewpoint position, to obtain the background viewpoint corresponding to the target viewpoint information image; the viewpoint position represents a position corresponding to each target light field camera;
图像合成模块,被配置为根据所述前景视点图像和所述背景视点图像生成目标光场图像。An image synthesis module configured to generate a target light field image according to the foreground viewpoint image and the background viewpoint image.
在一些实施方式中,所述前景融合模块被配置为:In some implementations, the foreground fusion module is configured to:
对所述光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像;performing image segmentation on each light field image in the light field image group to obtain a foreground image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,对所述第一光场图像对应的第一前景图像以及所述第二光场图像对应的第二前景图像进行视差估计,得到所述第一前景图像对应的第一前景视差图以及第二前景图像对应的所述第二前景视差图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, the first foreground image corresponding to the first light field image and the first foreground image corresponding to the second light field image Performing disparity estimation on the second foreground image to obtain a first foreground disparity map corresponding to the first foreground image and a second foreground disparity map corresponding to the second foreground image;
基于第一前景视差图对所述第一前景图像进行视差映射得到第一前景映射图,基于第二前景视差图对所述第二前景图像进行视差映射得到第二前景映射图;performing parallax mapping on the first foreground image based on the first foreground disparity map to obtain a first foreground map, and performing parallax mapping on the second foreground image based on the second foreground disparity map to obtain a second foreground map;
基于所述目标视点信息对所述第一前景映射图和所述第二前景映射图进行图像融合处理,得到所述前景视点图像。performing image fusion processing on the first foreground map and the second foreground map based on the target viewpoint information to obtain the foreground viewpoint image.
在一些实施方式中,所述前景融合模块被配置为:In some implementations, the foreground fusion module is configured to:
对于所述光场图像组中的每个光场图像,基于预先生成的与所述光场图像相同视点位置的预设背景图像,对所述光场图像进行图像差分,得到所述光场图像对应的前景图像和背景图像。For each light field image in the light field image group, based on a pre-generated preset background image at the same viewpoint position as the light field image, image difference is performed on the light field image to obtain the light field image Corresponding foreground and background images.
在一些实施方式中,所述前景融合模块被配置为:In some implementations, the foreground fusion module is configured to:
基于预设降采样系数对所述第一前景图像进行降采样得到第一降采样图,对所述第二前景图像进行降采样得到第二降采样图;performing downsampling on the first foreground image based on a preset downsampling coefficient to obtain a first downsampling image, and performing downsampling on the second foreground image to obtain a second downsampling image;
对所述第一降采样图和所述第二降采样图上相同像素的位置进行匹配,得到第一降采样图对应的第一视差图,以及第二降采样图对应的第二视差图;matching the positions of the same pixels on the first downsampled image and the second downsampled image to obtain a first disparity map corresponding to the first downsampled image and a second disparity map corresponding to the second downsampled image;
根据所述第一视差图和所述预设降采样系数确定第一视差搜索范围,根据所述第二视差图和所述预设降采样系数确定第二视差搜索范围;determining a first disparity search range according to the first disparity map and the preset downsampling coefficient, and determining a second disparity search range according to the second disparity map and the preset downsampling coefficient;
基于所述第一视差搜索范围对所述第一前景图像进行视差估计得到所述第一前景视差图,基于所述第二视差搜索范围对所述第二前景图像进行视差估计得到所述第二前景视差图。Performing disparity estimation on the first foreground image based on the first disparity search range to obtain the first foreground disparity map, and performing disparity estimation on the second foreground image based on the second disparity search range to obtain the second foreground image Foreground disparity map.
在一些实施方式中,所述前景融合模块被配置为:In some implementations, the foreground fusion module is configured to:
根据所述第一前景视差图将所述第一前景图像上的每个像素匹配至映射图上的对应像素位置,得到所述第一前景映射图;根据所述第二前景视差图将所述第二前景图像上的每个像素匹配至映射图上的对应像素位置,得到所述第二前景映射图;matching each pixel on the first foreground image to a corresponding pixel position on the map according to the first foreground disparity map to obtain the first foreground map; according to the second foreground disparity map matching each pixel on the second foreground image to a corresponding pixel position on the map to obtain the second foreground map;
根据所述目标视点信息与所述任意两个相邻的目标光场相机的位置信息,确定第一权值和第二权值;determining a first weight and a second weight according to the target viewpoint information and the position information of any two adjacent target light field cameras;
基于所述第一权值和所述第二权值,对所述第一前景映射图和所述第二前景映射图进行图像融合处理,得到所述前景视点图像。Based on the first weight and the second weight, image fusion processing is performed on the first foreground map and the second foreground map to obtain the foreground viewpoint image.
在一些实施方式中,所述背景融合模块被配置为:In some implementations, the background fusion module is configured to:
对所述光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的背景图像;performing image segmentation on each light field image in the light field image group to obtain a background image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,基于预先生成的与所述第一光场图像相同视点位置的第一背景视差图,对所述第一光场图像的第一背景图像进行视差映射得到第一背景映射图,基于预先生成的与所述第二光场图像相同视点位置的第二背景视差图,对所述第二光场图像的第二背景图像进行视差映射得到第二背景映射图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, based on the pre-generated first background disparity map at the same viewpoint position as the first light field image, the performing parallax mapping on the first background image of the first light field image to obtain a first background map, and based on the pre-generated second background parallax map at the same viewpoint position as the second light field image, performing parallax mapping on the second background image of the image to obtain a second background map;
基于所述目标视点信息对所述第一背景映射图和所述第二背景映射图进行图像融合处理,得到所述背景视点图像。performing image fusion processing on the first background map and the second background map based on the target viewpoint information to obtain the background viewpoint image.
在一些实施方式中,所述获取模块被配置为:In some implementations, the acquisition module is configured to:
通过设于所述显示设备上的图像采集装置采集场景图像;collecting scene images through an image collection device arranged on the display device;
根据所述场景图像进行图像检测,得到场景图像中观察者眼睛的位置信息;performing image detection according to the scene image to obtain position information of the observer's eyes in the scene image;
基于所述位置信息生成所述目标视点信息。The target viewpoint information is generated based on the position information.
在一些实施方式中,所述获取模块被配置为:In some implementations, the acquisition module is configured to:
将所述目标视点信息发送至所述采集设备,以使所述采集设备根据所述目标视点信息从多个光场相机中确定一个或多个所述目标光场相机;sending the target viewpoint information to the acquisition device, so that the acquisition device determines one or more target light field cameras from a plurality of light field cameras according to the target viewpoint information;
接收所述采集设备发送的所述光场图像组。The light field image group sent by the acquisition device is received.
在一些实施方式中,所述获取模块被配置为:In some implementations, the acquisition module is configured to:
接收所述采集设备发送的每个视点位置的背景视差图并存储。The background disparity map of each viewpoint position sent by the collection device is received and stored.
第四方面,本公开实施方式提供了一种光场图像处理装置,应用于采集设备,所述装置包括:In a fourth aspect, an embodiment of the present disclosure provides a light field image processing device, which is applied to a collection device, and the device includes:
图像采集模块,被配置为通过设于所述采集设备上的多个光场相机分别采集当前场景图像,得到每个光场相机对应的视点位置的场景图像;The image acquisition module is configured to respectively acquire the current scene image through a plurality of light field cameras arranged on the acquisition device, so as to obtain the scene image of the viewpoint position corresponding to each light field camera;
视差确定模块,被配置为对于任意相邻的两个光场相机,根据两个光场相机分别采集的场景图像,生成每个光场相机的视点位置的背景视差图;The parallax determination module is configured to generate a background parallax map of the viewpoint position of each light field camera for any two adjacent light field cameras according to the scene images respectively collected by the two light field cameras;
发送模块,被配置为将每个视点位置的背景视差图发送至显示设备,以使所述显示设备存储每个视点位置的背景视差图。The sending module is configured to send the background disparity map of each viewpoint position to the display device, so that the display device stores the background disparity map of each viewpoint position.
在一些实施方式中,所述发送模块被配置为:In some implementations, the sending module is configured to:
接收所述显示设备发送的目标视点信息;receiving target viewpoint information sent by the display device;
根据所述目标视点信息,从所述采集设备包括的多个光场相机中确定一个或多个目标光场相机;determining one or more target light field cameras from the plurality of light field cameras included in the acquisition device according to the target viewpoint information;
通过所述目标光场相机采集光场图像得到光场图像组,并将所述光场图像组发送至所述显示设备。Collecting light field images by the target light field camera to obtain a light field image group, and sending the light field image group to the display device.
第五方面,本公开实施方式提供了一种电子设备,包括:In a fifth aspect, an embodiment of the present disclosure provides an electronic device, including:
处理器;和processor; and
存储器,存储有计算机指令,所述计算机指令用于使所述处理器执行根据第一方面任意实施方式所述的方法,或者执行根据第二方面任意实施方式所述的方法。The memory stores computer instructions for causing the processor to execute the method according to any implementation manner of the first aspect, or execute the method according to any implementation manner of the second aspect.
第六方面,本公开实施方式提供了一种视频通信系统,包括:In a sixth aspect, an embodiment of the present disclosure provides a video communication system, including:
显示设备,包括图像采集装置和第一控制器,所述第一控制器用于执行根据第一方面任意实施方式所述的方法;A display device, including an image acquisition device and a first controller, the first controller is configured to execute the method according to any implementation manner of the first aspect;
采集设备,包括光场相机阵列和第二控制器,所述光场相机阵列包括多个光场相机,所述第二控制器用于执行根据第二方面任意实施方式所述的方法。The acquisition device includes a light field camera array and a second controller, the light field camera array includes a plurality of light field cameras, and the second controller is configured to execute the method according to any implementation manner of the second aspect.
第七方面,本公开实施方式提供了一种存储介质,存储有计算机指令,所述计算机指令用于使计算机执行根据第一方面任意实施方式所述的方法,或者执行根据第二方面任意实施方式所述的方法。In the seventh aspect, the embodiments of the present disclosure provide a storage medium, which stores computer instructions, and the computer instructions are used to make the computer execute the method according to any implementation manner of the first aspect, or execute the method according to any implementation manner of the second aspect. the method described.
本公开实施方式的光场图像处理方法,包括获取目标试点信息以及由采集设备发送的光场图像组,基于目标视点信息对各个光场图像中的前景图像进行视点融合得到前景视点图像,基于目标视点信息以及预先生成的每个视点位置的背景视点图,对各个光场图像中的背景图像进行视点融合得到背景视点图像,根据前景视点图像和背景视点图像生成目标光场图像。本公开实施方式中,通过前背景分割的方式,预先生成背景图像的视差图,从而无需实时计算针对复杂背景的视差图,大大缩减视点图像合成的数据量,提高图像处理速度和精度,可以实现实时光场视频通信。The light field image processing method of the embodiment of the present disclosure includes acquiring the target pilot information and the light field image group sent by the acquisition device, performing viewpoint fusion on the foreground images in each light field image based on the target viewpoint information to obtain the foreground viewpoint image, and obtaining the foreground viewpoint image based on the target viewpoint information. Viewpoint information and the pre-generated background viewpoint image of each viewpoint position, perform viewpoint fusion on the background images in each light field image to obtain the background viewpoint image, and generate the target light field image according to the foreground viewpoint image and the background viewpoint image. In the embodiment of the present disclosure, the disparity map of the background image is generated in advance by means of foreground and background segmentation, so that there is no need to calculate the disparity map for the complex background in real time, greatly reducing the amount of data for viewpoint image synthesis, improving the speed and accuracy of image processing, and realizing Real-time light field video communication.
附图说明Description of drawings
为了更清楚地说明本公开具体实施方式或现有技术中的技术方案,下面将对具体实施方式或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本公开的一些实施方式,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the specific embodiments of the present disclosure or the technical solutions in the prior art, the following will briefly introduce the drawings that need to be used in the description of the specific embodiments or the prior art. Obviously, the accompanying drawings in the following description The drawings are some implementations of the present disclosure, and those skilled in the art can also obtain other drawings according to these drawings without creative work.
图1是根据本公开一些实施方式中视频通信系统的架构图。Fig. 1 is an architecture diagram of a video communication system according to some implementations of the present disclosure.
图2是根据本公开一些实施方式中电子设备的结构示意图。Fig. 2 is a schematic structural diagram of an electronic device according to some implementations of the present disclosure.
图3是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 3 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图4是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 4 is a flowchart of a light field image processing method according to some implementations of the present disclosure.
图5是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 5 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图6是根据本公开一些实施方式中光场图像处理方法的原理图。Fig. 6 is a schematic diagram of a light field image processing method according to some embodiments of the present disclosure.
图7是根据本公开一些实施方式中光场相机阵列的电路结构示意图。Fig. 7 is a schematic diagram of a circuit structure of a light field camera array according to some embodiments of the present disclosure.
图8是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 8 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图9是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 9 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图10是根据本公开一些实施方式中光场图像处理方法的原理图。Fig. 10 is a schematic diagram of a light field image processing method according to some embodiments of the present disclosure.
图11是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 11 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图12是根据本公开一些实施方式中光场图像处理方法的流程图。Fig. 12 is a flowchart of a light field image processing method according to some embodiments of the present disclosure.
图13是根据本公开一些实施方式中光场图像处理装置的结构框图。Fig. 13 is a structural block diagram of a light field image processing device according to some embodiments of the present disclosure.
图14是根据本公开一些实施方式中光场图像处理装置的结构框图。Fig. 14 is a structural block diagram of a light field image processing device according to some embodiments of the present disclosure.
图15是根据本公开一些实施方式中电子设备的结构框图。Fig. 15 is a structural block diagram of an electronic device according to some embodiments of the present disclosure.
具体实施方式Detailed ways
下面将结合附图对本公开的技术方案进行清楚、完整地描述,显然,所描述的实施方式是本公开一部分实施方式,而不是全部的实施方式。基于本公开中的实施方式,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施方式,都属于本公开保护的范围。此外,下面所描述的本公开不同实施方式中所涉及的技术特征只要彼此之间未构成冲突就可以相互结合。The technical solutions of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings. Apparently, the described implementations are part of the implementations of the present disclosure, but not all of them. Based on the implementation manners in the present disclosure, all other implementation manners obtained by persons of ordinary skill in the art without creative efforts shall fall within the protection scope of the present disclosure. In addition, the technical features involved in different embodiments of the present disclosure described below may be combined with each other as long as they do not constitute a conflict with each other.
光场(Light Field)的定义是指光在每一个方向通过每一个点的光量,光场图像可以记录比传统二维图像更高维度的光线数据,从而呈现出比传统二维成像及以双目立体视觉为代表的传统三维成像更高精度的三维信息。The definition of light field (Light Field) refers to the amount of light passing through each point in each direction. Light field images can record higher-dimensional light data than traditional two-dimensional images, thus presenting a more comprehensive image than traditional two-dimensional imaging and dual-dimensional imaging. Traditional 3D imaging represented by stereo vision provides higher-precision 3D information.
光场视频可以准确感知动态环境,结合眼球追踪技术,在用户观看视点发生变化时,视频画面可以实时跟随视点变化,从而呈现给用户身临其境的裸眼3D观看体验。Light field video can accurately perceive the dynamic environment. Combined with eye tracking technology, when the user's viewing point of view changes, the video screen can follow the change of the point of view in real time, thus presenting the user with an immersive naked-eye 3D viewing experience.
光场视频的数据采集需要用到光场相机阵列,光场相机阵列中包括数个甚至数十个不同位置的光场相机,每个光场相机负责采集一个视点位置的图像,从而光场视频的数据量庞大,导致后期对于不同相机采集的图像数据进行视点合成的运算量很大,数据处理速度很慢。The data collection of light field video requires the use of light field camera array, which includes several or even dozens of light field cameras at different positions, and each light field camera is responsible for collecting images of a viewpoint position, so that light field video The amount of data is huge, which leads to a large amount of computation for viewpoint synthesis of image data collected by different cameras in the later stage, and the data processing speed is very slow.
因此,相关技术中光场视频主要用于离线视频场景,对于实时性的视频场景难以实现。例如以远程视频聊天场景为例,用户A通过第一设备观看用户B所在场景的光场视频,需要实时针对用户B所在场景的光场视频数据进行处理发送,同时结合用户A的视点信息对光场视频画面进行合成渲染,整个过程数据运算量很大,难以做到实时呈现。Therefore, the light field video in the related art is mainly used in an offline video scene, and it is difficult to realize a real-time video scene. For example, take the remote video chat scene as an example. User A watches the light field video of the scene where user B is located through the first device, and needs to process and send the light field video data of the scene where user B is located in real time. Composite rendering of field video images, the whole process involves a lot of data computation, and it is difficult to achieve real-time presentation.
基于上述相关技术存在的缺陷,本公开实施方式提供了一种光场图像处理方法、装置、电子设备、视频通信系统及存储介质,旨在提高光场数据处理速度,实现实时性的光场视频呈现。Based on the defects in the above-mentioned related technologies, the embodiments of the present disclosure provide a light field image processing method, device, electronic equipment, video communication system and storage medium, aiming at improving the processing speed of light field data and realizing real-time light field video presented.
图1示出了本公开一些实施方式中视频通信系统的架构图,下面结合图1对本公开实施方式的应用场景进行说明。FIG. 1 shows an architecture diagram of a video communication system in some embodiments of the present disclosure. The application scenarios of the embodiments of the present disclosure will be described below with reference to FIG. 1 .
如图1所示,在一些实施方式中,视频通信系统包括采集设备100和显示设备200,采集设备100和显示设备200通过有线或者无线网络建立可通信连接。As shown in FIG. 1 , in some implementations, the video communication system includes a
在一个示例性的单向视频通信场景下,采集设备100可以采集用户A所在场景的光场图像数据,并将光场图像数据发送至显示设备200。显示设备200通过对用户B的眼部位置追踪,得到用户B当前观看的视点位置,结合该视点位置及采集设备100发送的光场图像数据进行视点图像合成,并在显示设备200上渲染展示合成后的光场图像。In an exemplary one-way video communication scenario, the
当然可以理解,上述示例仅以单向视频通信为例,但是本公开方案并不局限于单向视频通信场景,对于双向视频通信场景,显示设备200同时也可以采集用户B所在场景的光场图像数据,并将光场图像数据发送至采集设备100。采集设备100同时也可以对用户A的眼部位置进行追踪,得到用户A当前观看的视点位置,结合该视点位置及显示设备200发送的光场图像数据进行视点图像合成,并在采集设备100上渲染展示合成后的光场图像。本领域技术人员对此可以理解,本公开不再赘述。Of course, it can be understood that the above example only takes one-way video communication as an example, but the disclosed solution is not limited to the one-way video communication scene. For the two-way video communication scene, the
以双向视频通信场景为例,图2示出了本公开一些实施方式中电子设备的结构示意图,该电子设备既可以是采集设备100,也可以是显示设备200,本公开对此不作限制。Taking a two-way video communication scene as an example, FIG. 2 shows a schematic structural diagram of an electronic device in some implementations of the present disclosure. The electronic device can be either a
如图2所示,电子设备包括显示屏110、光场相机阵列120以及图像采集装置130。As shown in FIG. 2 , the electronic device includes a
显示屏110用于显示光场图像,显示屏110可以是任何适于实施的屏幕组件,例如LCD(Liquid Crystal Display,液晶显示)屏、OLED(Organic Light-Emitting Diode,有机发光半导体)屏等,本公开对此不作限制。The
光场相机阵列120包括多个光场相机121,这些光场相机121在电子设备上呈阵列形式部署,由于每个光场相机121在电子设备上的部署位置不同,从而光场相机阵列120可以采集到不同视点位置的场景图像。The light
例如图2示例中,光场相机阵列120共包括9个光场相机121,且9个光场相机121在显示屏110的上边缘均匀间隔设置。当然,本领域技术人员可以理解,光场相机阵列120的相机数量和部署方式并不局限于图2所示,还可以是其他任何适于实施的形式,本公开对此不作限制。For example, in the example shown in FIG. 2 , the light
图像采集装置130则是用于实现用户眼部追踪的相机,其可以是例如高精度的RGB相机,也即,图像采集装置130通过采集当前场景图像,并对场景图像进行图像检测,确定当前用户视点信息,该视点信息即表示用户眼睛的位置信息。在图2示例中,图像采集装置130设于电子设备的显示屏110的下方,但是可以理解,本公开对于图像采集装置130的位置不作限定。The
在上述图1和图2所示的视频通信系统基础上,下面对本公开实施方式的光场图像处理方法进行说明。On the basis of the above video communication system shown in FIG. 1 and FIG. 2 , the light field image processing method according to the embodiment of the present disclosure will be described below.
值得说明的是,为便于理解,本公开下文实施方式中将以单向视频通信场景为例进行说明,也即采集设备100作为光场数据采集端,显示设备200作为光场视频显示端,对于双向视频通信场景的原理与之完全相同,本公开对此不再赘述。It is worth noting that, for ease of understanding, the following embodiments of the present disclosure will take a one-way video communication scenario as an example, that is, the
在一些实施方式中,本公开示例提供了一种光场图像处理方法,该方法可应用于显示设备200中,由显示设备200的处理器执行处理,下面结合图3进行说明。In some implementations, the present disclosure provides a light field image processing method, which can be applied to the
如图3所示,在一些实施方式中,本公开示例的光场图像处理方法,包括:As shown in FIG. 3 , in some implementations, the light field image processing method of the present disclosure includes:
S310、获取目标视点信息以及由采集设备发送的光场图像组。S310. Acquire target viewpoint information and a light field image group sent by the acquisition device.
可以理解,光场图像包括很多视点位置的视点图像,但是用户眼睛所能接收到的视点位置有限,也即并非所有的视点图像均会进入用户眼睛,因此显示设备200上渲染显示的目标光场图像是结合用户当前的视点位置所生成的视点合成图像。从而,本公开实施方式中,即需要结合用户当前的目标视点信息来进行视点图像合成,得到目标光场图像。It can be understood that the light field image includes viewpoint images of many viewpoint positions, but the viewpoint positions that the user's eyes can receive are limited, that is, not all viewpoint images will enter the user's eyes, so the target light field rendered and displayed on the
结合图1所示场景,在显示设备200端,可以通过显示设备200上的图像采集装置130并结合眼部追踪算法,实现对用户B的视点追踪,得到用户B眼睛的位置信息,该位置信息即为本公开所述的目标视点信息。对于眼部追踪得到目标视点信息的过程,本公开下文实施方式进行说明,在此暂不详述。In combination with the scene shown in FIG. 1 , on the
同时,显示设备200还需要接收来自采集设备100的光场图像组,光场图像组是指通过采集设备100上的光场相机阵列120采集到的图像组。结合图2所示,在本示例中光场相机阵列共包括9个光场相机,每个相机可以采集到一张光场图像,光场图像组即为这些光场图像的集合。At the same time, the
值得说明的是,在一些实施方式中,光场图像组中可以包括每个光场相机所采集到的光场图像,例如图2示例中,9个光场相机分别采集一张光场图像,从而光场图像组中共包括9张光场图像,也即光场相机阵列120中的每个光场相机121均为本公开所述的目标光场相机。It is worth noting that, in some implementations, the light field image group may include light field images collected by each light field camera. For example, in the example in FIG. 2, 9 light field cameras collect a light field image respectively, Therefore, the light field image group includes 9 light field images in total, that is, each
在另一些实施方式中,结合前述的原理可知,由于人眼所能接收到的视点数量有限,并非所有的视点图像均能进入观察者眼睛,也即光场相机阵列120所采集的光场图像组中存在大量的冗余图像,这部分冗余图像数据也会导致数据处理速度变慢。In some other implementations, it can be seen from the combination of the aforementioned principles that, due to the limited number of viewpoints that the human eye can receive, not all viewpoint images can enter the observer's eyes, that is, the light field images collected by the light
因此,可以基于目标视点信息从多个光场相机中选择一个或多个目标光场相机进行光场图像采集,目标光场相机即为目标视点信息所对应位置的光场相机。可以理解,仅利用用户视点位置的目标光场相机采集得到光场图像组,可以筛除冗余图像数据,在保证图像精度的情况下降低运算量,提高数据处理效率,本公开下文实施方式对此进行说明。Therefore, one or more target light field cameras may be selected from multiple light field cameras based on the target viewpoint information to collect light field images, and the target light field camera is the light field camera at a position corresponding to the target viewpoint information. It can be understood that only using the target light field camera at the user's viewpoint to acquire the light field image group can filter out redundant image data, reduce the amount of computation while ensuring image accuracy, and improve data processing efficiency. This is for explanation.
S320、基于目标视点信息对各个光场图像中的前景图像进行视点融合,得到目标视点信息所对应的前景视点图像。S320. Perform viewpoint fusion on the foreground images in each light field image based on the target viewpoint information, to obtain foreground viewpoint images corresponding to the target viewpoint information.
S330、基于目标视点信息以及预先生成的每个视点位置的背景视差图,对各个光场图像中的背景图像进行视点融合,得到目标视点信息对应的背景视点图像。S330. Based on the target viewpoint information and the pre-generated background disparity map for each viewpoint position, perform viewpoint fusion on the background images in each light field image to obtain a background viewpoint image corresponding to the target viewpoint information.
可以理解,显示设备200上所显示的光场图像需要跟随用户的视点位置进行变化,从而在生成目标光场图像时,需要结合用户的目标视点信息对光场图像组中的光场图像进行视点图像合成,进而得到在用户新视点下的目标光场图像,实现画面随动效果。It can be understood that the light field images displayed on the
本公开实施方式中,为了加快视点图像合成速度,满足光场视频的实时性要求,将视点图像合成分为前景视点图像合成以及背景视点图像合成。In the embodiments of the present disclosure, in order to speed up the synthesis speed of viewpoint images and meet the real-time requirements of light field video, the synthesis of viewpoint images is divided into synthesis of foreground viewpoint images and synthesis of background viewpoint images.
值得说明的是,结合视频通信场景可知,以视频会议为例,用于实现视频会议的大屏电子设备往往位置比较固定,从而在视频通信期间,采集设备100所采集到的场景图像中的背景部分几乎不会发生变化,一般只有前景的人或物体会产生运动。It is worth noting that, in combination with the video communication scene, it can be known that taking video conference as an example, the large-screen electronic equipment used to realize the video conference is usually in a relatively fixed position, so that during the video communication, the background in the scene image collected by the
因此,本公开实施方式中,可以考虑将光场图像中的前景和背景进行分割,对于变化很小的背景图像,可以通过预先处理的方式,提前生成每个视点位置的背景视差图。Therefore, in the embodiments of the present disclosure, it may be considered to divide the foreground and background in the light field image, and for the background image with little change, the background disparity map of each viewpoint position may be generated in advance through preprocessing.
视差(Diaparity)是指由于视点位置的不同所带来的图像像素的偏移,视差图(Diaparity Map)即为反映该像素偏移的图像,视差图是一张二维图像,其大小与原图相等,视差图上的每个像素表示原图上该位置像素的视差值。例如图2所示中,以光场相机阵列120中任意相邻的两个光场相机121为例,由于两者所部署的位置不同,从而采集得到的光场图像上的像素也存在偏差,视差图即用来记录两张图像上的像素偏差。Parallax (Diaparity) refers to the offset of image pixels due to different viewpoint positions. The Diaparity Map (Diaparity Map) is an image that reflects the pixel offset. The Disparity Map is a two-dimensional image whose size is equal to the original image. , each pixel on the disparity map represents the disparity value of the pixel at that position on the original image. For example, as shown in FIG. 2 , taking any two adjacent
对于实时光场视频通信场景,由于光场相机阵列120包括相机数量较多,而且每个相机位置代表一个视点位置,从而在视点图像合成时,需要计算每张光场图像与相邻图像的视差图,计算数据量较大,导致难以实现实时性。For real-time light field video communication scenarios, since the light
而本公开实施方式中,则考虑用户A所处场景中,背景部分几乎不会产生变化,从而可以针对光场图像的背景部分预先生成视差图。例如,可以在采集设备100开机时,采集设备100上的光场相机阵列120采集当前场景图像,预先构建得到每个视点位置所对应的背景视差图,从而,在后续采集设备100与显示设备200建立视频通信连接时,将该背景视差图发送至显示设备200,则显示设备200可以直接基于预先得到的背景视差图对当前光场图像中的背景部分进行背景视点图像的合成,无需重新计算背景部分的视差图,以此缩减数据量,加快视点图像的合成。However, in the embodiments of the present disclosure, it is considered that in the scene where the user A is located, the background part hardly changes, so the disparity map can be generated in advance for the background part of the light field image. For example, when the
同时,对于光场图像中的前景图像,结合视频通信场景可知,前景人物一般只占图像较小的范围,在将复杂的背景图像分割出去之后,针对前景图像进行视点图像合成的速度也会大大提高,从而满足视频通信的实时性和低延时要求。At the same time, for the foreground image in the light field image, combined with the video communication scene, it can be seen that the foreground figure generally only occupies a small area of the image. After the complex background image is segmented out, the speed of viewpoint image synthesis for the foreground image will also be greatly improved. Improve, so as to meet the real-time and low-latency requirements of video communication.
本公开一些实施方式中,显示设备200在接收到采集设备100发送的光场图像组之后,可以首先对光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像和背景图像。In some embodiments of the present disclosure, after receiving the light field image group sent by the
对于前景图像,由于无法预先建立前景视差图,从而可以对其进行实时的视差图计算,得到每个视点位置的前景视差图,然后基于前景视差图和目标视点信息对各个前景图像进行视点融合,得到对应目标视点信息下的前景视点图像。For the foreground image, since the foreground disparity map cannot be established in advance, real-time disparity map calculation can be performed on it to obtain the foreground disparity map of each viewpoint position, and then based on the foreground disparity map and target viewpoint information, the viewpoint fusion of each foreground image is performed. The foreground viewpoint image corresponding to the target viewpoint information is obtained.
对于背景图像,由于预先已经建立各个视点位置的背景视差图,从而无需在进行视差图计算,直接基于预先建立的背景视差图和目标视点信息对各个背景图像进行视点融合,即可得到对应目标视点信息下的背景视点图像。For the background image, since the background disparity map of each viewpoint position has been established in advance, there is no need to calculate the disparity map, and the viewpoint fusion of each background image is directly based on the pre-established background disparity map and target viewpoint information, and the corresponding target viewpoint can be obtained Background viewpoint image under information.
对于前景视点图像和背景视点图像的视点融合过程,本公开下文实施方式对此进行说明,在此暂不详述。For the viewpoint fusion process of the foreground viewpoint image and the background viewpoint image, this will be described in the following embodiments of the present disclosure, and will not be described in detail here.
S340、根据前景视点图像和背景视点图像生成目标光场图像。S340. Generate a target light field image according to the foreground viewpoint image and the background viewpoint image.
可以理解,前景视点图像表示在新视点位置(也即目标视点信息对应的视点位置)的前景图像,背景视点图像表示在新视点位置(也即目标视点信息对应的视点位置)的背景图像。It can be understood that the foreground viewpoint image represents the foreground image at the new viewpoint position (that is, the viewpoint position corresponding to the target viewpoint information), and the background viewpoint image represents the background image at the new viewpoint position (that is, the viewpoint position corresponding to the target viewpoint information).
从而,在得到前景视点图像和背景视点图像之后,对两者进行融合处理即可得到目标光场图像。例如一个示例中,将前景视点图像贴在背景视点图像上,即可得到目标光场图像。Therefore, after the foreground viewpoint image and the background viewpoint image are obtained, the target light field image can be obtained by performing fusion processing on the two. For example, in an example, the target light field image can be obtained by pasting the foreground viewpoint image on the background viewpoint image.
在得到目标光场图像之后,即可在显示设备200的显示屏上渲染显示该目标光场图像,用户B即可通过显示屏观看到目标光场图像。After the target light field image is obtained, the target light field image can be rendered and displayed on the display screen of the
可以理解,上述实施方式中以一帧目标光场图像的生成过程进行了说明,对于光场视频的每一帧图像,重复执行上述过程,即可在显示设备200上实现光场视频的播放。It can be understood that, in the above embodiment, the process of generating a frame of target light field image is described. For each frame of light field video image, the above process is repeated, and the light field video can be played on the
同时可以理解,对于目标光场图像的生成过程中,需要结合观察者的视点位置(也即目标视点信息对应的视点位置),从而在观察者眼部位置移动时,目标视点信息也随之更新,从而最终得到的目标光场图像也变化为新视点位置所对应的光场图像,呈现出视频画面跟随观察者视点变化的裸眼3D效果。在例如视频会议场景中,使得用户产生身临其境的体验,消除常规二维视频通信所产生的距离感,提高用户通信体验。At the same time, it can be understood that in the process of generating the target light field image, it is necessary to combine the viewpoint position of the observer (that is, the viewpoint position corresponding to the target viewpoint information), so that when the observer's eye position moves, the target viewpoint information is also updated accordingly , so that the finally obtained target light field image is also changed to a light field image corresponding to the new viewpoint position, presenting a naked-eye 3D effect in which the video picture changes with the viewer's viewpoint. For example, in a video conferencing scenario, the user can have an immersive experience, eliminate the sense of distance generated by conventional two-dimensional video communication, and improve the user communication experience.
通过上述可知,本公开实施方式中,通过将光场图像进行前景与背景分割,并且基于预先生成的背景视差图实现视点图像合成,降低视点图像合成的数据量,提高运算效率和精度,进而实现光场视频的实时低延时通信,提高用户视频通信体验。From the above, it can be seen that in the embodiments of the present disclosure, by dividing the light field image into the foreground and the background, and realizing the viewpoint image synthesis based on the pre-generated background disparity map, the data volume of the viewpoint image synthesis is reduced, and the calculation efficiency and accuracy are improved, and further realize Real-time low-latency communication of light field video improves user video communication experience.
结合前述可知,本公开实施方式中,需要在采集设备100端预先生成每个视点位置的背景视差图,下面结合图4对生成背景视差图的过程进行说明。In combination with the foregoing, it can be seen that in the embodiments of the present disclosure, it is necessary to pre-generate the background disparity map of each viewpoint position at the
如图4所示,在一些实施方式中,本公开示例的光场图像处理方法,应用于采集设备100,采集设备100生成背景视差图的过程包括:As shown in FIG. 4 , in some implementations, the light field image processing method of the example of the present disclosure is applied to the
S410、通过设于采集设备上的多个光场相机分别采集当前场景图像,得到每个光场相机对应的视点位置的场景图像。S410. Collect the current scene image respectively through multiple light field cameras arranged on the collection device, and obtain the scene image of the viewpoint position corresponding to each light field camera.
S420、对于任意相邻的两个光场相机,根据两个光场相机分别采集的场景图像,生成每个光场相机的视点位置的背景视差图。S420. For any two adjacent light field cameras, generate a background disparity map of the viewpoint position of each light field camera according to the scene images respectively collected by the two light field cameras.
S430、将每个视点位置的背景视差图发送至显示设备,以使显示设备存储每个视点位置的背景视差图。S430. Send the background disparity map of each viewpoint position to the display device, so that the display device stores the background disparity map of each viewpoint position.
在一些实施方式中,可以在采集设备100每次开机时,执行S410~S430过程生成当前场景下的背景视差图。In some implementation manners, the process of S410-S430 may be executed to generate the background disparity map in the current scene each time the
例如图1示例中,在采集设备100开机时,此时采集设备100并未与显示设备200建立视频通信连接,从而采集设备100所处的场景中没有用户A,仅包括背景,此时则可以利用采集设备100来生成每个视点位置的背景视差图。For example, in the example in FIG. 1, when the
结合图2所示,采集设备100可以通过设于上方的光场相机阵列120中的每个光场相机分别采集一张当前场景图像,也即图2示例中,光场相机阵列120中的9个光场相机121各采集一张当前场景图像。As shown in FIG. 2, the
可以理解,由于光场相机阵列120中每个光场相机121的部署位置不同,从而采集得到的场景图像对应不同的视点位置,某个视点位置的视差图即可以理解为,该视点位置的光场图像相对于其他视点位置的光场图像的像素偏差。本公开实施方式中,每个视点位置的背景视差图,即为该视点位置的光场图像与相邻视点位置的光场图像的视差图。It can be understood that since the deployment positions of each
本公开一些实施方式中,可以基于视差估计算法来确定每个视差位置相对于相邻视差位置的背景视差图,对于视差估计算法的具体过程,可参照本文下述计算前景视差图的方法过程,在此暂不详述。In some embodiments of the present disclosure, the background disparity map of each disparity position relative to adjacent disparity positions can be determined based on the disparity estimation algorithm. For the specific process of the disparity estimation algorithm, you can refer to the following method for calculating the foreground disparity map in this paper. It will not be described in detail here.
在另一些实施方式中,考虑到背景视差图的估计过程为预先构建,因此对于运算速度无要求,从而可以采用精度更高的视差估计方法。例如一个示例中,可以采用基于深度神经网络(DNN,Deep Neural Network)的视差估计网络,可以通过人工标注的方式预先训练得到视差估计网络,然后将任意相邻两个视点位置的场景图像输入视差估计网络,得到每个视点位置所对应的背景视差图。In some other implementation manners, considering that the estimation process of the background disparity map is pre-built, there is no requirement on the operation speed, so a disparity estimation method with higher precision can be used. For example, in an example, a disparity estimation network based on a deep neural network (DNN, Deep Neural Network) can be used, and the disparity estimation network can be pre-trained by manual labeling, and then the scene images of any two adjacent viewpoint positions can be input into the disparity Estimate the network to obtain the background disparity map corresponding to each viewpoint position.
在通过上述过程得到每个视点位置的背景视差图之后,采集设备100可以将背景视差图存储在缓存中。After the background disparity map of each viewpoint position is obtained through the above process, the
在完成上述离线阶段的准备工作之后,当显示设备200与采集设备100建立视频通信连接时,表示显示设备200的用户B需要与采集设备100的用户A进行视频通信,此时采集设备100可以将存储在缓存中的背景视差图发送至显示设备200,显示设备200在接收每个视点位置的背景视差图之后,可以将背景视差图进行存储,以等待后续视点图像合成阶段调用。下面将对视频通信过程中采集设备100与显示设备200的交互过程进行说明。After completing the preparatory work in the above-mentioned offline stage, when the
结合前述可知,在视频通信场景下,显示设备200的用户B所能观察到的视点有限,因此,采集设备100的光场相机阵列120所采集到的光场图像组中存在大量冗余图像。本公开一些实施方式中,则可以根据用户B当前的眼睛位置信息,从采集设备100的多个光场相机中确定目标光场相机,下面结合图5进行说明。It can be seen from the foregoing that in the video communication scenario, user B of the
如图5所示,在一些实施方式中,本公开示例的光场图像处理方法,包括:As shown in FIG. 5, in some implementations, the light field image processing method of the example of the present disclosure includes:
S510、显示设备通过图像采集装置采集场景图像。S510. The display device collects the scene image through the image collection device.
结合图1、图2所示,显示设备200可以通过设于设备上的图像采集装置130采集包括用户B的场景图像。As shown in FIG. 1 and FIG. 2 , the
S520、显示设备根据场景图像进行图像检测,得到场景图像中观察者眼睛的位置信息。S520. The display device performs image detection according to the scene image, and obtains position information of the observer's eyes in the scene image.
然后,显示设备200即可基于眼部追踪算法对采集到的场景图像进行图像检测,从而确定观察者(也即用户B)的眼睛的位置信息,该位置信息表示观察者眼睛在场景图像上的图像位置。Then, the
S530、显示设备基于位置信息生成目标视点信息。S530. The display device generates target viewpoint information based on the location information.
之后,显示设备200可以根据观察者眼睛的位置信息,将该位置信息映射到显示设备200的光场相机阵列120的视点位置上,得到目标视点信息,也即目标视点信息表示观察者眼睛在显示设备200的光场相机阵列120中的位置信息。Afterwards, the
例如一个示例中,用户B的眼睛的位置信息映射到显示设备200的光场相机阵列120中的目标视点信息如图6所示,也即目标视点信息对应光场相机121-a、121-b以及121-c的视点位置。For example, in an example, the position information of user B's eyes is mapped to the target viewpoint information in the light
S540、显示设备将目标视点信息发送至采集设备。S540. The display device sends the target viewpoint information to the collection device.
显示设备200将目标视点信息发送至采集设备100,以使采集设备100根据目标视点信息从多个光场相机中确定一个或多个目标光场相机。The
S550、采集设备100根据目标视点信息,从多个光场相机中确定一个或多个目标光场相机。S550. The
本公开实施方式中,结合图6所示,目标视点信息表示观察者眼睛在光场相机阵列120中的位置信息,从而采集设备100根据该目标视点信息,可以从光场相机阵列120中确定预设数量的目标光场相机。In the embodiments of the present disclosure, as shown in FIG. 6 , the target viewpoint information represents the position information of the observer's eyes in the light
可以理解,目标光场相机是指位于目标视点信息附近的光场相机,目标光场相机的数量可以根据具体场景进行选取,但是,目标光场相机的数量应当保证目标光场相机的视点位置能够覆盖目标视点信息的视点位置。从而,例如图6示例中,目标光场相机的数量可以设置为3个,3个目标光场相机即可覆盖用户双眼的视点。当然,本领域技术人员应当理解,目标光场相机的数量并不局限于3个,还可以是其他数量,本公开对此不再赘述。It can be understood that the target light field camera refers to the light field camera located near the target viewpoint information, the number of target light field cameras can be selected according to the specific scene, however, the number of target light field cameras should ensure that the viewpoint position of the target light field camera can Override the viewpoint position of the target viewpoint information. Therefore, for example, in the example shown in FIG. 6 , the number of target light field cameras can be set to three, and three target light field cameras can cover the viewpoints of both eyes of the user. Of course, those skilled in the art should understand that the number of target light field cameras is not limited to three, and may also be other numbers, which will not be repeated in this disclosure.
S560、采集设备通过目标光场相机采集光场图像得到光场图像组。S560. The collection device collects light field images through the target light field camera to obtain a light field image group.
采集设备100在确定目标光场相机之后,即可利用目标光场相机来采集当前的场景图像,得到每个目标光场相机采集到的光场图像,光场图像组即为每个目标光场相机采集的光场图像的集合。After the
在一些实施方式中,在目标光场相机在采集得到光场图像之后,还可以对各个光场图像进行预处理,预处理的目的是提高光场图像的精度,预处理例如可包括图像校准、畸变矫正等。In some implementations, after the target light field camera collects the light field images, preprocessing can also be performed on each light field image. The purpose of the preprocessing is to improve the accuracy of the light field image. The preprocessing can include, for example, image calibration, Distortion correction, etc.
本公开实施方式中,为了提高对光场图像的预处理速度,进一步保证实施性,可以采用多处理芯片的电路拓扑结构。例如图7示例中,Cam0~Cam8分别为光场相机阵列120中的光场相机,在电路拓扑中,可按照Cam0~Cam8的编号,依次将每3个相邻的光场相机编为一组,电路中共包括3个处理芯片,处理芯片Tx_0的输入端分别连接Cam0、Cam3和Cam6,处理芯片Tx_1的输入端分别连接Cam1、Cam4和Cam7,处理芯片Tx_2的输入端分别连接Cam2、Cam5和Cam8。In the embodiments of the present disclosure, in order to increase the preprocessing speed of the light field image and further ensure implementation, a circuit topology of a multi-processing chip may be used. For example, in the example shown in FIG. 7, Cam0-Cam8 are the light field cameras in the light
从而,通过图7所示的电路结构,对于任意相邻的3个目标光场相机,均可以保证一个处理芯片单独处理一路图像处理,实现光场图像数据的并行处理,提高图像预处理速度。Therefore, through the circuit structure shown in Figure 7, for any three adjacent target light field cameras, one processing chip can be guaranteed to process one image processing alone, realizing parallel processing of light field image data and improving image preprocessing speed.
S570、采集设备将光场图像组发送至显示设备。S570. The acquisition device sends the light field image group to the display device.
本公开实施方式中,采集设备100在对目标光场相机采集的光场图像进行预处理之后得到光场图像组,然后将光场图像组发送至显示设备200。In the embodiments of the present disclosure, the
通过上述可知,本公开实施方式中,基于用户当前的目标视点信息从光场相机阵列中确定目标光场相机进行光场图像采集,从而筛除冗余视点位置的光场图像,缩减视点图像合成的数据量,提高光场图像处理效率。From the above, it can be seen that in the embodiments of the present disclosure, based on the current target viewpoint information of the user, the target light field camera is determined from the light field camera array to collect light field images, so as to filter out the light field images of redundant viewpoint positions and reduce the synthesis of viewpoint images. The amount of data can improve the efficiency of light field image processing.
对于显示设备200端,其在接收到采集设备100发送的光场图像组之后,即可根据目标视点信息和光场图像组进行视点图像合成。通过前述可知,本公开实施方式中,将视点图像合成分为前景视点图像合成及背景视点图像合成,从而在显示设备200在得到光场图像组之后,首先需要对光场图像进行前景与背景的分割。在一些实施方式中,本公开示例的光场图像处理方法,包括:For the
对光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像和背景图像。Image segmentation is performed on each light field image in the light field image group to obtain a foreground image and a background image corresponding to each light field image.
可以理解,光场图像组中包括每个目标光场相机所采集的光场图像,例如图7示例中,显示设备200接收到的光场图像组中包括3张光场图像。It can be understood that the light field image group includes light field images collected by each target light field camera. For example, in the example of FIG. 7 , the light field image group received by the
然后,显示设备200可以对每张光场图像进行图像分割,图像分割的目的是从光场图像中分割出前景与背景。以视频通信场景为例,前景即为光场图像中的人物,背景即为除人物之外的其他图像部分。Then, the
本公开实施方式中,对于图像分割的具体算法不作限制,本领域技术人员可以采用相关技术中任意图像分割算法实现前景与背景的分割。但是,为了加快图像分割速度,本公开一些实施方式中,可以基于预先得到的背景图像进行图像分割。In the embodiments of the present disclosure, there is no limitation on the specific algorithm for image segmentation, and those skilled in the art can use any image segmentation algorithm in the related art to realize the segmentation of foreground and background. However, in order to speed up image segmentation, in some embodiments of the present disclosure, image segmentation may be performed based on a pre-obtained background image.
可以理解,结合图4实施方式可知,在采集设备100预先生成背景视差图的过程中,采集设备100所采集到的当前场景图像即为不包括人物的背景图像。换言之,前述S410中,采集设备100通过每个光场相机已经采集到每个视点位置的背景图像,该背景图像即为本公开所述的预设背景图像。It can be understood that, referring to the embodiment shown in FIG. 4 , in the process of pre-generating the background disparity map by the
从而在一些实施方式中,在S430中,在采集设备100向显示设备200发送背景视差图时,同时将每个光场相机采集到的各个视点位置的场景图像发送至显示设备200,显示设备200接收并存储这些场景图像,这些场景图像即作为本公开所述的预设背景图像。Therefore, in some implementations, in S430, when the
从而,在图像分割过程中,对于某个视点位置的光场图像,可以根据预先得到的该视点位置对应的预设背景图像,对光场图像进行图像差分,从而两者相同的图像位置即为背景区域,两者不同的图像位置即为前景区域,基于此原理可以快速实现对每个光场图像的前景与背景分割,提高图像分割速度。Therefore, in the process of image segmentation, for a light field image at a certain viewpoint position, image difference can be performed on the light field image according to the pre-obtained preset background image corresponding to the viewpoint position, so that the same image position of the two is The background area and the different image positions of the two are the foreground area. Based on this principle, the foreground and background segmentation of each light field image can be quickly realized, and the image segmentation speed can be improved.
通过上述过程对每个光场图像进行图像分割之后,即可得到每个光场图像所对应的前景图像及背景图像,然后基于前景图像和背景图像实现前景视点图像合成及背景视点图像合成,下面分别进行说明。After image segmentation of each light field image through the above process, the foreground image and background image corresponding to each light field image can be obtained, and then based on the foreground image and background image, the foreground viewpoint image synthesis and background viewpoint image synthesis are realized, as follows Described separately.
如图8所示,在一些实施方式中,本公开示例的光场图像处理方法,合成得到前景视点图像的过程,包括:As shown in FIG. 8 , in some implementations, the light field image processing method described in the present disclosure includes:
S810、对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,对第一光场图像对应的第一前景图像以及第二光场图像对应的第二前景图像进行视差估计,得到第一前景图像对应的第一前景视差图以及第二前景图像对应的第二前景视差图。S810. For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, the first foreground image corresponding to the first light field image and the second light field image corresponding to the second light field image Perform disparity estimation on the foreground image to obtain a first foreground disparity map corresponding to the first foreground image and a second foreground disparity map corresponding to the second foreground image.
S820、基于第一前景视差图对第一前景图像进行视差映射得到第一前景映射图,基于第二前景视差图对第二前景图像进行视差映射得到第二前景映射图。S820. Perform disparity mapping on the first foreground image based on the first foreground disparity map to obtain a first foreground map, and perform disparity mapping on the second foreground image based on the second foreground disparity map to obtain a second foreground map.
S830、基于目标视点信息对第一前景映射图和所述第二前景映射图进行图像融合处理,得到前景视点图像。S830. Perform image fusion processing on the first foreground map and the second foreground map based on the target viewpoint information to obtain a foreground viewpoint image.
值得说明的是,为实现视点图像的合成,首先需要计算得到相邻两个视点位置的图像的视差图,本公开实施方式中,将以其中任意相邻视点位置的两张光场图像为例,对两者前景视点图像及背景视点图像合成的过程进行说明。It is worth noting that in order to realize the synthesis of viewpoint images, it is first necessary to calculate the disparity maps of the images of two adjacent viewpoint positions. In the implementation of the present disclosure, two light field images of any adjacent viewpoint positions will be taken as an example , the process of synthesizing the two foreground viewpoint images and background viewpoint images will be described.
例如图7示例中,光场图像组共包括3张光场图像,分别为第一光场图像I1、第二光场图像I2和第三光场图像I3,其中,第一光场图像I1和第二光场图像I2为相邻视点位置的光场图像,第二光场图像I2与第三光场图像I3为相邻视点位置的光场图像。本公开下文实施方式中,将以第一光场图像I1和第二光场图像I2为例进行说明,而第二光场图像I2与第三光场图像I3参照相同的方法步骤即可,对此不再赘述。For example, in the example shown in Fig. 7, the light field image group includes three light field images in total, namely the first light field image I1, the second light field image I2 and the third light field image I3, wherein the first light field image I1 and The second light field image I2 is a light field image at an adjacent viewpoint position, and the second light field image I2 and the third light field image I3 are light field images at adjacent viewpoint positions. In the following embodiments of the present disclosure, the first light field image I1 and the second light field image I2 will be described as examples, and the second light field image I2 and the third light field image I3 can refer to the same method steps. This will not be repeated here.
结合前述可知,通过对第一光场图像I1进行图像分割可以得到第一光场图像I1对应的第一前景图像Ifore1和第一背景图像Iback1,同样,对第二光场图像I2进行图像分割可以得到第二光场图像I2对应的第二前景图像Ifore2和第二背景图像Iback2。In combination with the foregoing, it can be seen that by performing image segmentation on the first light field image I1, the first foreground image I fore 1 and the first background image I back 1 corresponding to the first light field image I1 can be obtained. Similarly, for the second light field image I2 Performing image segmentation can obtain a second foreground image I fore 2 and a second background image I back 2 corresponding to the second light field image I2.
对于前景视点图像合成,首先需要基于第一前景图像Ifore1和第二前景图像Ifore2确定视差图,下面结合图9进行说明。For foreground viewpoint image synthesis, it is first necessary to determine a disparity map based on the first foreground image I fore 1 and the second foreground image I fore 2, which will be described below with reference to FIG. 9 .
如图9所示,在一些实施方式中,本公开示例的光场图像处理方法,得到第一前景视差图和第二前景视差图的过程,包括:As shown in FIG. 9 , in some implementations, the process of obtaining the first foreground disparity map and the second foreground disparity map in the light field image processing method of the example of the present disclosure includes:
S811、基于预设降采样系数对第一前景图像进行降采样得到第一降采样图,对第二前景图像进行降采样得到第二降采样图。S811. Perform down-sampling on the first foreground image based on a preset down-sampling coefficient to obtain a first down-sampled image, and perform down-sampling on the second foreground image to obtain a second down-sampled image.
值得说明的是,本公开实施方式中,考虑到光场图像的原图尺度较大,若是基于原图尺度进行视差图估计,数据量较大,因此可以对原图尺度的前景图像进行降采样,从而缩小图像尺寸,缩减数据量,进而提高运算速度。It is worth noting that, in the embodiments of the present disclosure, considering that the scale of the original image of the light field image is large, if the disparity map is estimated based on the scale of the original image, the amount of data is large, so the foreground image of the scale of the original image can be down-sampled , so as to reduce the size of the image, reduce the amount of data, and improve the operation speed.
参见图10所示,首先可以将原图尺度的第一前景图像Ifore1进行降采样得到第一降采样图Ifore1’,同样将原图尺度的第二前景图像Ifore2进行降采样得到第二降采样图Ifore2’。Referring to Fig. 10, firstly, the first foreground image I fore 1 of the original image scale can be down-sampled to obtain the first down-sampled image I fore 1', and the second foreground image I fore 2 of the original image scale can also be down-sampled A second downsampled image I fore 2' is obtained.
值得说明的是,预设降采样系数是指图像缩小的倍率,该系数可以根据具体场景进行设置,图像缩小倍率越大运算速度越来同时精度越高,图像缩小倍率越小运算速度越慢同时精度越高,基于此规律,在一个示例中,预设降采样系数可以选择1/4、1/8、1/16等。It is worth noting that the preset downsampling factor refers to the magnification of image reduction. This factor can be set according to specific scenarios. The larger the image magnification, the faster the calculation speed and the higher the accuracy. The smaller the image magnification, the slower the calculation speed. The higher the accuracy, based on this rule, in an example, the preset downsampling coefficient can be selected as 1/4, 1/8, 1/16, etc.
S812、对第一降采样图和第二降采样图上相同像素的位置进行匹配,得到第一降采样图对应的第一视差图,以及第二降采样图对应的第二视差图。S812. Match the positions of the same pixels on the first downsampled image and the second downsampled image to obtain a first disparity map corresponding to the first downsampled image and a second disparity map corresponding to the second downsampled image.
本公开实施方式中,在对第一前景图像Ifore1和第二前景图像Ifore2进行降采样之后,即可基于降采样之后的第一降采样图Ifore1’和第二降采样图Ifore2’进行视差估计,视差估计的基本原理是针对图像上相同像素的位置进行匹配,从而确定像素偏移的距离,也即视差图上的像素值即表示像素偏移距离。In the embodiment of the present disclosure, after downsampling the first foreground image I fore 1 and the second foreground image I fore 2, the first downsampled image I fore 1' and the second downsampled image after downsampling can be used I fore 2' performs disparity estimation. The basic principle of disparity estimation is to match the position of the same pixel on the image to determine the pixel offset distance, that is, the pixel value on the disparity map represents the pixel offset distance.
以第一前景图像Ifore1为例,第一前景图像Ifore1对应的第一视差图Iforepara1’即表示第一前景图像Ifore1上的某个像素相对于第二前景图像Ifore2上相同像素的偏移距离。Taking the first foreground image I fore 1 as an example, the first disparity map I forepara 1' corresponding to the first foreground image I fore 1 means that a certain pixel on the first foreground image I fore 1 is relative to the second foreground image I fore The offset distance of the same pixel on 2.
从而,通过上述像素匹配的过程即可实现视差估计,得到第一前景图像Ifore1对应的第一视差图Iforepara1’,以及第二前景图像Ifore2对应的第二视差图Iforepara2’。第一视差图Iforepara1’和第二视差图Iforepara2’可如图10所示。Therefore, the parallax estimation can be realized through the above pixel matching process, and the first parallax map I forepara 1' corresponding to the first foreground image I fore 1, and the second parallax map I forepara 2 corresponding to the second foreground image I fore 2 are obtained. '. The first disparity map I forepara 1' and the second disparity map I forepara 2' may be shown in FIG. 10 .
S813、根据第一视差图和预设降采样系数确定第一视差搜索范围,根据第二视差图和预设降采样系数确定第二视差搜索范围。S813. Determine a first disparity search range according to the first disparity map and a preset downsampling coefficient, and determine a second disparity search range according to the second disparity map and a preset downsampling coefficient.
结合图10可知,第一视差图Iforepara1’和第二视差图Iforepara2’的图像尺度与降采样后的图像尺度相同,因此需要将第一视差图Iforepara1’和第二视差图Iforepara2’恢复至原图尺度。It can be seen from FIG. 10 that the image scales of the first parallax map I forepara 1' and the second parallax map I forepara 2' are the same as the downsampled image scale, so it is necessary to combine the first parallax map I forepara 1' and the second parallax map I forepara 2'revert to the original scale.
以第一视差图Iforepara1’为例,可以理解,由于第一视差图Iforepara1’尺度较小,因此第一视差图Iforepara1’上的每个像素对应值原图上一个范围,本公开实施方式中,可以将第一视差图Iforepara1’进行分块,以图像块为单位,确定每个图像块的对应像素的视差搜索范围(min’,max’),该视差搜索范围(min’,max’)表示该图像块对应至原图尺寸上的像素范围,视差搜索范围的具体数值可以结合图像块像素值的最大值和最小值确定。Taking the first parallax map I forepara 1' as an example, it can be understood that since the scale of the first parallax map I forepara 1' is small, each pixel on the first parallax map I forepara 1' corresponds to a range on the original image. In the embodiment of the present disclosure, the first disparity map I forepara 1' can be divided into blocks, and the disparity search range (min', max') of the corresponding pixels of each image block is determined in units of image blocks. The disparity search range (min', max') indicates that the image block corresponds to the pixel range on the size of the original image, and the specific value of the disparity search range can be determined in combination with the maximum and minimum values of the pixel values of the image block.
然后,将该视差搜索范围(min’,max’)恢复至原图尺度,也即,对视差搜索范围(min’,max’)的最小值和最大值乘以预设采样系数的倒数,得到第一视差搜索范围(min,max),第一视差搜索范围(min,max)即表示在原图尺度上的视差搜索范围。同理,根据上述过程对第二视差图Iforepara2’进行处理即可得到第二视差搜索范围。Then, the disparity search range (min', max') is restored to the scale of the original image, that is, the minimum and maximum values of the disparity search range (min', max') are multiplied by the reciprocal of the preset sampling coefficient to obtain The first disparity search range (min, max), the first disparity search range (min, max) means the disparity search range on the scale of the original image. Similarly, the second parallax search range can be obtained by processing the second parallax map I forepara 2' according to the above process.
S814、基于第一视差搜索范围对第一前景图像进行视差估计得到第一前景视差图,基于第二视差搜索范围对第二前景图像进行视差估计得到第二前景视差图。S814. Perform disparity estimation on the first foreground image based on the first disparity search range to obtain a first foreground disparity map, and perform disparity estimation on the second foreground image based on the second disparity search range to obtain a second foreground disparity map.
本公开实施方式中,以第一前景图像Ifore1为例,在通过前述得到第一视差搜索范围(min,max)之后,该第一视差搜索范围表示对第一前景图像Ifore1和第二前景图像Ifore2上相同像素进行匹配的搜索范围,从而基于该第一视差搜索范围对第一前景图像Ifore1进行视差估计,即可得到第一前景图像Ifore1对应的第一前景视差图Iforepara1。同理,基于第二视差搜索范围对第二前景图像Ifore2进行视差估计,即可得到第二前景图像Ifore2对应的第二前景视差图Iforepara2。In the embodiments of the present disclosure, taking the first foreground image I fore 1 as an example, after the first disparity search range (min, max) is obtained through the foregoing, the first disparity search range represents the comparison between the first foreground image I fore 1 and the first foreground image The search range for matching the same pixels on the two foreground images I fore 2, so that the first foreground image I fore 1 is subjected to parallax estimation based on the first disparity search range, and the first foreground corresponding to the first foreground image I fore 1 can be obtained
通过上述可知,本公开实施方式中,通过对前景图像进行降采样后进行视差估计,可以有效缩减数据量,提高图像处理效率,满足视频通信场景的实时性要求。From the above, it can be seen that in the embodiments of the present disclosure, by performing disparity estimation after down-sampling the foreground image, the amount of data can be effectively reduced, the image processing efficiency can be improved, and the real-time requirement of the video communication scene can be met.
本公开实施方式中,在分别得到第一前景图像Ifore1和第二前景图像Ifore2对应的第一前景视差图Iforepara1和第二前景视差图Iforepara2之后,即可根据前景视差图对前景图像进行视点合成,得到新视点位置的前景视点图像,下面结合图10进行说明。In the embodiment of the present disclosure, after obtaining the first foreground parallax map I forepara 1 and the second foreground parallax map I forepara 2 corresponding to the first foreground image I fore 1 and the second foreground image I fore 2 respectively, the foreground parallax Figure 10 performs viewpoint synthesis on the foreground image to obtain a foreground viewpoint image at a new viewpoint position, which will be described below with reference to FIG. 10 .
如图11所示,在一些实施方式中,本公开示例的光场图像处理方法,得到前景视点图像的过程,包括:As shown in FIG. 11 , in some implementations, the light field image processing method described in the present disclosure includes:
S1110、根据第一前景视差图将第一前景图像上的每个像素匹配至映射图上的对应像素位置,得到第一前景映射图;根据第二前景视差图将第二前景图像上的每个像素匹配至映射图上的对应像素位置,得到第二前景映射图。S1110. Match each pixel on the first foreground image to the corresponding pixel position on the map according to the first foreground disparity map to obtain the first foreground map; match each pixel on the second foreground image according to the second foreground disparity map Pixels are matched to corresponding pixel positions on the map to obtain a second foreground map.
结合前述可知,视差图是反映由于视点位置差异带来像素位置偏移的图像,视差图上的每个像素表示原图上该位置像素的视差值,以第一前景视差图Iforepara1和第二前景视差图Iforepara2为例,在忽略计算误差的情况下,第一前景图像Ifore1上的像素坐标加上第一前景视差图Iforepara1上的视差值即为第二前景图像Ifore2上的像素坐标,同理,第二前景图像Ifore2上的像素坐标加上第二前景视差图Iforepara2上的视差值即为第一前景图像Ifore1上的像素坐标。In combination with the foregoing, it can be seen that the disparity map is an image that reflects the pixel position offset due to the difference in viewpoint position, and each pixel on the disparity map represents the disparity value of the pixel at the position on the original image. The first foreground disparity map I forepara 1 and Take the second foreground disparity map I forepara 2 as an example. In the case of ignoring the calculation error, the pixel coordinates on the first foreground image I fore 1 plus the disparity value on the first foreground disparity map I forepara 1 are the second foreground The pixel coordinates on the image I fore 2, likewise, the pixel coordinates on the second foreground image I fore 2 plus the parallax value on the second foreground disparity map I forepara 2 is the pixel on the first foreground image I fore 1 coordinate.
因此,在得到第一前景视差图Iforepara1和第二前景视差图Iforepara2之后,即可根据第一前景视差图Iforepara1和第二前景视差图Iforepara2对第一前景图像Ifore1和第二前景图像Ifore2进行像素偏移处理,该像素偏移处理过程即为像素坐标映射过程。在对第一前景图像Ifore1映射处理之后,即可得到第一前景映射图Iforemap1,对第二前景图像Ifore2映射处理之后,即可得到第一前景映射图Iforemap2。Therefore, after obtaining the first foreground parallax map I forepara 1 and the second foreground parallax map I forepara 2, the first foreground image I fore can be processed according to the first foreground parallax map I forepara 1 and the second foreground parallax map I forepara 2 1 and the second foreground image I fore 2 are subjected to pixel offset processing, and the pixel offset processing process is the pixel coordinate mapping process. After the first foreground image I fore 1 is mapped, the first foreground map I foremap 1 can be obtained, and after the second foreground image I fore 2 is mapped, the first foreground map I foremap 2 can be obtained.
以第一前景映射图Iforemap1为例,可以根据第一前景视差图Iforepara1上的视差值,对第一前景图像Ifore1上的每个像素进行偏移处理,从而得到在第一前景映射图Iforemap1上的像素位置,完成从第一前景图像Ifore1到第一前景映射图Iforemap1的像素偏移处理,得到第一前景映射图Iforemap1。同理,以同样的过程根据第二前景视差图Iforepara2对第二前景图像Ifore2进行映射处理,即可得到对应的第二前景映射图Iforemap2。Taking the first foreground map I foremap 1 as an example, each pixel on the first foreground image I fore 1 can be offset according to the disparity value on the first foreground disparity map I forepara 1, so as to obtain A pixel position on the foreground map I foremap 1, complete the pixel offset processing from the first foreground image I fore 1 to the first foreground map I foremap 1, and obtain the first
值得说明的是,在对第一前景图像Ifore1和第二前景图像Ifore2进行映射处理之前,还可以对第一前景视差图Iforepara1和第二前景视差图Iforepara2进行一致性校验,一致性校验的目的是对第一前景视差图Iforepara1和第二前景视差图Iforepara2进行修正,以提高视差图的精度。对于一致性校验的过程,本领域技术人员参照相关技术即可,本公开对此不再赘述。It is worth noting that, before performing the mapping process on the first foreground image I fore 1 and the second foreground image I fore 2, the first foreground parallax map I forepara 1 and the second foreground parallax map I forepara 2 can also be consistent Verification, the purpose of consistency verification is to correct the first foreground disparity map I forepara 1 and the second foreground disparity map I forepara 2, so as to improve the accuracy of the disparity map. For the consistency verification process, those skilled in the art may refer to related technologies, which will not be repeated in this disclosure.
S1120、根据目标视点信息与任意两个相邻的目标光场相机的位置信息,确定第一权值和第二权值。S1120. Determine a first weight and a second weight according to the target viewpoint information and the position information of any two adjacent target light field cameras.
S1130、基于第一权值和第二权值,对第一前景映射图和第二前景映射图进行图像融合处理,得到前景视点图像。S1130. Based on the first weight and the second weight, perform image fusion processing on the first foreground map and the second foreground map to obtain a foreground viewpoint image.
结合前述可知,目标视点信息是指用户当前的新视点位置,需要结合该目标视点信息对第一前景映射图Iforemap1和第二前景映射图Iforemap2进行视点图像合成,从而得到在用户新视点位置下的前景视点图像。In combination with the foregoing, it can be seen that the target viewpoint information refers to the user's current new viewpoint position, and it is necessary to combine the target viewpoint information to perform viewpoint image synthesis on the first foreground map I foremap 1 and the second foreground map I foremap 2, so as to obtain the user's new The foreground viewpoint image at the viewpoint position.
在对第一前景映射图Iforemap1和第二前景映射图Iforemap2进行视点图像合成时,首先需要确定第一前景映射图Iforemap1和第二前景映射图Iforemap2的权值,该权值表示第一前景映射图Iforemap1和第二前景映射图Iforemap2的融合系数。When performing viewpoint image synthesis on the first foreground map I foremap 1 and the second foreground map I foremap 2, it is first necessary to determine the weights of the first foreground map I foremap 1 and the second foreground map I foremap 2, the The weight represents the fusion coefficient of the first foreground map I foremap 1 and the second
可以理解,第一前景映射图Iforemap1对应一个目标光场相机的视点位置,第二前景映射图Iforemap2对应另一个目标光场相机的视点位置,而目标视点信息所对应的视点位置,可能出现在两者之间的任意位置,新视点位置距离目标光场相机的视点位置不同,所对应的权值大小也应当不同。It can be understood that the first foreground map I foremap 1 corresponds to the viewpoint position of a target light field camera, the second foreground map I foremap 2 corresponds to the viewpoint position of another target light field camera, and the viewpoint position corresponding to the target viewpoint information, It may appear at any position between the two. The new viewpoint position is different from the viewpoint position of the target light field camera, and the corresponding weights should also be different.
基于此原理,本公开实施方式中,可以根据目标视点信息与左右两个目标光场相机的位置信息,确定针对左右两个前景映射图的融合系数,也即第一权值和第二权值。例如,目标视点信息距离第一前景映射图Iforemap1的视点位置更近,则第一前景映射图Iforemap1对应的第一权值w1更大;反之,若目标视点信息距离第二前景映射图Iforemap2的视点位置更近,则第二前景映射图Iforemap2对应的第二权值w2更大。据此本领域技术人员可以结合目标视点信息确定第一权值w1和第二权值w2的具体数值,本公开对此不作限制。Based on this principle, in the embodiments of the present disclosure, the fusion coefficients for the left and right foreground maps, that is, the first weight and the second weight, can be determined according to the target viewpoint information and the position information of the left and right target light field cameras . For example, if the target viewpoint information is closer to the viewpoint position of the first foreground map I foremap 1, the first weight w1 corresponding to the first foreground map I foremap 1 is larger; otherwise, if the target viewpoint information is farther away from the second foreground map The viewpoint position of the graph I foremap 2 is closer, and the second weight value w2 corresponding to the second foreground map graph I foremap 2 is larger. Accordingly, those skilled in the art may determine specific values of the first weight w1 and the second weight w2 in combination with the target viewpoint information, which is not limited in the present disclosure.
在根据目标视点信息确定第一权值w1和第二权值w2之后,即可根据第一权值w1和第二权值w2对第一前景映射图Iforemap1和第二前景映射图Iforemap2进行融合处理,融合处理的过程可表示为:After determining the first weight w1 and the second weight w2 according to the target viewpoint information, the first foreground map I foremap 1 and the second foreground map I foremap can be calculated according to the first weight w1 and the
P = w1* Iforemap1+ w2* Iforemap2 (1)P = w1* I foremap 1+ w2* I foremap 2 (1)
公式(1)中,P表示融合处理之后得到的前景视点图像。通过上述过程,对第一前景图像Ifore1和第二前景图像Ifore2结合目标视点信息进行视点图像合成,得到对应新视点位置下的前景视点图像P。In formula (1), P represents the foreground viewpoint image obtained after fusion processing. Through the above process, the first foreground image I fore 1 and the second foreground image I fore 2 are combined with the target viewpoint information to perform viewpoint image synthesis to obtain the foreground viewpoint image P corresponding to the new viewpoint position.
如图12所示,在一些实施方式中,本公开示例的光场图像处理方法,合成得到背景视点图像的过程,包括:As shown in FIG. 12 , in some implementations, the light field image processing method described in the present disclosure includes:
S1210、对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,基于预先生成的与第一光场图像相同视点位置的第一背景视差图,对第一光场图像的第一背景图像进行视差映射得到第一背景映射图,基于预先生成的与第二光场图像相同视点位置的第二背景视差图,对第二光场图像的第二背景图像进行视差映射得到第二背景映射图。S1210. For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, based on the pre-generated first background disparity map at the same viewpoint position as the first light field image, perform the second light field image Perform parallax mapping on the first background image of a light field image to obtain the first background map, and based on the pre-generated second background parallax map at the same viewpoint position as the second light field image, the second background image of the second light field image Perform parallax mapping to obtain a second background map.
S1220、基于目标视点信息对第一背景映射图和第二背景映射图进行图像融合处理,得到背景视点图像。S1220. Perform image fusion processing on the first background map and the second background map based on the target viewpoint information to obtain a background viewpoint image.
对于背景视点图像的合成,仍以光场图像组中的相邻视点位置的第一光场图像I1和第二光场图像I2为例,前述通过图像分割得到了第一光场图像I1的第一背景图像Iback1,以及第二光场图像I2的第二背景图像Iback2。For the synthesis of background viewpoint images, still take the first light field image I1 and the second light field image I2 of adjacent viewpoint positions in the light field image group as an example, the first light field image I1 obtained through image segmentation A background image I back 1, and a second background image I back 2 of the second light field image I2.
在对第一背景图像Iback1和第二背景图像Iback2进行背景视点图像合成时,无需像前景视点图像合成过程中计算前景视差图,这是由于通过前述图4实施方式,已经在离线阶段预先生成了每个视点位置的背景视差图,从而无需在线计算。When performing background viewpoint image synthesis on the first background image I back 1 and the second background image I back 2, there is no need to calculate the foreground disparity map in the process of foreground viewpoint image synthesis, because through the implementation of the aforementioned Figure 4, the offline stage pre-generates the background disparity map for each viewpoint location, eliminating the need for online computation.
因此,对于背景视点图像合成,首先可根据第一背景图像Iback1的视点位置,从背景视差图中确定与之相同视点位置的第一背景视差图Ibackpara1,同理,根据第二背景图像Iback2的视点位置,从背景视差图中确定与之相同视点位置的第二背景视差图Ibackpara2。Therefore, for background viewpoint image synthesis, firstly, according to the viewpoint position of the first background image I back 1, the first background disparity map I backpara 1 with the same viewpoint position can be determined from the background disparity map. Similarly, according to the second background image I backpara 1 For the viewpoint position of the image I back 2, a second background disparity map I backpara 2 with the same viewpoint position is determined from the background disparity map.
在确定背景视差图之后,即可结合目标视点信息的新视点位置对第一背景图像Iback1和第二背景图像Iback2进行背景视点图像合成,其和过程与前述的前景视点图像合成原理相同,下面仅进行简述。After the background disparity map is determined, the first background image I back 1 and the second background image I back 2 can be synthesized by combining the new viewpoint position of the target viewpoint information, and the sum process is the same as the aforementioned foreground viewpoint image synthesis principle The same, only briefly described below.
首先,可以根据第一背景视差图Ibackpara1上的视差值,对第一背景图像Iback1上的每个像素进行偏移处理,该偏移处理的过程即为针对像素坐标的映射过程,从而得到在第一背景映射图Ibackmap1上的像素位置,完成从第一背景图像Iback1到第一背景映射图Ibackmap1的像素偏移处理,得到第一背景映射图Ibackmap1。同理,以同样的过程根据第二背景视差图Ibackpara2对第二背景图像Iback2进行映射处理,即可得到对应的第二背景映射图Ibackmap2。First, each pixel on the first background image I back 1 can be shifted according to the parallax value on the first background parallax map I backpara 1, and the process of the shift processing is the mapping process for pixel coordinates , so as to obtain the pixel position on the first background map I backmap 1, complete the pixel offset processing from the first background image I back 1 to the first background map I backmap 1, and obtain the first
值得说明的是,在对第一背景图像Iback1和第二背景图像Iback2进行映射处理之前,还可以对第一背景视差图Ibackpara1和第二背景视差图Ibackpara2进行一致性校验,一致性校验的目的是对第一背景视差图Ibackpara1和第二背景视差图Ibackpara2进行修正,以提高视差图的精度。对于一致性校验的过程,本领域技术人员参照相关技术即可,本公开对此不再赘述。It is worth noting that, before performing mapping processing on the first background image I back 1 and the second background image I back 2, the first background parallax map I backpara 1 and the second background parallax map I backpara 2 can also be consistent Verification, the purpose of the consistency verification is to correct the first background parallax map I backpara 1 and the second background parallax map I backpara 2, so as to improve the accuracy of the parallax map. For the consistency verification process, those skilled in the art may refer to related technologies, which will not be repeated in this disclosure.
然后,可以根据目标视点信息与左右两个目标光场相机的位置信息,确定针对左右两个背景映射图的融合系数,该融合系数也即前述的第一权值w1和第二权值w2,对此不再赘述。之后即可根据第一权值w1和第二权值w2对第一背景映射图Ibackmap1和第二背景映射图Ibackmap2进行融合处理,融合处理的过程可表示为:Then, according to the target viewpoint information and the position information of the left and right target light field cameras, the fusion coefficients for the left and right background maps can be determined, and the fusion coefficients are also the aforementioned first weight w1 and second weight w2, I won't repeat it here. After that, the first background map I backmap 1 and the second background map I backmap 2 can be fused according to the first weight w1 and the second weight w2, and the fusion process can be expressed as:
Q = w1* Ibackmap1+ w2* Ibackmap2 (2)Q = w1* I backmap 1+ w2* I backmap 2 (2)
公式(2)中,Q表示融合处理之后得到的背景视点图像。通过上述过程,对第一背景图像Iback1和第二背景图像Iback2结合目标视点信息进行视点图像合成,得到对应新视点位置下的背景视点图像Q。In formula (2), Q represents the background viewpoint image obtained after fusion processing. Through the above process, the viewpoint image synthesis is performed on the first background image I back 1 and the second background image I back 2 combined with the target viewpoint information to obtain the background viewpoint image Q corresponding to the new viewpoint position.
通过上述过程得到了前景视点图像P和背景视点图像Q,然后对前景视点图像P和背景视点图像Q进行融合处理,例如将背景视点图像Q贴在前景视点图像P上,即可得到最终对应新视点位置的目标光场图像。上述仅以第一光场图像I1与第二光场图像I2之间的视点图像合成进行了说明,对于其他任意相邻两个光场图像之间的视点图像合成过程与之相同,依次参照执行即可得到用户目标视点信息包括的每个视点位置下的目标光场图像,本公开对此不再赘述。Through the above process, the foreground viewpoint image P and the background viewpoint image Q are obtained, and then the foreground viewpoint image P and the background viewpoint image Q are fused, for example, the background viewpoint image Q is pasted on the foreground viewpoint image P to obtain the final corresponding new The target light field image at the viewpoint position. The above description is only based on the viewpoint image synthesis between the first light field image I1 and the second light field image I2. The viewpoint image synthesis process between any other two adjacent light field images is the same. The target light field image at each viewpoint position included in the user's target viewpoint information can then be obtained, which will not be described in detail in this disclosure.
在得到一张或多张目标光场图像之后,即可在显示设备200的显示屏110上渲染展示目标光场图像,对于图像渲染展示的过程,本领域参照相关技术即可理解,本公开不再赘述。After obtaining one or more target light field images, the target light field images can be rendered and displayed on the
通过上述可知,本公开实施方式中,通过前背景分割的方式,预先生成背景图像的视差图,从而无需实时计算针对复杂背景的视差图,大大缩减视点图像合成的数据量,提高图像处理速度和精度,可以实现实时光场视频通信。并且,在对前景视差图计算过程中,基于降采样小图进行视差估计,进一步缩减计算量,提高数据处理速度。另外,通过目标视点信息从光场相机阵列中选取目标光场相机,筛除大量冗余数据的采集、传输、处理的操作,进一步提高图像处理速度,实现低延时实施视频通信。From the above, it can be seen that in the embodiments of the present disclosure, the disparity map of the background image is generated in advance through the method of foreground and background segmentation, so that there is no need to calculate the disparity map for the complex background in real time, greatly reducing the amount of data for viewpoint image synthesis, and improving image processing speed and Accuracy, real-time light field video communication can be realized. Moreover, in the process of calculating the foreground disparity map, the disparity estimation is performed based on the downsampled small image, which further reduces the calculation amount and improves the data processing speed. In addition, the target light field camera is selected from the light field camera array through the target viewpoint information, and the operation of collecting, transmitting, and processing a large amount of redundant data is eliminated, the image processing speed is further improved, and low-latency video communication is realized.
在一些实施方式中,本公开提供了一种光场图像处理装置,该装置可应用于显示设备200,参见图13所示,本公开示例的光场图像处理装置包括:In some implementations, the present disclosure provides a light field image processing device, which can be applied to a
获取模块10,被配置为获取目标视点信息以及由采集设备发送的光场图像组;目标视点信息表示显示设备的观察者眼睛的位置信息,光场图像组包括采集设备中每个目标光场相机所采集的光场图像;The
前景融合模块20,被配置为基于目标视点信息对各个光场图像中的前景图像进行视点融合,得到目标视点信息所对应的前景视点图像;The
背景融合模块30,被配置为基于目标视点信息以及预先生成的每个视点位置的背景视差图,对各个光场图像中的背景图像进行视点融合,得到目标视点信息所对应的背景视点图像;视点位置表示与每个目标光场相机相对应的位置;The
图像合成模块40,被配置为根据前景视点图像和背景视点图像生成目标光场图像。The
在一些实施方式中,前景融合模块20被配置为:In some embodiments, the
对光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的前景图像;performing image segmentation on each light field image in the light field image group to obtain a foreground image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,对第一光场图像对应的第一前景图像以及第二光场图像对应的第二前景图像进行视差估计,得到第一前景图像对应的第一前景视差图以及第二前景图像对应的第二前景视差图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, the first foreground image corresponding to the first light field image and the second foreground image corresponding to the second light field image Perform parallax estimation to obtain a first foreground parallax map corresponding to the first foreground image and a second foreground parallax map corresponding to the second foreground image;
基于第一前景视差图对第一前景图像进行视差映射得到第一前景映射图,基于第二前景视差图对第二前景图像进行视差映射得到第二前景映射图;performing parallax mapping on the first foreground image based on the first foreground disparity map to obtain a first foreground map, and performing parallax mapping on the second foreground image based on the second foreground disparity map to obtain a second foreground map;
基于目标视点信息对第一前景映射图和第二前景映射图进行图像融合处理,得到前景视点图像。Image fusion processing is performed on the first foreground map and the second foreground map based on the target viewpoint information to obtain a foreground viewpoint image.
在一些实施方式中,前景融合模块20被配置为:In some embodiments, the
对于光场图像组中的每个光场图像,基于预先生成的与光场图像相同视点位置的预设背景图像,对光场图像进行图像差分,得到光场图像对应的前景图像和背景图像。For each light field image in the light field image group, based on a pre-generated preset background image at the same viewpoint position as the light field image, image difference is performed on the light field image to obtain a foreground image and a background image corresponding to the light field image.
在一些实施方式中,前景融合模块20被配置为:In some embodiments, the
基于预设降采样系数对第一前景图像进行降采样得到第一降采样图,对第二前景图像进行降采样得到第二降采样图;downsampling the first foreground image based on a preset downsampling coefficient to obtain a first downsampling image, and downsampling the second foreground image to obtain a second downsampling image;
对第一降采样图和第二降采样图上相同像素的位置进行匹配,得到第一降采样图对应的第一视差图,以及第二降采样图对应的第二视差图;Matching the positions of the same pixels on the first downsampled image and the second downsampled image to obtain a first disparity map corresponding to the first downsampled image and a second disparity map corresponding to the second downsampled image;
根据第一视差图和预设降采样系数确定第一视差搜索范围,根据第二视差图和预设降采样系数确定第二视差搜索范围;determining a first disparity search range according to the first disparity map and a preset downsampling coefficient, and determining a second disparity search range according to the second disparity map and a preset downsampling coefficient;
基于第一视差搜索范围对第一前景图像进行视差估计得到第一前景视差图,基于第二视差搜索范围对第二前景图像进行视差估计得到第二前景视差图。Performing disparity estimation on the first foreground image based on the first disparity search range to obtain a first foreground disparity map, and performing disparity estimation on the second foreground image based on the second disparity search range to obtain a second foreground disparity map.
在一些实施方式中,前景融合模块20被配置为:In some embodiments, the
根据第一前景视差图将第一前景图像上的每个像素匹配至映射图上的对应像素位置,得到第一前景映射图;根据第二前景视差图将第二前景图像上的每个像素匹配至映射图上的对应像素位置,得到第二前景映射图;Match each pixel on the first foreground image to the corresponding pixel position on the map according to the first foreground disparity map to obtain the first foreground map; match each pixel on the second foreground image according to the second foreground disparity map to the corresponding pixel position on the map to obtain the second foreground map;
根据目标视点信息与任意两个相邻的目标光场相机的位置信息,确定第一权值和第二权值;determining the first weight and the second weight according to the target viewpoint information and the position information of any two adjacent target light field cameras;
基于第一权值和第二权值,对第一前景映射图和第二前景映射图进行图像融合处理,得到前景视点图像。Based on the first weight and the second weight, image fusion processing is performed on the first foreground map and the second foreground map to obtain a foreground viewpoint image.
在一些实施方式中,背景融合模块30被配置为:In some embodiments, the
对光场图像组中的每个光场图像进行图像分割,得到每个光场图像对应的背景图像;Image segmentation is performed on each light field image in the light field image group to obtain a background image corresponding to each light field image;
对于任意两个相邻的目标光场相机所对应的第一光场图像和第二光场图像,基于预先生成的与第一光场图像相同视点位置的第一背景视差图,对第一光场图像的第一背景图像进行视差映射得到第一背景映射图,基于预先生成的与第二光场图像相同视点位置的第二背景视差图,对第二光场图像的第二背景图像进行视差映射得到第二背景映射图;For the first light field image and the second light field image corresponding to any two adjacent target light field cameras, based on the pre-generated first background disparity map at the same viewpoint position as the first light field image, the first light field Perform parallax mapping on the first background image of the field image to obtain the first background map, and perform parallax on the second background image of the second light field image based on the pre-generated second background parallax map at the same viewpoint position as the second light field image Mapping to obtain a second background map;
基于目标视点信息对第一背景映射图和第二背景映射图进行图像融合处理,得到背景视点图像。Image fusion processing is performed on the first background map and the second background map based on the target viewpoint information to obtain a background viewpoint image.
在一些实施方式中,获取模块10被配置为:In some embodiments, the
通过设于显示设备上的图像采集装置采集场景图像;Acquiring scene images through an image acquisition device arranged on the display device;
根据场景图像进行图像检测,得到场景图像中观察者眼睛的位置信息;Perform image detection based on the scene image to obtain the position information of the observer's eyes in the scene image;
基于位置信息生成目标视点信息。Target viewpoint information is generated based on the position information.
在一些实施方式中,获取模块10被配置为:In some embodiments, the
将目标视点信息发送至采集设备,以使采集设备根据目标视点信息从多个光场相机中确定一个或多个目标光场相机;sending the target viewpoint information to the acquisition device, so that the acquisition device determines one or more target light field cameras from multiple light field cameras according to the target viewpoint information;
接收采集设备发送的光场图像组。Receive the light field image group sent by the acquisition device.
在一些实施方式中,获取模块10被配置为:In some embodiments, the
接收采集设备发送的每个视点位置的背景视差图并存储。The background disparity map of each viewpoint position sent by the acquisition device is received and stored.
通过上述可知,本公开实施方式中,通过前背景分割的方式,预先生成背景图像的视差图,从而无需实时计算针对复杂背景的视差图,大大缩减视点图像合成的数据量,提高图像处理速度和精度,可以实现实时光场视频通信。并且,在对前景视差图计算过程中,基于降采样小图进行视差估计,进一步缩减计算量,提高数据处理速度。另外,通过目标视点信息从光场相机阵列中选取目标光场相机,筛除大量冗余数据的采集、传输、处理的操作,进一步提高图像处理速度,实现低延时实施视频通信。From the above, it can be seen that in the embodiments of the present disclosure, the disparity map of the background image is generated in advance through the method of foreground and background segmentation, so that there is no need to calculate the disparity map for the complex background in real time, greatly reducing the amount of data for viewpoint image synthesis, and improving image processing speed and Accuracy, real-time light field video communication can be realized. Moreover, in the process of calculating the foreground disparity map, the disparity estimation is performed based on the downsampled small image, which further reduces the calculation amount and improves the data processing speed. In addition, the target light field camera is selected from the light field camera array through the target viewpoint information, and the operation of collecting, transmitting, and processing a large amount of redundant data is eliminated, the image processing speed is further improved, and low-latency video communication is realized.
在一些实施方式中,本公开提供了一种光场图像处理装置,该装置可应用于采集设备100,参见图14所示,本公开示例的光场图像处理装置包括:In some implementations, the present disclosure provides a light field image processing device, which can be applied to the
图像采集模块50,被配置为通过设于采集设备上的多个光场相机分别采集当前场景图像,得到每个光场相机对应的视点位置的场景图像;The
视差确定模块60,被配置为对于任意相邻的两个光场相机,根据两个光场相机分别采集的场景图像,生成每个光场相机的视点位置的背景视差图;The
发送模块70,被配置为将每个视点位置的背景视差图发送至显示设备,以使显示设备存储每个视点位置的背景视差图。The sending
在一些实施方式中,发送模块70被配置为:In some implementations, the sending
接收显示设备发送的目标视点信息;Receive the target viewpoint information sent by the display device;
根据目标视点信息,从采集设备包括的多个光场相机中确定一个或多个目标光场相机;Determining one or more target light field cameras from multiple light field cameras included in the acquisition device according to the target viewpoint information;
通过目标光场相机采集光场图像得到光场图像组,并将光场图像组发送至显示设备。The light field image is collected by the target light field camera to obtain a light field image group, and the light field image group is sent to a display device.
通过上述可知,本公开实施方式中,通过前背景分割的方式,预先生成背景图像的视差图,从而无需实时计算针对复杂背景的视差图,大大缩减视点图像合成的数据量,提高图像处理速度和精度,可以实现实时光场视频通信。并且,在对前景视差图计算过程中,基于降采样小图进行视差估计,进一步缩减计算量,提高数据处理速度。另外,通过目标视点信息从光场相机阵列中选取目标光场相机,筛除大量冗余数据的采集、传输、处理的操作,进一步提高图像处理速度,实现低延时实施视频通信。From the above, it can be seen that in the embodiments of the present disclosure, the disparity map of the background image is generated in advance through the method of foreground and background segmentation, so that there is no need to calculate the disparity map for the complex background in real time, greatly reducing the amount of data for viewpoint image synthesis, and improving image processing speed and Accuracy, real-time light field video communication can be realized. Moreover, in the process of calculating the foreground disparity map, the disparity estimation is performed based on the downsampled small image, which further reduces the calculation amount and improves the data processing speed. In addition, the target light field camera is selected from the light field camera array through the target viewpoint information, and the operation of collecting, transmitting, and processing a large amount of redundant data is eliminated, the image processing speed is further improved, and low-latency video communication is realized.
在一些实施方式中,本公开提供了一种视频通信系统,视频通信系统可如图1所示,其包括:In some implementations, the present disclosure provides a video communication system. The video communication system may be as shown in FIG. 1 , which includes:
显示设备200,包括图像采集装置和第一控制器,第一控制器用于执行上述任意实施方式的方法;The
采集设备100,包括光场相机阵列和第二控制器,光场相机阵列包括多个光场相机,第二控制器用于执行上述任意实施方式的方法;The
在一些实施方式中,本公开提供了一种存储介质,存储有计算机指令,计算机指令用于使计算机执行上述任意实施方式的方法。In some implementations, the present disclosure provides a storage medium storing computer instructions for causing a computer to execute the method in any of the above implementations.
在一些实施方式中,本公开提供了一种电子设备,包括:In some embodiments, the present disclosure provides an electronic device comprising:
处理器;和processor; and
存储器,存储有计算机指令,计算机指令用于使处理器执行上述任意实施方式的方法。The memory stores computer instructions, and the computer instructions are used to cause the processor to execute the method in any of the above implementation manners.
本公开实施方式中,电子设备既可以是上述的采集设备100,也可以是显示设备200,本公开对此不作限制。具体而言,图15示出了适于用来实现本公开方法的电子设备600的结构示意图,通过图15所示电子设备,可实现上述处理器、控制器及存储介质相应功能。In the embodiments of the present disclosure, the electronic device may be the above-mentioned
如图15所示,电子设备600包括处理器601,其可以根据存储在存储器602中的程序或者从存储部分608加载到存储器602中的程序而执行各种适当的动作和处理。在存储器602中,还存储有电子设备600操作所需的各种程序和数据。处理器601和存储器602通过总线604彼此相连。输入/输出(I/O)接口605也连接至总线604。As shown in FIG. 15 , the
以下部件连接至I/O接口605:包括键盘、鼠标等的输入部分606;包括诸如阴极射线管(CRT)、液晶显示器(LCD)等以及扬声器等的输出部分607;包括硬盘等的存储部分608;以及包括诸如LAN卡、调制解调器等的网络接口卡的通信部分609。通信部分609经由诸如因特网的网络执行通信处理。驱动器610也根据需要连接至I/O接口605。可拆卸介质611,诸如磁盘、光盘、磁光盘、半导体存储器等等,根据需要安装在驱动器610上,以便于从其上读出的计算机程序根据需要被安装入存储部分608。The following components are connected to the I/O interface 605: an
特别地,根据本公开的实施方式,上文方法过程可以被实现为计算机软件程序。例如,本公开的实施方式包括一种计算机程序产品,其包括有形地包含在机器可读介质上的计算机程序,计算机程序包含用于执行上述方法的程序代码。在这样的实施方式中,该计算机程序可以通过通信部分609从网络上被下载和安装,和/或从可拆卸介质611被安装。In particular, according to the embodiments of the present disclosure, the above method process can be implemented as a computer software program. For example, embodiments of the present disclosure include a computer program product comprising a computer program tangibly embodied on a machine-readable medium, the computer program comprising program code for performing the method described above. In such an embodiment, the computer program may be downloaded and installed from a network via the
附图中的流程图和框图,图示了按照本公开各种实施方式的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。The flowchart and block diagrams in the Figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in a flowchart or block diagram may represent a module, program segment, or part of code that contains one or more Executable instructions. It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or they may sometimes be executed in the reverse order, depending upon the functionality involved. It should also be noted that each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented by a dedicated hardware-based system that performs the specified functions or operations , or may be implemented by a combination of dedicated hardware and computer instructions.
显然,上述实施方式仅仅是为清楚地说明所作的举例,而并非对实施方式的限定。对于所属领域的普通技术人员来说,在上述说明的基础上还可以做出其它不同形式的变化或变动。这里无需也无法对所有的实施方式予以穷举。而由此所引伸出的显而易见的变化或变动仍处于本公开创造的保护范围之中。Apparently, the above-mentioned implementation manners are only examples for clear description, rather than limiting the implementation manners. For those of ordinary skill in the art, other changes or changes in different forms can be made on the basis of the above description. It is not necessary and impossible to exhaustively list all the implementation manners here. And the obvious changes or changes derived therefrom are still within the scope of protection of the present disclosure.
Claims (16)
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310410075.6A CN116402878A (en) | 2023-04-17 | 2023-04-17 | Light field image processing method and device |
| PCT/CN2024/081563 WO2024217194A1 (en) | 2023-04-17 | 2024-03-14 | Light-field image processing method and apparatus |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310410075.6A CN116402878A (en) | 2023-04-17 | 2023-04-17 | Light field image processing method and device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN116402878A true CN116402878A (en) | 2023-07-07 |
Family
ID=87015775
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202310410075.6A Pending CN116402878A (en) | 2023-04-17 | 2023-04-17 | Light field image processing method and device |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN116402878A (en) |
| WO (1) | WO2024217194A1 (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2024217194A1 (en) * | 2023-04-17 | 2024-10-24 | 京东方科技集团股份有限公司 | Light-field image processing method and apparatus |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2000057350A (en) * | 1998-08-10 | 2000-02-25 | Toshiba Corp | Image processing apparatus and method and image transmitting apparatus and method |
| CN104537667A (en) * | 2014-12-27 | 2015-04-22 | 西安电子科技大学 | Image cutting method based on direction multi-target genetic clustering algorithm |
| CN107071383A (en) * | 2017-02-28 | 2017-08-18 | 北京大学深圳研究生院 | The virtual visual point synthesizing method split based on image local |
| WO2019142794A1 (en) * | 2018-01-22 | 2019-07-25 | シャープ株式会社 | Image generating device, display processing device, image reproducing system, image generating method, control program, and recording medium |
Family Cites Families (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101714293A (en) * | 2009-12-16 | 2010-05-26 | 上海交通投资信息科技有限公司 | Stereoscopic vision based acquisition method of congestion degree of bus passenger flow |
| CN104537668B (en) * | 2014-12-29 | 2017-08-15 | 浙江宇视科技有限公司 | A kind of quick parallax image computational methods and device |
| CN111064945B (en) * | 2019-12-26 | 2021-07-16 | 和信光场(深圳)科技有限公司 | Naked eye 3D image acquisition and generation method |
| CN116402878A (en) * | 2023-04-17 | 2023-07-07 | 京东方科技集团股份有限公司 | Light field image processing method and device |
-
2023
- 2023-04-17 CN CN202310410075.6A patent/CN116402878A/en active Pending
-
2024
- 2024-03-14 WO PCT/CN2024/081563 patent/WO2024217194A1/en not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2000057350A (en) * | 1998-08-10 | 2000-02-25 | Toshiba Corp | Image processing apparatus and method and image transmitting apparatus and method |
| CN104537667A (en) * | 2014-12-27 | 2015-04-22 | 西安电子科技大学 | Image cutting method based on direction multi-target genetic clustering algorithm |
| CN107071383A (en) * | 2017-02-28 | 2017-08-18 | 北京大学深圳研究生院 | The virtual visual point synthesizing method split based on image local |
| WO2019142794A1 (en) * | 2018-01-22 | 2019-07-25 | シャープ株式会社 | Image generating device, display processing device, image reproducing system, image generating method, control program, and recording medium |
Non-Patent Citations (1)
| Title |
|---|
| 一度逍遥: "真实场景的虚拟视点合成(View Synthsis)详解", 《HTTPS://WWW.CNBLOGS.COM/RIDDICK/P/8511960.HTML》, 7 March 2018 (2018-03-07), pages 1 - 6 * |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2024217194A1 (en) * | 2023-04-17 | 2024-10-24 | 京东方科技集团股份有限公司 | Light-field image processing method and apparatus |
Also Published As
| Publication number | Publication date |
|---|---|
| WO2024217194A1 (en) | 2024-10-24 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US11960639B2 (en) | Virtual 3D methods, systems and software | |
| JP7804725B2 (en) | Neural Blending for Novel View Synthesis | |
| EP2328125B1 (en) | Image splicing method and device | |
| US11451758B1 (en) | Systems, methods, and media for colorizing grayscale images | |
| US20080158340A1 (en) | Video chat apparatus and method | |
| EP3660663B1 (en) | Delivering virtualized content | |
| JPWO2018047687A1 (en) | Three-dimensional model generation device and three-dimensional model generation method | |
| CN112207821B (en) | Target searching method and robot of visual robot | |
| JP7184748B2 (en) | A method for generating layered depth data for a scene | |
| CN106997579B (en) | Image splicing method and device | |
| CN107578435A (en) | A method and device for image depth prediction | |
| US20230122149A1 (en) | Asymmetric communication system with viewer position indications | |
| WO2018188277A1 (en) | Sight correction method and device, intelligent conference terminal and storage medium | |
| CN112233165A (en) | A Baseline Extension Implementation Method Based on Multi-plane Image Learning Perspective Synthesis | |
| US9380263B2 (en) | Systems and methods for real-time view-synthesis in a multi-camera setup | |
| KR101933037B1 (en) | Apparatus for reproducing 360 degrees video images for virtual reality | |
| US11758101B2 (en) | Restoration of the FOV of images for stereoscopic rendering | |
| WO2020184174A1 (en) | Image processing device and image processing method | |
| Zhou et al. | Single-view view synthesis with self-rectified pseudo-stereo | |
| Mulligan et al. | Stereo-based environment scanning for immersive telepresence | |
| WO2024217194A1 (en) | Light-field image processing method and apparatus | |
| CN119365892A (en) | Depth estimation for SLAM systems using a monocular camera | |
| CN114339120A (en) | Immersive video conference system | |
| CN113793420A (en) | Depth information processing method and device, electronic equipment and storage medium | |
| US20250218109A1 (en) | Rendering Videos with Novel Views from Near-Duplicate Photos |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination |