技术领域Technical Field
本发明涉及图像处理技术领域,特别是涉及一种基于视差的裸眼3D显示方法及系统。The present invention relates to the field of image processing technology, and in particular to a parallax-based naked-eye 3D display method and system.
背景技术Background technique
我们所处的物理世界是一个三维空间,人类在进化过程中发展出了与环境相适应的双目成像视觉系统,实现在三维世界中物体的立体空间感知。人类一般可以通过视觉、嗅觉、听觉等多种方式感知物理世界,其中视觉占人类感知到的信息总量的80%以上。19世纪早期,人们就开始创造立体影像,到20世纪中期,影片制作人开始使用特殊的双目摄影技术来拍摄电影,并在电影放映时配合使用特殊的3D眼镜来呈现逼真的3D效果。近年来,随着计算机技术和电视技术的飞速发展,3D技术也得到了进一步的发展和应用。例如,人们已经能够使用3D打印技术制作出逼真的3D模型和物体,使用裸眼3D技术实现不需要佩戴眼镜的3D电视,以及在虚拟现实和增强现实技术中应用3D图像和效果。其中,3D影院技术往往是使用双目特摄等技术拍出两个视角的画面,对应人的左右眼,再合成一部3D电影,影院配备3D放映系统,包括3D放映机、3D屏幕、3D眼镜等;而裸眼3D显示器技术是通过自适应光栅技术实现2D图像转换成3D图像,对光线传输进行控制,使每个像素点只向左眼或右眼发送光线。The physical world we live in is a three-dimensional space. In the process of evolution, humans have developed a binocular imaging vision system that adapts to the environment to achieve three-dimensional spatial perception of objects in the three-dimensional world. Humans can generally perceive the physical world through vision, smell, hearing and other means, of which vision accounts for more than 80% of the total information perceived by humans. In the early 19th century, people began to create stereoscopic images. By the mid-20th century, filmmakers began to use special binocular photography technology to shoot movies and use special 3D glasses to present realistic 3D effects when showing movies. In recent years, with the rapid development of computer technology and television technology, 3D technology has also been further developed and applied. For example, people have been able to use 3D printing technology to produce realistic 3D models and objects, use naked-eye 3D technology to achieve 3D TVs that do not require glasses, and apply 3D images and effects in virtual reality and augmented reality technologies. Among them, 3D cinema technology often uses binocular special photography and other technologies to shoot two perspectives of the picture, corresponding to the left and right eyes of the person, and then synthesizes a 3D movie. The cinema is equipped with a 3D projection system, including a 3D projector, 3D screen, 3D glasses, etc.; while the naked-eye 3D display technology uses adaptive grating technology to convert 2D images into 3D images, and controls the transmission of light so that each pixel only sends light to the left eye or the right eye.
然而,传统的裸眼3D技术,需要在特定角度特定角度下实现3D效果,这会带来一定的不便,需在观看时选择适当的位置和角度,才能获得最佳的视觉体验。因此,传统的裸眼3D技术存在裸眼深度感知效果较差的问题。However, traditional naked-eye 3D technology requires a specific angle to achieve the 3D effect, which brings certain inconveniences. It is necessary to choose the appropriate position and angle when watching to get the best visual experience. Therefore, traditional naked-eye 3D technology has the problem of poor naked-eye depth perception.
发明内容Summary of the invention
基于此,为了解决上述技术问题,提供一种基于视差的裸眼3D显示方法及系统,可以提高裸眼对物体的深度分辨能力,实现裸眼深度感知的效果。Based on this, in order to solve the above technical problems, a parallax-based naked-eye 3D display method and system are provided, which can improve the naked eye's depth resolution ability for objects and achieve the effect of naked-eye depth perception.
一种基于视差的裸眼3D显示方法,所述方法包括:A parallax-based naked-eye 3D display method, the method comprising:
获取左右视图,并根据双目视觉立体原理计算出所述左右视图之间的距离差异,得到视差图;Obtaining left and right views, and calculating the distance difference between the left and right views according to the binocular vision stereo principle to obtain a disparity map;
根据所述视差图计算得到深度信息,并根据所述深度信息对所述视差图中的物体进行色彩处理,得到颜色分布图;Calculating depth information according to the disparity map, and performing color processing on the object in the disparity map according to the depth information to obtain a color distribution map;
使用图像分割技术对所述颜色分布图进行处理,将所述颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓;Using image segmentation technology to process the color distribution map, connect the contours of objects in the color distribution map, and mark the contours of closed objects;
根据所述封闭物体轮廓,对所述视差图进行三维色彩处理,并将处理后的视差图赋予在所述左右视图上。According to the closed object outline, the disparity map is subjected to three-dimensional color processing, and the processed disparity map is assigned to the left and right views.
在其中一个实施例中,所述根据双目视觉立体原理计算出所述左右视图之间的距离差异,得到视差图,包括:In one embodiment, the distance difference between the left and right views is calculated according to the binocular vision stereo principle to obtain a disparity map, including:
确定所述左右视图中同一物体的像素位置;Determining pixel positions of the same object in the left and right views;
根据双目视觉立体原理,通过所述像素位置对同一物体进行视差计算,得到视差图。According to the binocular vision stereo principle, the disparity of the same object is calculated through the pixel positions to obtain a disparity map.
在其中一个实施例中,所述根据所述深度信息对所述视差图中的物体进行色彩处理,得到颜色分布图,包括:In one of the embodiments, performing color processing on the object in the disparity map according to the depth information to obtain a color distribution map includes:
确定所述视差图中物体的各个连续颜色分布区域;Determining each continuous color distribution area of the object in the disparity map;
根据所述深度信息将各个所述连续颜色分布区域转换成不同深度的分离颜色,得到颜色分布图。Each of the continuous color distribution areas is converted into separated colors of different depths according to the depth information to obtain a color distribution map.
在其中一个实施例中,所述使用图像分割技术对所述颜色分布图进行处理,将所述颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓,包括:In one embodiment, the color distribution map is processed using image segmentation technology to connect the contours of objects in the color distribution map and mark the closed object contours, including:
根据所述颜色分布图,将不同深度的分离颜色分别进行轮廓连通,标注出封闭物体轮廓;According to the color distribution map, the separated colors at different depths are connected in outline respectively, and the outline of the closed object is marked;
基于所述封闭物体轮廓将不同深度的物体进行分割。Objects at different depths are segmented based on the closed object contours.
在其中一个实施例中,所述获取左右视图,包括:In one embodiment, obtaining the left and right views includes:
利用无人机设备拍摄左右视图,并通过所述无人机设备获取所述左右视图。The left and right views are photographed by using a drone device, and the left and right views are acquired by the drone device.
一种基于视差的裸眼3D显示系统,所述系统包括:A parallax-based naked-eye 3D display system, the system comprising:
视差图获取模块,用于获取左右视图,并根据双目视觉立体原理计算出所述左右视图之间的距离差异,得到视差图;A disparity map acquisition module is used to acquire left and right views, and calculate the distance difference between the left and right views according to the binocular vision stereo principle to obtain a disparity map;
色彩处理模块,用于根据所述视差图计算得到深度信息,并根据所述深度信息对所述视差图中的物体进行色彩处理,得到颜色分布图;A color processing module, used to calculate depth information according to the disparity map, and perform color processing on the object in the disparity map according to the depth information to obtain a color distribution map;
图像分割模块,用于使用图像分割技术对所述颜色分布图进行处理,将所述颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓;An image segmentation module, used to process the color distribution map using image segmentation technology, connect the contours of objects in the color distribution map, and mark the contours of closed objects;
三维处理模块,用于根据所述封闭物体轮廓,对所述视差图进行三维色彩处理,并将处理后的视差图赋予在所述左右视图上。The three-dimensional processing module is used to perform three-dimensional color processing on the disparity map according to the closed object outline, and assign the processed disparity map to the left and right views.
上述基于视差的裸眼3D显示方法及系统,根据双目视觉立体原理得到视差图,再通过深度信息对视差图进行色彩处理、图像分割,从而进行三维色彩处理,可以提高裸眼对物体的深度分辨能力,优化要素的整体分割效率,加强图片的深度信息并实现裸眼的深度感知。The above-mentioned parallax-based naked-eye 3D display method and system obtains a parallax map according to the stereoscopic principle of binocular vision, and then performs color processing and image segmentation on the parallax map through depth information, thereby performing three-dimensional color processing. It can improve the naked eye's depth resolution ability for objects, optimize the overall segmentation efficiency of elements, enhance the depth information of the picture and realize the naked eye's depth perception.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
图1为一个实施例中基于视差的裸眼3D显示方法的应用环境图;FIG1 is a diagram showing an application environment of a parallax-based naked-eye 3D display method in one embodiment;
图2为一个实施例中基于视差的裸眼3D显示方法的流程示意图;FIG2 is a schematic flow chart of a parallax-based naked-eye 3D display method in one embodiment;
图3为一个实施例中基于视差的裸眼3D显示方法的图像变化示意图;FIG3 is a schematic diagram of image changes in a parallax-based naked-eye 3D display method in one embodiment;
图4为一个实施例中基于视差的裸眼3D显示系统的结构框图;FIG4 is a structural block diagram of a parallax-based naked-eye 3D display system in one embodiment;
图5为一个实施例中计算机设备的内部结构图。FIG. 5 is a diagram showing the internal structure of a computer device in one embodiment.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
本申请实施例提供的基于视差的裸眼3D显示方法,可以应用于如图1所示的应用环境中。如图1所示,该应用环境包括计算机设备110。计算机设备110可以获取左右视图,并根据双目视觉立体原理计算出左右视图之间的距离差异,得到视差图;计算机设备110可以根据视差图计算得到深度信息,并根据深度信息对视差图中的物体进行色彩处理,得到颜色分布图;计算机设备110可以使用图像分割技术对颜色分布图进行处理,将颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓;计算机设备110可以根据封闭物体轮廓,对视差图进行三维色彩处理,并将处理后的视差图赋予在左右视图上。其中,计算机设备110可以但不限于是各种个人计算机、笔记本电脑、智能手机、机器人、无人飞行器、平板电脑等设备。The parallax-based naked-eye 3D display method provided in the embodiment of the present application can be applied to the application environment shown in FIG. 1. As shown in FIG. 1, the application environment includes a computer device 110. The computer device 110 can obtain the left and right views, and calculate the distance difference between the left and right views according to the binocular vision stereo principle to obtain a disparity map; the computer device 110 can calculate the depth information according to the disparity map, and perform color processing on the objects in the disparity map according to the depth information to obtain a color distribution map; the computer device 110 can use image segmentation technology to process the color distribution map, connect the contours of the objects in the color distribution map, and mark the closed object contours; the computer device 110 can perform three-dimensional color processing on the disparity map according to the closed object contour, and assign the processed disparity map to the left and right views. Among them, the computer device 110 can be, but is not limited to, various personal computers, laptops, smart phones, robots, unmanned aerial vehicles, tablet computers and other devices.
在一个实施例中,如图2所示,提供了一种基于视差的裸眼3D显示方法,包括以下步骤:In one embodiment, as shown in FIG2 , a parallax-based naked-eye 3D display method is provided, comprising the following steps:
步骤202,获取左右视图,并根据双目视觉立体原理计算出左右视图之间的距离差异,得到视差图。Step 202 , obtain the left and right views, and calculate the distance difference between the left and right views according to the binocular vision stereo principle to obtain a disparity map.
计算机设备可以获取到左右视图,对应人眼的左眼和右眼所看到的图像。接着,计算机设备可以根据双目立体原理计算出左右视图之间的距离差异,从而获取最为合适的左右视图,得到视差图。The computer device can obtain the left and right views, corresponding to the images seen by the left and right eyes of the human eye. Then, the computer device can calculate the distance difference between the left and right views based on the binocular stereo principle, thereby obtaining the most appropriate left and right views and obtaining a disparity map.
步骤204,根据视差图计算得到深度信息,并根据深度信息对视差图中的物体进行色彩处理,得到颜色分布图。Step 204 , depth information is calculated according to the disparity map, and color processing is performed on the objects in the disparity map according to the depth information to obtain a color distribution map.
深度信息可以用于表示视差图中各个物体到图像采集设备之间的距离信息。通过视差图计算深度信息,可以获取到视差图中各个物体分别到图像采集设备之间的距离。Depth information can be used to represent the distance information between each object in the disparity map and the image acquisition device. By calculating the depth information through the disparity map, the distance between each object in the disparity map and the image acquisition device can be obtained.
计算机设备可以根据深度信息对视差图中的物体进行色彩处理。具体的,计算机设备可以根据深度信息,对视差图中的不用距离的物体分配不同的颜色,例如距离越近的物体颜色越深,距离越远的物体颜色越浅,从而得到颜色分布图。The computer device can perform color processing on the objects in the disparity map according to the depth information. Specifically, the computer device can assign different colors to objects at different distances in the disparity map according to the depth information, for example, the closer the object, the darker the color, and the farther the object, the lighter the color, thereby obtaining a color distribution map.
步骤206,使用图像分割技术对颜色分布图进行处理,将颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓。Step 206, using image segmentation technology to process the color distribution map, connect the contours of the objects in the color distribution map, and mark the closed object contours.
其中,图像分割技术可以对图像中的同一类物体实现分割操作。在本实施例中,计算机设备可以使用图像分割技术对颜色分布图进行处理,具体根据颜色分布图中属于同一颜色的物体进行轮廓连通,得到封闭的物体轮廓并标注,便于进一步处理。The image segmentation technology can implement segmentation operations on objects of the same type in the image. In this embodiment, the computer device can use the image segmentation technology to process the color distribution map, specifically connecting the contours of objects of the same color in the color distribution map, obtaining closed object contours and marking them for further processing.
步骤208,根据封闭物体轮廓,对视差图进行三维色彩处理,并将处理后的视差图赋予在左右视图上。Step 208 , performing three-dimensional color processing on the disparity map according to the closed object outline, and assigning the processed disparity map to the left and right views.
同一封闭物体轮廓属于同一颜色、拥有相同的深度信息,计算机设备可以根据封闭物体轮廓对视差图进行三维色彩处理,通过融合左右视图,从而得到裸眼3D图像。The outline of the same closed object has the same color and the same depth information. The computer device can perform three-dimensional color processing on the disparity map according to the outline of the closed object, and obtain a naked-eye 3D image by fusing the left and right views.
具体的,计算机设备可以根据封闭物体轮廓赋予原灰度图的像素强度并用不同颜色区分,使得图片具备第三个维度;利用分立的颜色分布和封闭物体轮廓,将原灰度图赋予对应的视差图,根据不同物体的深度信息确定颜色,距离观察者距离越近颜色则越鲜艳,通过这种方式,实现深度感知的视觉效果,并使得不同物体的深度信息更加清晰和明显,从而提升观赏体验。Specifically, the computer device can assign pixel intensity to the original grayscale image according to the outline of the closed object and distinguish it with different colors, so that the image has a third dimension; using the discrete color distribution and the outline of the closed object, the original grayscale image is assigned a corresponding disparity map, and the color is determined according to the depth information of different objects. The closer the distance to the observer, the brighter the color. In this way, the visual effect of depth perception is achieved, and the depth information of different objects is made clearer and obvious, thereby enhancing the viewing experience.
在本实施例中,计算机设备根据双目视觉立体原理得到视差图,再通过深度信息对视差图进行色彩处理、图像分割,从而进行三维色彩处理,可以提高裸眼对物体的深度分辨能力,优化要素的整体分割效率,加强图片的深度信息并实现裸眼的深度感知。本实施例中提供的一种基于视差的裸眼3D显示方法,首次利用双视角的视差颜色分布对图片要素进行整体分割,再根据分割结果原本在图片中的深度进行不同颜色的赋值,现有的裸眼3D显示器技术需要利用光栅技术以及对观看者的观看视角有所要求,本实施例只需观看赋色后的图片从而实现裸眼深度感知的效果。In this embodiment, the computer device obtains a disparity map based on the binocular vision stereo principle, and then performs color processing and image segmentation on the disparity map through depth information, thereby performing three-dimensional color processing, which can improve the naked eye's depth resolution ability for objects, optimize the overall segmentation efficiency of elements, enhance the depth information of the picture and realize the depth perception of the naked eye. A parallax-based naked eye 3D display method provided in this embodiment first uses the parallax color distribution of dual-viewing angles to segment the picture elements as a whole, and then assigns different colors according to the original depth in the picture of the segmentation result. The existing naked eye 3D display technology requires the use of grating technology and has certain requirements on the viewing angle of the viewer. In this embodiment, only the colored picture needs to be viewed to achieve the effect of naked eye depth perception.
在一个实施例中,提供的一种基于视差的裸眼3D显示方法还可以包括计算左右视图差异得到视差图的过程,具体过程包括:确定左右视图中同一物体的像素位置;根据双目视觉立体原理,通过像素位置对同一物体进行视差计算,得到视差图。In one embodiment, a parallax-based naked-eye 3D display method provided may also include a process of calculating the difference between left and right views to obtain a parallax map, the specific process including: determining the pixel position of the same object in the left and right views; and calculating the parallax of the same object through the pixel position according to the binocular vision stereo principle to obtain a parallax map.
计算机设备可以对左右视图中的物体进行识别,并对同一物体进行标记。接着,计算机设备可以确定左右视图中同一物体的像素位置,根据双目视觉立体原理计算出同一物体的像素位置差别,从而计算差异距离,得到视差图。具体的,计算机设备可以基于得到的左右视图,进行视差估计,即计算左右视图中不同物体之间的差异,通过对视差的计算,得到视差图,从而更加精准地测量不同物体之间的距离差异。The computer device can identify objects in the left and right views and mark the same object. Then, the computer device can determine the pixel position of the same object in the left and right views, calculate the difference in pixel position of the same object based on the binocular vision stereo principle, and thus calculate the difference distance to obtain a disparity map. Specifically, the computer device can perform disparity estimation based on the obtained left and right views, that is, calculate the difference between different objects in the left and right views, and obtain a disparity map by calculating the disparity, thereby more accurately measuring the distance difference between different objects.
在一个实施例中,提供的一种基于视差的裸眼3D显示方法还可以包括进行色彩处理的过程,具体过程包括:确定视差图中物体的各个连续颜色分布区域;根据深度信息将各个连续颜色分布区域转换成不同深度的分离颜色,得到颜色分布图。In one embodiment, a parallax-based naked-eye 3D display method provided may also include a color processing process, the specific process including: determining each continuous color distribution area of the object in the parallax map; converting each continuous color distribution area into separated colors of different depths according to depth information to obtain a color distribution map.
计算机设备可以对视差图中的颜色分布做出改变。具体的,计算机设备可以确定视差图中物体的各个连续颜色分布区域,将连续的颜色分布转换成不同深度的分离颜色,以便更好地对图片要素进行整体分割和区分。通过将颜色分布离散化,更加准确地判断图片中不同物体的深度层次,进而实现更好的深度分辨。The computer device can make changes to the color distribution in the disparity map. Specifically, the computer device can determine the continuous color distribution areas of the objects in the disparity map, and convert the continuous color distribution into separated colors of different depths, so as to better segment and distinguish the image elements as a whole. By discretizing the color distribution, the depth levels of different objects in the image can be more accurately judged, thereby achieving better depth resolution.
在一个实施例中,提供的一种基于视差的裸眼3D显示方法还可以包括进行图像分割的过程,具体过程包括:根据颜色分布图,将不同深度的分离颜色分别进行轮廓连通,标注出封闭物体轮廓;基于封闭物体轮廓将不同深度的物体进行分割。In one embodiment, a parallax-based naked-eye 3D display method provided may also include a process of image segmentation, the specific process including: according to a color distribution map, connecting the separated colors of different depths with contours respectively, marking the contours of closed objects; and segmenting objects of different depths based on the contours of closed objects.
由于遮挡、对比度不足等原因,部分像素视差估计出现错误,导致包含有深度信息的颜色分布图很可能出现噪点。计算机设备可以基于视差的差异,计算深度划分相应的深度层次,划分不同的物体元素,进一步去掉小连通区域,精细划分图像上的元素,获取封闭的轮廓,得到完整平滑的深度层,即将不同深度的分离颜色分别进行轮廓连通,标注出封闭物体轮廓。其中,不同的轮廓连通域不仅代表不同的图像要素,同时也是不同深度层的体现。Due to occlusion, insufficient contrast and other reasons, some pixel disparity estimation errors occur, resulting in the possibility of noise in the color distribution map containing depth information. Computer equipment can calculate the depth based on the difference in disparity, divide the corresponding depth level, divide different object elements, further remove small connected areas, finely divide the elements on the image, obtain closed contours, and obtain a complete and smooth depth layer, that is, connect the separated colors of different depths with contours, and mark the closed object contours. Among them, different contour connected domains not only represent different image elements, but also reflect different depth layers.
在视差图的颜色分布离散化后,通过应用图像分割技术,根据分立的颜色分布图得到封闭的物体轮廓;基于这些轮廓,进一步对图片要素进行分割,实现对不同深度物体的准确区分。封闭的轮廓能够避免出现漏分割或者误分割等问题,使得深度感知效果更加准确。After the color distribution of the disparity map is discretized, the image segmentation technology is applied to obtain the closed object contours according to the discrete color distribution map; based on these contours, the image elements are further segmented to achieve accurate distinction of objects at different depths. Closed contours can avoid problems such as missed segmentation or mis-segmentation, making the depth perception effect more accurate.
采用轮廓提取技术并基于深度信息进行色彩分配,使得不同深度的物体呈现出不同的颜色,从而在视觉上形成层次感,实现裸眼深度感知;双视角的视差颜色分布保证了能有效的对图片要素整体分割。By using contour extraction technology and allocating colors based on depth information, objects at different depths appear in different colors, thus forming a sense of layering visually and realizing naked eye depth perception; the dual-perspective parallax color distribution ensures that the overall image elements can be effectively segmented.
在一个实施例中,提供的一种基于视差的裸眼3D显示方法还可以包括获取左右视图的过程,具体过程包括:利用无人机设备拍摄左右视图,并通过无人机设备获取左右视图。In one embodiment, a parallax-based naked-eye 3D display method is provided that may further include a process of acquiring left and right views, and the specific process includes: using a drone device to shoot left and right views, and acquiring the left and right views through the drone device.
在一个实施例中,提供的一种基于视差的裸眼3D显示方法中,图像的处理变化过程如图3所示,计算机设备可以利用无人机航拍获取F1左视图,F2右视图,其中,F1左视图对应人眼的左眼所看到的图像,F2右视图对应人眼的右眼所看到的图像;In one embodiment, in a parallax-based naked-eye 3D display method, the image processing change process is shown in FIG3 , and the computer device can use drone aerial photography to obtain F1 left view and F2 right view, wherein F1 left view corresponds to the image seen by the left eye of the human eye, and F2 right view corresponds to the image seen by the right eye of the human eye;
接着,计算机设备可以根据双目视觉立体原理,计算出无人机拍摄左右视图之间的距离差异,即基于航拍得到的左右视图,进行视差估计,即计算左右视图中不同物体之间的差异,通过对视差的计算,得到视差图;Next, the computer device can calculate the distance difference between the left and right views taken by the drone based on the principle of binocular vision stereo, that is, based on the left and right views obtained by aerial photography, perform disparity estimation, that is, calculate the difference between different objects in the left and right views, and obtain a disparity map by calculating the disparity;
计算机设备可以对视差图中的颜色分布做出改变,将连续的颜色分布转换成不同深度的分离颜色,将颜色分布离散化,以便更好地对图片要素进行整体分割和区分;The computer device can change the color distribution in the disparity map, convert the continuous color distribution into separated colors of different depths, and discretize the color distribution to better segment and distinguish the image elements as a whole;
在视差图的颜色分布离散化后,计算机设备可以通过应用图像分割技术,根据分立的颜色分布图得到封闭的物体轮廓;基于这些轮廓,进一步对图片要素进行分割,实现对不同深度物体的准确区分;After the color distribution of the disparity map is discretized, the computer device can obtain the closed object contours according to the discrete color distribution map by applying image segmentation technology; based on these contours, the image elements are further segmented to achieve accurate distinction of objects at different depths;
计算机设备可以根据连通域赋予原灰度图的像素强度并用不同颜色区分,使得图片具备第三个维度;利用分立的颜色分布和封闭的轮廓,将原灰度图赋予对应的视差图,根据不同物体的深度信息确定颜色,距离观察者距离越近颜色则越鲜艳。Computer equipment can assign pixel intensity to the original grayscale image based on the connected domain and distinguish them with different colors, giving the image a third dimension; using discrete color distribution and closed contours, the original grayscale image is assigned a corresponding disparity map, and the color is determined based on the depth information of different objects. The closer the distance to the observer, the brighter the color.
应该理解的是,虽然上述流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,上述流程图中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the various steps in the above-mentioned flow chart are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the above-mentioned flow chart may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
在一个实施例中,如图4所示,提供了一种基于视差的裸眼3D显示系统,包括:视差图获取模块410、色彩处理模块420、图像分割模块430和三维处理模块440,其中:In one embodiment, as shown in FIG. 4 , a parallax-based naked-eye 3D display system is provided, comprising: a parallax map acquisition module 410, a color processing module 420, an image segmentation module 430 and a three-dimensional processing module 440, wherein:
视差图获取模块410,用于获取左右视图,并根据双目视觉立体原理计算出左右视图之间的距离差异,得到视差图;The disparity map acquisition module 410 is used to acquire the left and right views, and calculate the distance difference between the left and right views according to the binocular vision stereo principle to obtain a disparity map;
色彩处理模块420,用于根据视差图计算得到深度信息,并根据深度信息对视差图中的物体进行色彩处理,得到颜色分布图;A color processing module 420 is used to calculate depth information according to the disparity map, and perform color processing on the objects in the disparity map according to the depth information to obtain a color distribution map;
图像分割模块430,用于使用图像分割技术对颜色分布图进行处理,将颜色分布图中的物体进行轮廓连通,标注出封闭物体轮廓;An image segmentation module 430 is used to process the color distribution map using image segmentation technology, connect the contours of objects in the color distribution map, and mark the contours of closed objects;
三维处理模块440,用于根据封闭物体轮廓,对视差图进行三维色彩处理,并将处理后的视差图赋予在左右视图上。The three-dimensional processing module 440 is used to perform three-dimensional color processing on the disparity map according to the closed object outline, and assign the processed disparity map to the left and right views.
在一个实施例中,视差图获取模块410还用于确定左右视图中同一物体的像素位置;根据双目视觉立体原理,通过像素位置对同一物体进行视差计算,得到视差图。In one embodiment, the disparity map acquisition module 410 is further used to determine the pixel positions of the same object in the left and right views; according to the binocular vision stereo principle, the disparity of the same object is calculated through the pixel positions to obtain the disparity map.
在一个实施例中,色彩处理模块420还用于确定视差图中物体的各个连续颜色分布区域;根据深度信息将各个连续颜色分布区域转换成不同深度的分离颜色,得到颜色分布图。In one embodiment, the color processing module 420 is further used to determine each continuous color distribution area of the object in the disparity map; and convert each continuous color distribution area into separated colors of different depths according to the depth information to obtain a color distribution map.
在一个实施例中,图像分割模块430还用于根据颜色分布图,将不同深度的分离颜色分别进行轮廓连通,标注出封闭物体轮廓;基于封闭物体轮廓将不同深度的物体进行分割。In one embodiment, the image segmentation module 430 is further used to connect the separated colors at different depths according to the color distribution map, mark the closed object contours, and segment the objects at different depths based on the closed object contours.
在一个实施例中,视差图获取模块410还用于利用无人机设备拍摄左右视图,并通过无人机设备获取左右视图。In one embodiment, the disparity map acquisition module 410 is further used to shoot left and right views using a drone device, and acquire the left and right views through the drone device.
在一个实施例中,提供了一种计算机设备,该计算机设备可以是终端,其内部结构图可以如图5所示。该计算机设备包括通过系统总线连接的处理器、存储器、网络接口、显示屏和输入装置。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统和计算机程序。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种基于视差的裸眼3D显示方法。该计算机设备的显示屏可以是液晶显示屏或者电子墨水显示屏,该计算机设备的输入装置可以是显示屏上覆盖的触摸层,也可以是计算机设备外壳上设置的按键、轨迹球或触控板,还可以是外接的键盘、触控板或鼠标等。In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be shown in FIG5. The computer device includes a processor, a memory, a network interface, a display screen, and an input device connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, a naked-eye 3D display method based on parallax is implemented. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device may be a touch layer covered on the display screen, or a key, trackball or touchpad provided on the housing of the computer device, or an external keyboard, touchpad or mouse, etc.
本领域技术人员可以理解,图5中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。Those skilled in the art will understand that the structure shown in FIG. 5 is merely a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.
在一个实施例中,提供了一种计算机设备,包括存储器和处理器,存储器中存储有计算机程序,该处理器执行计算机程序时实现基于视差的裸眼3D显示方法的步骤。In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps of a parallax-based naked-eye 3D display method when executing the computer program.
在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,计算机程序被处理器执行时实现基于视差的裸眼3D显示方法的步骤。In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of a parallax-based naked-eye 3D display method are implemented.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM)或者外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDRSDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)等。Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202410161309.2ACN118075442B (en) | 2024-02-05 | 2024-02-05 | Naked-eye 3D display method and system based on parallax |
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202410161309.2ACN118075442B (en) | 2024-02-05 | 2024-02-05 | Naked-eye 3D display method and system based on parallax |
| Publication Number | Publication Date |
|---|---|
| CN118075442Atrue CN118075442A (en) | 2024-05-24 |
| CN118075442B CN118075442B (en) | 2025-02-07 |
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202410161309.2AActiveCN118075442B (en) | 2024-02-05 | 2024-02-05 | Naked-eye 3D display method and system based on parallax |
| Country | Link |
|---|---|
| CN (1) | CN118075442B (en) |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20140168385A1 (en)* | 2011-09-06 | 2014-06-19 | Sony Corporation | Video signal processing apparatus and video signal processing method |
| CN104301706A (en)* | 2014-10-11 | 2015-01-21 | 成都斯斐德科技有限公司 | Synthetic method for improving naked eye stereoscopic display effect |
| CN108230392A (en)* | 2018-01-23 | 2018-06-29 | 北京易智能科技有限公司 | A kind of dysopia analyte detection false-alarm elimination method based on IMU |
| CN108259881A (en)* | 2018-01-30 | 2018-07-06 | 深圳市得色科技有限公司 | 3D synthetic methods and its system based on parallax estimation |
| CN110807798A (en)* | 2018-08-03 | 2020-02-18 | 华为技术有限公司 | Image recognition method, system, related device, and computer-readable storage medium |
| CN112950695A (en)* | 2021-02-26 | 2021-06-11 | 浙江清华柔性电子技术研究院 | Image processing method, image processing device, electronic equipment and storage medium |
| CN116708746A (en)* | 2023-05-11 | 2023-09-05 | 人民百业科技有限公司 | Naked eye 3D-based intelligent display processing method |
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20140168385A1 (en)* | 2011-09-06 | 2014-06-19 | Sony Corporation | Video signal processing apparatus and video signal processing method |
| CN104301706A (en)* | 2014-10-11 | 2015-01-21 | 成都斯斐德科技有限公司 | Synthetic method for improving naked eye stereoscopic display effect |
| CN108230392A (en)* | 2018-01-23 | 2018-06-29 | 北京易智能科技有限公司 | A kind of dysopia analyte detection false-alarm elimination method based on IMU |
| CN108259881A (en)* | 2018-01-30 | 2018-07-06 | 深圳市得色科技有限公司 | 3D synthetic methods and its system based on parallax estimation |
| CN110807798A (en)* | 2018-08-03 | 2020-02-18 | 华为技术有限公司 | Image recognition method, system, related device, and computer-readable storage medium |
| CN112950695A (en)* | 2021-02-26 | 2021-06-11 | 浙江清华柔性电子技术研究院 | Image processing method, image processing device, electronic equipment and storage medium |
| CN116708746A (en)* | 2023-05-11 | 2023-09-05 | 人民百业科技有限公司 | Naked eye 3D-based intelligent display processing method |
| Publication number | Publication date |
|---|---|
| CN118075442B (en) | 2025-02-07 |
| Publication | Publication Date | Title |
|---|---|---|
| US20230377183A1 (en) | Depth-Aware Photo Editing | |
| EP3841554B1 (en) | Method and system for reconstructing colour and depth information of a scene | |
| Zhu et al. | Depth image based view synthesis: New insights and perspectives on hole generation and filling | |
| US8588514B2 (en) | Method, apparatus and system for processing depth-related information | |
| US20090219383A1 (en) | Image depth augmentation system and method | |
| JP7184748B2 (en) | A method for generating layered depth data for a scene | |
| EP3547672A1 (en) | Data processing method, device, and apparatus | |
| Jang et al. | Efficient disparity map estimation using occlusion handling for various 3D multimedia applications | |
| KR20210001254A (en) | Method and apparatus for generating virtual view point image | |
| US20250299428A1 (en) | Layered view synthesis system and method | |
| Jung | A modified model of the just noticeable depth difference and its application to depth sensation enhancement | |
| JP6128748B2 (en) | Image processing apparatus and method | |
| CN116450002A (en) | VR image processing method and device, electronic device and readable storage medium | |
| CN112991210A (en) | Image processing method and device, computer readable storage medium and electronic device | |
| KR100560464B1 (en) | How to configure a multiview image display system adaptive to the observer's point of view | |
| GB2585197A (en) | Method and system for obtaining depth data | |
| KR20140118083A (en) | System for producing stereo-scopic image or video and method for acquiring depth information | |
| KR102091860B1 (en) | Method and apparatus for image encoding | |
| Köppel et al. | Filling disocclusions in extrapolated virtual views using hybrid texture synthesis | |
| Jung et al. | Visual discomfort visualizer using stereo vision and time-of-flight depth cameras | |
| Kao | Stereoscopic image generation with depth image based rendering | |
| Pan et al. | An automatic 2D to 3D video conversion approach based on RGB-D images | |
| CN118075442B (en) | Naked-eye 3D display method and system based on parallax | |
| CN113706597B (en) | Video frame image processing method and electronic equipment | |
| Kuo et al. | High efficiency depth image-based rendering with simplified inpainting-based hole filling |
| 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 | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |