CN102790901A - Method for achieving 2D-3D conversion based on weighted average operator algorithm - Google Patents

Method for achieving 2D-3D conversion based on weighted average operator algorithm Download PDF

Info

Publication number
CN102790901A
CN102790901A CN2012102510692A CN201210251069A CN102790901A CN 102790901 A CN102790901 A CN 102790901A CN 2012102510692 A CN2012102510692 A CN 2012102510692A CN 201210251069 A CN201210251069 A CN 201210251069A CN 102790901 A CN102790901 A CN 102790901A
Authority
CN
China
Prior art keywords
pixel
algorithm
operator algorithm
frame data
edge detection
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
Application number
CN2012102510692A
Other languages
Chinese (zh)
Inventor
唐益绍
姜凤山
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Irico Group Corp
Original Assignee
Irico Group Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Irico Group Corp filed Critical Irico Group Corp
Priority to CN2012102510692A priority Critical patent/CN102790901A/en
Publication of CN102790901A publication Critical patent/CN102790901A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Processing (AREA)

Abstract

The invention relates to a method for achieving 2D-3D conversion based on weighted average operator algorithm. The method is characterized by comprising the following steps: (1) receiving an original 2D image and caching data of a first frame; (2) caching data of the next frame; (3) extracting the data of the first frame; (4) calculating the offset position of each individual pixel of the first frame image; (5) calculating gray scale difference of each individual pixel field based on the weighted average operator algorithm; (6) generating edge scan result of each pixel and determining whether the processing of all pixels is completed or not; (7) dividing images displayed by left and right eyes according to an edge scan grayscale; (8) caching the divided two images according to time sharing order; and (9) outputting the date of the first frame for displaying and returning to the step (2) so long as the data of the next frame arrives. Tests show that the method for achieving 2D-3D conversion based on the weighted average operator algorithm, provided by the invention, can produce a more obvious 3D effect.

Description

A kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm
Technical field
The present invention relates to a kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm.
Background technology
Present stage, the 3D technology develops at a terrific speed.Along with people's is to the concern of 3D technology, and More and more factories is released the novel product of supporting that 3D shows.The 3D TV, 3D projector, the 3D mobile phone, the carry-on video player of 3D etc. just progressively enters into ordinary people's family.But because the quantity problem of 3D film source, the equipment that great majority support 3D to show often can not be given full play to its effect.Exactly because so, convert the technology of 3D video to, received the concern of each producer through traditional 2D video.
For original 2D image or video, be fit to the 3D images displayed if want to convert into, need in original image, isolate the picture of left eye and right eye, and the image of left eye and right eye is handled according to diverse ways, and produce 3D effect by glasses.And the most difficult among this be the image of separate left and right eye.
Summary of the invention
The purpose of this invention is to provide a kind of method of changeing 3D, can convert traditional 2D video to the 3D video based on edge detection operator algorithm realization 2D.
A kind of method of changeing 3D based on edge detection operator algorithm realization 2D, its special feature is, comprises the steps:
(1) receives original 2D image and with the first frame data buffer memory;
(2) buffer memory next frame data;
(3) first frame data are extracted;
(4) calculate the deviation post of single pixel;
(5) calculate single pixel field grey scale difference according to edge detection algorithm;
(6) generate single pixel edge scanning result, and judge whether to accomplish all processes pixel,, otherwise return step (4) if accomplish then carry out next step;
(7) left eye and right eye institute images displayed are cut apart according to the boundary scan gray-scale map;
(8) two width of cloth images after will cutting apart carry out buffer memory according to the order that timesharing shows;
Export first frame data when (9) the next frame data arrive and be used for showing and returning step (2).
Pixel-shift position calculation formula is in the step (4): (y*w+x) * 4, and wherein x, y represent the position of pixel in this two field picture, and w represents the wide of this two field picture.
Edge detection algorithm adopts Roberts operator algorithm in the step (5), the computing formula of this Roberts operator algorithm be R=scale* (| A0-A3|+|A1-A2|), wherein R represent pixel point is the grey scale difference of each pixel in first frame data; And A0, A1, A2 and A3 represent four pixels that are the 2*2 mode configuration respectively; A0 is upper left angle point, and A1 is the point on A0 right side, and A2 is the point of A0 below; A3 is the point of A1 below, and the value of scale gets 1 in addition.
Gray value according to the R that wants elder generation to each pixel before each pixel field grey scale difference of Roberts operator algorithm computation, G, three kinds of colors of B carries out Difference Calculation; Add up again; If accumulated value more than or equal to 255, then is decided to be 255 with accumulated value, otherwise will keep accumulated value constant.
The present invention proposes a kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm; Through evidence; Through the image border that detects; The image that will belong to same profile carries out right and left eyes to be separated, and relends and helps different fast gate-types or red blue formula 3D glasses, thereby produce apparent in view 3D effect.
Description of drawings
Accompanying drawing 1 is asked differential direction figure for the edge detection algorithm that the present invention adopts;
Fig. 2 is for realizing the flow chart of the inventive method.
Embodiment
The inventive method provides a kind of and has realized that based on the edge detection operator algorithm 2D changes the method for 3D.This method is on the basis of Roberts (edge) operator algorithm, and the gray value of the pixel on the diagonal is carried out (difference) computing, and generates the boundary scan result, and the zone that will detect the edge is at last carried out right and left eyes and separated.Particular hardware realizes that framework can adopt FPGA (field programmable gate array).
The Roberts operator algorithm that the present invention adopts can be simply fast with the detection and location of original 2D edge of image profile, and accomplish the separating of left eye and eye image, thereby highlight local generation 3D effect at profile.
Embodiment 1:
Be illustrated in figure 2 as and adopt Roberts operator algorithm to realize that 2D changes the method flow diagram of 3D, may further comprise the steps:
1) receives original 2D image from video source, and, consider the size of image, calculate, need to guarantee that spatial cache will have the space of 70Mbits at least with the 1920*1080*32bit data volume with the first frame data buffer memory;
2) continue to receive the next frame data, and buffer memory next frame data, to guarantee that equally also spatial cache will have 70Mbits at least;
3) from buffer memory, first frame data are extracted;
4) calculate the deviation post of each pixel according to formula (y*w+x) * 4, wherein (the wide of w presentation video is that image is in the occupied pixel number of abscissa direction for x, y) the horizontal ordinate position of pixel in the presentation video;
5) according to Roberts boundary operator algorithm computation pixel field grey scale difference, it is that pixel value on the diagonal is asked difference that the boundary operator algorithm is asked the direction of difference, and as shown in Figure 1, the formula of reference is: R=scale* (| A0-A3|+|A1-A2|); Wherein R is the grey scale difference of pixel, A0, A1, A2; A3 is respectively four pixels that are the 2*2 mode configuration, and A0 is upper left angle point, and A1 is the point on A0 right side; A2 is the point of A0 below, and A3 is the point of A1 below, and the scale value gets 1; Then when calculating, obtain the gray scale difference score value of pixel RGB respectively, and these three values are added up; Whether judge this accumulated value then greater than 255, more than or equal to then getting 255, less than guaranteeing that then former accumulated value is constant;
6) generate single pixel boundary scan result, and (w h) judges whether to accomplish all processes pixel according to the size of this two field picture; Wherein the w presentation video is wide; The height of h presentation video, satisfied then accomplish boundary scan and handle and to carry out next step then, continue to carry out otherwise return step 4);
7) original image and scanning result image are compared, outline portion is handled, according to the deviation post of each pixel that calculates in the step 4) image offset is cut apart, dislocation is divided into left-eye image and eye image two parts;
8) two width of cloth images after will cutting apart carry out buffer memory according to the order that timesharing shows;
Export the demonstration of first frame when 9) the next frame data arrive and return the execution of second step, until end.

Claims (4)

1. a method of changeing 3D based on edge detection operator algorithm realization 2D is characterized in that, comprises the steps:
(1) receives original 2D image and with the first frame data buffer memory;
(2) buffer memory next frame data;
(3) first frame data are extracted;
(4) calculate the deviation post of single pixel;
(5) calculate single pixel field grey scale difference according to edge detection algorithm;
(6) generate single pixel edge scanning result, and judge whether to accomplish all processes pixel,, otherwise return step (4) if accomplish then carry out next step;
(7) left eye and right eye institute images displayed are cut apart according to the boundary scan gray-scale map;
(8) two width of cloth images after will cutting apart carry out buffer memory according to the order that timesharing shows;
Export first frame data when (9) the next frame data arrive and be used for showing and returning step (2).
2. a kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm as claimed in claim 1; It is characterized in that: pixel-shift position calculation formula is in the step (4): (y*w+x) * 4; Wherein x, y represent the position of pixel in this two field picture, and w represents the wide of this two field picture.
3. a kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm as claimed in claim 1; It is characterized in that: edge detection algorithm adopts Roberts operator algorithm in the step (5), the computing formula of this Roberts operator algorithm be R=scale* (| A0-A3|+|A1-A2|), wherein R represent pixel point is the grey scale difference of each pixel in first frame data; And A0, A1, A2 and A3 represent four pixels that are the 2*2 mode configuration respectively; A0 is upper left angle point, and A1 is the point on A0 right side, and A2 is the point of A0 below; A3 is the point of A1 below, and the value of scale gets 1 in addition.
4. a kind of method that realizes 2D commentaries on classics 3D based on the edge detection operator algorithm as claimed in claim 3; It is characterized in that: the gray value according to the R that wants elder generation to each pixel before each pixel field grey scale difference of Roberts operator algorithm computation, G, three kinds of colors of B carries out Difference Calculation; Add up again; If accumulated value more than or equal to 255, then is decided to be 255 with accumulated value, otherwise will keep accumulated value constant.
CN2012102510692A 2012-07-19 2012-07-19 Method for achieving 2D-3D conversion based on weighted average operator algorithm Pending CN102790901A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2012102510692A CN102790901A (en) 2012-07-19 2012-07-19 Method for achieving 2D-3D conversion based on weighted average operator algorithm

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2012102510692A CN102790901A (en) 2012-07-19 2012-07-19 Method for achieving 2D-3D conversion based on weighted average operator algorithm

Publications (1)

Publication Number Publication Date
CN102790901A true CN102790901A (en) 2012-11-21

Family

ID=47156186

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2012102510692A Pending CN102790901A (en) 2012-07-19 2012-07-19 Method for achieving 2D-3D conversion based on weighted average operator algorithm

Country Status (1)

Country Link
CN (1) CN102790901A (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120007950A1 (en) * 2010-07-09 2012-01-12 Yang Jeonghyu Method and device for converting 3d images
CN102426693A (en) * 2011-10-28 2012-04-25 彩虹集团公司 Method for converting 2D into 3D based on gradient edge detection algorithm

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120007950A1 (en) * 2010-07-09 2012-01-12 Yang Jeonghyu Method and device for converting 3d images
CN102426693A (en) * 2011-10-28 2012-04-25 彩虹集团公司 Method for converting 2D into 3D based on gradient edge detection algorithm

Similar Documents

Publication Publication Date Title
CN110709892B (en) Method and system for rendering virtual reality content based on two-dimensional ('2D') captured images of a three-dimensional ('3D') scene
JP7002056B2 (en) 3D model generator and 3D model generation method
US8553029B2 (en) Method and apparatus for determining two- or three-dimensional display mode of image sequence
TWI524734B (en) Method and device for generating a depth map
EP2755187A2 (en) 3d-animation effect generation method and system
CN103369208A (en) Self-adaptive de-interlacing method and device
CN102291587B (en) Full high-definition 3D (Three Dimensional) video processing method
CN102426693B (en) Method for converting 2D into 3D based on gradient edge detection algorithm
US20110242294A1 (en) Stereoscopic image display device and method of deriving motion vector
CN102026012B (en) Generation method and device of depth map through three-dimensional conversion to planar video
CN102447870A (en) Detection method for static objects and motion compensation device
CN104240213A (en) Display method and device
JP2012133408A (en) Image processing device and program
US20120121163A1 (en) 3d display apparatus and method for extracting depth of 3d image thereof
CN102421003A (en) Image processing method and device
US20210110512A1 (en) Systems and methods for motion adaptive filtering as pre-process to video encoding
JP2014072809A (en) Image generation apparatus, image generation method, and program for the image generation apparatus
KR101336956B1 (en) Method for converting 2 dimensional video image into stereoscopic video
KR101302431B1 (en) Method for converting 2 dimensional video image into stereoscopic video
CN102790901A (en) Method for achieving 2D-3D conversion based on weighted average operator algorithm
CN102790893A (en) Method for achieving 2D-3D conversion based on weighted average operator algorithm
KR101207862B1 (en) Method for converting 2 dimensional video image into stereoscopic video
US20130106845A1 (en) Stereoscopic image display apparatus
CN102630029A (en) Method for realizing transformation from 2D to 3D based on contrast statistics
CN103955178B (en) A kind of elevating mechanism antenna array control method of three-dimensional dynamic scene display systems

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C12 Rejection of a patent application after its publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20121121