Naked eye 3D video display method, device, equipment, medium and program product

By implementing video format recognition and rendering technology on the terminal side, the problem of difficulty in identifying video sources in VoLTE/VoNR communication service is solved, and the effect and user experience of naked-eye 3D video display are improved.

CN119052452APending Publication Date: 2024-11-29CHINA MOBILE COMM LTD RES INST +1
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411063193.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-05
Publication Date
2024-11-29

AI Technical Summary

Technical Problem

In the IMS-based VoLTE/VoNR communication service, it is difficult for the terminal to accurately identify whether the received video source is 3D content, resulting in poor display of naked-eye 3D videos and may cause abnormal picture ghosting.

Method used

By implementing a video format recognition method on the terminal side, including 3D format recognition when receiving video, judging frame numbers, monochrome images, and stitching image features, combining hash value matching and resolution bit rate threshold, determining the video format, and based on the recognition The results are 3D or 2D rendering, ensuring proper display mode.

Benefits of technology

It realizes the accurate identification and processing of 3D video content on the terminal side, improves the naked-eye 3D video display effect, avoids picture abnormalities caused by mistaken processing of 2D content, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119052452A_ABST
    Figure CN119052452A_ABST
Patent Text Reader

Abstract

The invention discloses a naked eye 3D video display method, device and equipment, a medium and a program product, and the method comprises the steps: receiving a first video, and carrying out the video format recognition of the first video when a first terminal starts a 3D display mode; when identifying that the first video is in a 3D format, performing 3D rendering on a picture in the first video to obtain a second video, and playing the second video; according to the embodiment of the invention, the terminal side can accurately identify whether the received video source is the 3D content or not, and if the received video source is the 3D content, the 3D rendering display is carried out in combination with the eye position of the current user, so that the naked eye 3D video display effect on the terminal side is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of video display technology, and in particular to a naked-eye 3D video display method, device, equipment, medium and program product. Background Art

[0002] Existing terminal operating systems mainly implement VoIMS (Voice Over IMS) audio and video call functions through the Telephony (telephone system) framework and IMS (Internet Protocol Multimedia Subsystem) services. VoIMS includes VoLTE (Voice over Long-Term Evolution) and VoNR (Voice over New Radio). VoLTE and VoNR are mainly based on audio and video communications, supporting voice calls, video calls, video ringback tones and other telephone services. The IMS-based VoLTE telephone service enables voice / video services to be transmitted as data streams in the data bearer network at the control and media levels. The IMS-based VoNR telephone service adds a DC (Data Channel) on the terminal side for data interaction between the two parties of the call, the call terminal and the application server. Therefore, there is no need to maintain and rely on the traditional circuit-switched voice network, and data and communication services can be unified under the same network, making it possible to realize naked-eye 3D (3 Dimensions) video display on the terminal based on VoLTE / VoNR communication services.

[0003] The key point of the common naked-eye 3D display technology in terminals is to add a processing layer between the user and the light-emitting element, so that the left and right eyes see different images, thus creating a 3D perception. Currently, in VoLTE / VoNR communication services, terminals may receive 2D (2 Dimensions) content or 3D content. If the terminal processes the 3D content uniformly, it will cause abnormal double images for 2D content, affecting the video display effect. Therefore, how the terminal identifies whether the received video source is 3D content to realize the application of naked-eye 3D video display in IMS-based VoLTE / VoNR communication services is a problem that needs to be solved urgently. Summary of the invention

[0004] In view of the problems existing in the prior art, the embodiments of the present invention provide a naked-eye 3D video display method, device, equipment, medium and program product, which can accurately identify whether the received video source is 3D content on the terminal side, thereby improving the naked-eye 3D video display effect on the terminal side.

[0005] In a first aspect, an embodiment of the present invention provides a naked-eye 3D video display method, which is applied to a first terminal and includes:

[0006] receiving a first video;

[0007] When the first terminal turns on the 3D display mode, identifying the video format of the first video;

[0008] When it is identified that the first video is in 3D format, 3D rendering is performed on the images in the first video to obtain a second video, and the second video is played.

[0009] As an improvement of the above solution, the receiving the first video includes:

[0010] When the first terminal establishes a call connection with the second terminal, receiving the first video;

[0011] The first video includes a video ringback tone issued by a video ringback tone platform after the first terminal completes media negotiation or a call video between the first terminal and the second terminal.

[0012] As an improvement of the above solution, the step of identifying the video format of the first video includes:

[0013] For each frame in the first video, performing 3D format identification on the current frame;

[0014] When the current frame is identified as being in 3D format, determining whether the number of frames of the image identified as being in 3D format is greater than a preset first frame number threshold;

[0015] If yes, determining that the first video is in 3D format;

[0016] If not, determining whether the number of frames of the identified picture is greater than a preset second frame number threshold;

[0017] When the number of frames of the identified picture is greater than the second frame number threshold, determining that the first video is in 2D format;

[0018] When the number of frames of the identified picture is not greater than the second frame number threshold, 3D format identification is performed on the next frame.

[0019] As an improvement of the above solution, the step of identifying the 3D format of the current frame includes:

[0020] Perform monochrome image recognition on the current frame;

[0021] Perform splicing image recognition on the current frame;

[0022] When it is identified that the current frame is not a monochrome image and the current frame is formed by splicing two images, it is determined that the current frame is in 3D format; otherwise, it is determined that the current frame is in 2D format.

[0023] As an improvement of the above solution, the step of performing monochrome image recognition on the current frame includes:

[0024] Calculate the color histogram of the current frame, and determine the color corresponding to the maximum value in the color histogram as the target color;

[0025] Calculate the pixel ratio of the target color in the current frame.

[0026] When the pixel ratio is greater than or equal to a preset ratio threshold, determining that the current frame is a monochrome image;

[0027] When the pixel ratio is less than the ratio threshold, it is determined that the current frame is not a monochrome image.

[0028] As an improvement of the above solution, the step of performing monochrome image recognition on the current frame includes:

[0029] Convert the current frame into a grayscale image, and calculate the standard deviation of the grayscale value of the grayscale image;

[0030] When the standard deviation is greater than a preset standard deviation threshold, determining that the current frame is not a monochrome image;

[0031] When the standard deviation is less than or equal to the standard deviation threshold, it is determined that the current frame is a monochrome image.

[0032] As an improvement of the above solution, the image splicing recognition of the current frame includes:

[0033] Convert the current frame into a grayscale image, and perform Gaussian filtering on the grayscale image;

[0034] Perform edge detection on the grayscale image after Gaussian filtering to obtain a binary image;

[0035] Scan edge points of a center line area of ​​the binary image; wherein the center line area is an area within a first preset range from a center line of a current frame;

[0036] Performing continuity analysis on the edge points of the centerline area to determine whether the length of the continuous edge of the centerline area is greater than a preset length threshold;

[0037] When the length of the continuous edge of the center line area is greater than the length threshold, it is determined that the current frame is formed by splicing two images.

[0038] As an improvement of the above solution, the image splicing recognition of the current frame includes:

[0039] Convert the current frame into a YUV color space image;

[0040] For each component image in the YUV color space image, respectively calculating the absolute difference between adjacent pixels on both sides of a center line of the component image and the absolute difference between adjacent pixels on the same side of the center line;

[0041] When any one of the component images satisfies a preset component mutation condition, determining that the current frame is composed of two images spliced ​​together;

[0042] Among them, the component mutation conditions include: adjacent pixels on both sides of the center line of the component image simultaneously satisfy the first condition and the second condition; the first condition includes that the difference between the absolute difference of adjacent pixels on both sides of the center line of the component image and the absolute difference of adjacent pixels on the same side of the center line is greater than a preset jump threshold; the second condition includes that the number of adjacent pixels on both sides of the center line of the component image that satisfy the first condition exceeds a preset first number threshold.

[0043] As an improvement of the above solution, the step of performing splicing image recognition on the current frame includes:

[0044] Convert the current frame into a grayscale image, and perform an average division process on the grayscale image to obtain two segmented images;

[0045] Sampling the segmented image to obtain a gray value matrix of the corresponding segmented image; wherein the gray value matrix includes gray values ​​of a plurality of sampled rows in the corresponding segmented image;

[0046] Calculate the average value of the grayscale value, the standard deviation of the grayscale value, the position of the maximum grayscale value, and the position of the minimum grayscale value of the sampled rows of each segmented image;

[0047] According to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value and the position of the minimum grayscale value, it is determined whether the current frame is formed by splicing two images.

[0048] As an improvement of the above scheme, determining whether the current frame is composed of two images spliced ​​together according to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value, and the position of the minimum grayscale value includes:

[0049] Calculate the difference between the average value of the grayscale value of the i-th sampling row of the segmented image and the average value of the grayscale value of the i-th sampling row of another segmented image to obtain a first difference; i∈N, N represents the number of sampling rows;

[0050] Calculate the difference between the standard deviation of the grayscale value of the i-th sampling row of the segmented image and the standard deviation of the grayscale value of the i-th sampling row of another segmented image to obtain a second difference;

[0051] Calculate the difference between the position of the maximum gray value of the i-th sampling row of the segmented image and the position of the maximum gray value of the i-th sampling row of another segmented image to obtain a third difference;

[0052] Calculate the difference between the position where the minimum grayscale value of the i-th sampling row of the segmented image is located and the position where the minimum grayscale value of the i-th sampling row of another segmented image is located to obtain a fourth difference;

[0053] When the two segmented images meet a preset similarity condition, determining that the current frame is formed by splicing the two images;

[0054] Among them, the similarity condition includes: the two segmented images simultaneously satisfy the third condition and the fourth condition; the third condition includes that the first difference between the i-th sampling row of the segmented image and the i-th sampling row of the other segmented image is less than a preset first difference threshold, the second difference is less than a preset second difference threshold, the third difference is less than a preset third difference threshold, and the fourth difference is less than a preset fourth difference threshold; the fourth condition includes that the number of sampling rows satisfying the third condition exceeds a preset second number threshold.

[0055] As an improvement of the above solution, before performing video format identification on the first video, the method further includes:

[0056] Extracting the first non-monochrome image in the first video;

[0057] Convert the non-monochrome image into a first grayscale image of a set size, and calculate a hash value of the first grayscale image;

[0058] Calculating the Hamming distance between the hash value of the first grayscale image and the hash value in the preset database;

[0059] When the Hamming distance is less than a preset distance threshold, obtaining a video format recognition result corresponding to a corresponding hash value in the database as a video format recognition result of the first video;

[0060] When the Hamming distance is not less than the distance threshold, the hash value is used as the key and the video format recognition result of the first video is used as the value and saved in a preset database, and the video format recognition is performed on the first video.

[0061] As an improvement of the above solution, after performing video format identification on the first video, the method further includes:

[0062] Read the resolution and bit rate of the first video;

[0063] When the resolution is less than a preset resolution threshold and the bit rate is less than a preset bit rate threshold, switching the first video to a 2D display mode;

[0064] When the resolution is not less than the resolution threshold or the bit rate is not less than the bit rate threshold, the 3D display mode is maintained.

[0065] As an improvement of the above solution, performing 3D rendering on the picture in the first video to obtain a second video, and playing the second video includes:

[0066] Acquire a forward-view image of a user of the first terminal, and perform eye tracking on the forward-view image to determine an eye position of the user; or acquire a preset position parameter;

[0067] According to the human eye position or the position parameter, the picture in the first video is rendered in 3D to obtain a second video, and the second video is played.

[0068] As an improvement of the above solution, performing 3D rendering on the picture in the first video according to the human eye position or the position parameter to obtain a second video, and playing the second video includes:

[0069] According to the human eye position or the position parameter, interlacing the images in the first video is performed by a pre-deployed 3D rendering capability module to obtain a second video;

[0070] Input the second video into a 3D video display control of a call application, so that the 3D video display control performs the following operations:

[0071] For each 3D image frame of the second video, convert the current 3D image frame into a texture image;

[0072] According to the display size parameter of the current frame 3D video display control and the preset transformation matrix, the texture image is interleaved to obtain an updated texture image after grating splitting;

[0073] The updated texture image is rendered, and the rendered updated texture image is displayed.

[0074] As an improvement of the above solution, when the first video is a video ringback tone, the method further includes:

[0075] Initiating a 3D video ringback tone subscription to the video ringback tone platform;

[0076] Acquire a most recently updated 3D format recognition algorithm from a 3D content platform; wherein the 3D format recognition algorithm is used to perform video format recognition on the video ringback tone sent by the video ringback tone platform;

[0077] Performing video ring back tone media negotiation with the video ring back tone platform, so that the video ring back tone platform queries the 3D content platform for the tag information of the 3D video material to be sent before completing the video ring back tone media negotiation; and when it is found that the 3D video material has the tag information, sending the 3D video material as a video ring back tone to the first terminal; when it is found that the video material does not have the tag information, obtaining a 2D video material as a video ring back tone and sending it to the first terminal;

[0078] The marking information is generated by the 3D content platform after the video format verification is performed on the 3D video material according to the most recently updated 3D format recognition algorithm and after the video format verification passes.

[0079] In a second aspect, an embodiment of the present invention provides a naked-eye 3D video display device, comprising:

[0080] A video receiving module, used for receiving a first video;

[0081] A video format identification module, configured to identify the video format of the first video when the first terminal turns on the 3D display mode;

[0082] The 3D rendering and display module is used to perform 3D rendering on the pictures in the first video to obtain a second video and play the second video when it is recognized that the first video is in 3D format.

[0083] In a third aspect, an embodiment of the present invention provides a naked-eye 3D video display device, comprising: a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, it implements the naked-eye 3D video display method as described in any one of the first aspects.

[0084] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the naked-eye 3D video display method as described in any one of the first aspects.

[0085] In a fifth aspect, an embodiment of the present invention provides a computer program product, including a computer program / instruction, which, when executed by a processor, implements the naked-eye 3D video display method as described in any one of the first aspects.

[0086] Compared with the prior art, a naked-eye 3D video display method, device, equipment, medium and program product in an embodiment of the present invention receives a first video and identifies the video format of the first video when a 3D display mode is turned on at a first terminal; then, when it is identified that the first video is in 3D format, a forward-view image of a user of the first terminal is obtained, and human eye tracking is performed on the forward-view image to determine the eye position of the user; according to the eye position, 3D rendering is performed on the picture in the first video to obtain a second video, and the second video is played; in an embodiment of the present invention, the terminal side can accurately identify whether the received video source is 3D content, and if it is 3D content, 3D rendering and display are performed in combination with the eye position of the current user, thereby improving the naked-eye 3D video display effect on the terminal side. BRIEF DESCRIPTION OF THE DRAWINGS

[0087] In order to more clearly illustrate the technical solution of the present invention, the drawings used in the implementation mode will be briefly introduced below. Obviously, the drawings described below are only some implementation modes of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0088] Figure 1 is a schematic diagram of a video ring back tone service process provided by an embodiment of the present invention;

[0089] Figure 2 is a flow chart of a naked-eye 3D video display method provided by an embodiment of the present invention;

[0090] Figure 3 is a schematic diagram of a terminal architecture provided by an embodiment of the present invention;

[0091] Figure 4 is a flow chart of video ringback tone rendering and display provided by an embodiment of the present invention;

[0092] Figure 5 is a flowchart of video format identification provided by an embodiment of the present invention;

[0093] Figure 6 is a schematic diagram of an SBS format screen provided by an embodiment of the present invention;

[0094] Figure 7 is a schematic diagram of left and right parallax of the SBS format provided by an embodiment of the present invention;

[0095] Figure 8 is a schematic diagram of a 3D format recognition process provided by an embodiment of the present invention;

[0096] Fig. 9 is a schematic diagram of a 3D rendering process provided by an embodiment of the present invention;

[0097] Fig.10 is a schematic diagram of a pre-verification process of a 3D format recognition algorithm provided by an embodiment of the present invention;

[0098] Fig.11 is a structural block diagram of a naked-eye 3D video display device provided by an embodiment of the present invention;

[0099] Fig.12 It is a structural block diagram of a naked-eye 3D video display device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0100] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0101] It is understood that the various numbers involved in the embodiments of the present invention are only for the convenience of description and are not intended to limit the scope of the present application. The size of the sequence number of each process does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic.

[0102] In embodiments of the present invention, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. The terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or equipment including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or equipment. In the absence of more restrictions, the elements defined by the statement "include..." do not exclude the existence of other identical elements in the process, method, article or equipment including the elements. The term "multiple or several" refers to two or more, and the same applies to "multiple / items or several / items". "And / or" describes the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B, which can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects before and after are in an "or" relationship.

[0103] The technical solution provided by the embodiment of the present invention can be applied to various communication systems, for example: the fifth generation (5th generation, 5G) communication system (or called the new radio (new radio, NR) system), the fourth generation (4th generation, 4G) communication system (or called the long term evolution (long term evolution, LTE) system), LTE frequency division duplex (frequency division duplex, FDD) system, LTE time division duplex (time division duplex, TDD) system, etc. The technical solution provided by the embodiment of the present invention can also be applied to future communication systems, such as the sixth generation (6th generation, 6G) mobile communication system.

[0104] A terminal may be a device that provides voice / data connectivity to a user, such as a handheld device or a vehicle-mounted device with a wireless connection function. At present, some examples of terminals can be: mobile phones, tablet computers, computers with wireless transceiver functions (such as laptops, PDAs, etc.), mobile Internet devices (mobile internet devices, MID), virtual reality (virtual reality, VR) devices, AR devices, wireless terminals in industrial control, wireless terminals in unmanned driving, wireless terminals in telemedicine, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, wireless terminals in smart homes, cellular phones, cordless phones, session initiation protocol (session initiation protocol, SIP) phones, wireless local loop (wireless local loop, WLL) stations, personal digital assistants (personal digital assistant, PDA), handheld devices with wireless communication functions, computing devices or other processing devices connected to wireless modems, vehicle-mounted devices, wearable devices, terminal devices in 4G / 5G networks or terminal devices in future evolved public land mobile communication networks (public land mobile network, PLMN), wireless terminals in Internet of things (IoT) systems, etc., which are not specifically limited in the embodiments of the present invention.

[0105] The following is an explanation of some terminology concepts and related technologies involved in the embodiments of the present invention.

[0106] Most terminals on the market support video ringback tone playback. The video media of the video ringback tone service is usually a media file customized in advance by the video ringback tone platform. The media stream sent to the terminal is determined through pre-call media negotiation, and then decoded by the terminal and played by the player. Figure 1 As shown, UE (user equipment, also described as terminal) A and UE B conduct IMS calls through the IMS network, and UE A and UE B conduct multimedia communications through SIP (Session Initiation Protocol, Session Initiation Protocol / Session Initiation Protocol) signaling, such as video calls in the form of audio and video streams, video ringback tone and other call services. Among them, the IMS network includes the calling IMS domain and the called IMS domain, and both the calling IMS domain and the called IMS domain are equipped with SBC (Session Border Control) network elements and S-CSCF (serving call session control function) network elements.

[0107] SBS (Side-by-Side): A common 3D format, with left and right images placed side by side and parallax between them.

[0108] TAB (Top-and-Bottom): A common 3D format, where the upper and lower images are placed side by side with parallax between them.

[0109] Dialer: An application used on a terminal to implement calls, also known as a dial pad application.

[0110] At present, the video content of the naked-eye 3D video display of the VoLTE / VoNR communication service based on the IMS network is usually determined by the terminal and the platform after negotiation. However, since the video content in TAB / SBS format is directly played on the terminal, the user viewing experience is not good. At the same time, the terminal may receive 2D (2 Dimensions, two-dimensional) content or 3D content in the VoLTE / VoNR communication service. If the terminal processes the 3D content uniformly, it will cause abnormal double images for the 2D content, affecting the video display effect. Based on this, an embodiment of the present invention proposes a naked-eye 3D video display method, which realizes a new naked-eye 3D video display by automatically identifying the 3D format of the received video content on the terminal side and performing 3D video rendering on the video content in 3D format.

[0111] A naked-eye 3D video display method provided by an embodiment of the present invention is described in detail below with reference to the accompanying drawings.

[0112] See also Figure 1 , Figure 1 It is a flow chart of a naked-eye 3D video display method provided by an embodiment of the present invention.

[0113] The naked-eye 3D video display method is applied to a first terminal, comprising:

[0114] S11: receiving a first video;

[0115] S12: When the first terminal turns on the 3D display mode, identify the video format of the first video;

[0116] S13: When it is identified that the first video is in 3D format, 3D rendering is performed on the images in the first video to obtain a second video, and the second video is played.

[0117] Among them, when the first terminal establishes a call connection with the second terminal, the first video is received; the first video includes the video ringback tone issued by the video ringback tone platform after the first terminal completes the media negotiation or the call video between the first terminal and the second terminal.

[0118] Further, when it is identified that the first video is in 2D format, the first video is played directly.

[0119] If the first terminal does not open the 3D display mode, that is, in the 2D display mode, it is also necessary to identify the video format of the first video; at this time, if the first video is identified as a 3D format, the first video is converted into a 2D format to obtain a third video, and the third video is played; for example, by cropping each frame of the first video in the 3D format, the SBS format only takes the left or right image of the image, and the TAB format only takes the upper or lower image of the image, which is not specifically limited in the embodiment of the present invention. If the first video is identified as a 2D format, the first video is played directly.

[0120] Further, performing 3D rendering on the picture in the first video to obtain a second video, and playing the second video includes:

[0121] Acquire a forward-view image of a user of the first terminal, and perform eye tracking on the forward-view image to determine an eye position of the user; or acquire a preset position parameter;

[0122] According to the human eye position or the position parameter, the picture in the first video is rendered in 3D to obtain a second video, and the second video is played.

[0123] In an embodiment of the present invention, the first terminal pre-deploys a modem, a 3D logic management module, a 3D rendering capability module, and a call application; wherein the call application is provided with a 3D video display control and a 2D video display control, such as Figure 3 As shown. The 3D logic management module is used to control the switch of the 3D display mode and perform video format recognition, etc. The 3D rendering capability module is used to process the 3D format (such as SBS format, TAB format) video identified by the video format of the 3D rendering capability module, and form an interlaced picture composed of two images with a certain parallax projected to the human eye. The 3D video display control is used to execute the OpenGL standard rendering process to display videos in 3D format. The 2D video display control is used to execute the OpenGL standard rendering process to display videos in 2D format.

[0124] The user can enable the 3D display mode or the 2D display mode in advance through the 3D logic management module. Assuming that the first terminal is based on the Telephony framework of the Android system, the first video received by the first terminal is decoded by the modem and input into the 3D logic management module; the 3D logic management module first inquires whether the 3D display mode has been enabled. If enabled, the decoded first video is identified in the 3D mode to determine whether the first video is in 3D format; if it is in 3D format, the first video is input into the 3D rendering capability module, and at the same time, the first terminal starts the front camera to capture the current front image of the user, and performs human eye tracking on the front image to determine the user's human eye position, and inputs the human eye position into the 3D rendering capability module; or when the front camera cannot be started to capture the current front image of the user or the captured signature image cannot identify the user's human eye position, the pre-set default position parameters can be directly obtained (for example, 40 cm from the front is regarded as the human eye position), and the default position parameters are input into the 3D rendering capability module.

[0125] The 3D rendering capability module performs 3D rendering on the first video according to the received human eye position or position parameters. Each frame of the first video after 3D rendering is an interlaced picture projected to the human eye by two images with a certain parallax, and finally rendered to the 3D video display control for playback. If it is in 2D format, the first video is played through the 2D video display control. If the 3D logic management module inquires that the first terminal does not turn on the 3D display mode, that is, in 2D mode, the video format of the decoded first video is identified to determine whether the first video is in 3D format. The video format of the decoded first video will also be identified. However, regardless of whether the identified first video is in 2D format or 3D format, it will be played through the 2D video display control. For example, if it is identified as a 3D format, the first video is converted to 2D format and input into the 2D video display control for playback.

[0126] Take the first video as a video ringback tone as an example, combined with Figure 4The video ringback tone rendering and display process shown is a detailed description of the naked-eye 3D video display method described in the embodiment of the present invention. Assuming that the user of the first terminal has subscribed to the 3D video ringback tone service, the video ringback tone rendering and display process is consistent regardless of whether it is a calling video ringback tone or a called video ringback tone. Taking the calling video ringback tone as an example, the first terminal initiates a call to the second terminal (for example, initiates a SIP Invite, a Session Initiation Protocol / Session Initiation Protocol invitation), and completes the normal VoIMS call establishment and video ringback tone media negotiation. The video ringback tone platform performs video ringback tone media negotiation, resource reservation confirmation and video ringback tone playback preparation in accordance with the operator's business specifications. It should be noted that the video ringback tone media negotiation process can be referred to the existing media negotiation process, which is not described in detail here. After the first terminal establishes a call and completes the video ringback tone media negotiation, the video ringback tone platform is ready to play the video ringback tone and sends the video ringback tone to the first terminal. When the first terminal needs to view the video ringback tone, the following video ringback tone rendering and display process needs to be performed, which specifically includes:

[0127] Step a: Initialize the 3D logic management module and query whether the local machine has 3D rendering capability; for example, query the 3D rendering capability module whether the local machine has 3D rendering capability. It should be understood that 3D rendering capability requires the first terminal to be configured with a 3D raster matching software SDK (Software Development Kit). If 3D rendering capability is available, the 3D display mode is enabled through the 3D logic management module and step b is executed; otherwise, the 2D display mode is enabled through the 3D logic management module and step b' is executed.

[0128] Step b: Create a 3D video display control; for example, create a GLSurfaceView (GLSurfaceView is a display component based on OpenGL (Open Graphics Library, a cross-platform 3D graphics processing hardware programming interface)) as a 3D video display control.

[0129] Step c: In 3D display mode, set the decoded video ring back tone to be input into the 3D logic management module for frame-by-frame analysis to determine whether the current frame is in 3D format; for example, set the destination of the decoded video ring back tone (generally a Surface object, which represents the content displayed on the screen) and input the picture into the 3D logic management module frame by frame. If the video ring back tone is determined to be in 2D format, execute step e' for rendering. If the video ring back tone is determined to be in 3D format, execute step d.

[0130] Step d: calling the 3D rendering capability module to perform 3D interlacing processing on the video ringback tone picture, and at the same time using the front camera to capture the user's front-view image to calculate the eye position to assist in the 3D interlacing of the picture; in an embodiment of the present invention, the 3D rendering capability module needs to track the eye position to assist in the interlacing calculation, obtain the user's camera call permission authorization when subscribing to the 3D video ringback tone or making this call, use the camera API (Application Programming Interface) to start the front camera to capture the user's current front-view image, and then use the eye tracking algorithm to locate the eye of the front-view image, determine the eye position, and pass it to the 3D rendering capability module to assist in 3D interlacing.

[0131] Step e: Render the texture of each frame of the interleaved video ringback tone output by the 3D rendering capability module, and display it in the 3D video display control created in step b, so as to complete the video ringback tone playback in 3D format.

[0132] It should be noted that the 3D video display control performs rendering and display according to the OpenGL standard rendering process, for example, each frame of the video ringtone corresponding texture is displayed on the 3D video display control, including setting the shader, setting the viewport size, setting the vertex coordinates, setting the texture coordinates, setting the transformation matrix, etc., and calling the binding method to bind the texture corresponding to the video ringtone and the drawing method, so as to complete the display of one frame of the picture, and each subsequent frame undergoes the same processing. It should be understood that the OpenGL standard rendering process belongs to the prior art and is not described in detail in the embodiments of the present invention.

[0133] Step b': Create a 2D video display control; for example, create a GLSurfaceView or a TextureView (a UI (User Interface) display control that displays data streams) as a 2D video display control. In order to improve flexibility, the embodiment of the present invention preferably creates a GLSurfaceView as a 2D video display control.

[0134] Step c': In 2D display mode, set the decoded video ring back tone to be input into the 3D logic management module for frame-by-frame analysis to determine whether the current frame is in 3D format; for example, set the destination of the decoded video ring back tone (generally a Surface object, which represents the content displayed on the screen) and input the picture into the 3D logic management module frame by frame. If the video ring back tone is determined to be in 2D format, execute step e' for rendering; if the video ring back tone is determined to be in 3D format, execute step d'.

[0135] Step d': If the video ringback tone is determined to be in 3D visual format, for each frame of the video ringback tone, one of the images of the picture is cropped, and the texture of each frame of the cropped video ringback tone is output; for example, a video ringback tone in SBS format only takes the left or right picture of the picture, and a video ringback tone in TAB format only takes the top or bottom picture of the picture, which is not specifically limited in the embodiments of the present invention.

[0136] Step e': if the video ringback tone is determined to be in 2D format, the texture of each frame of the video ringback tone is finally obtained for rendering to the 2D video display control created in step b', thereby completing the playback of the video ringback tone in 2D format.

[0137] It should be understood that the 2D video display control also performs rendering and display according to the OpenGL standard rendering process. The OpenGL standard rendering process can be found in the above description and will not be described in detail here.

[0138] It should be noted that the embodiments of the present invention are applicable to video ringback tone, call and non-call scenarios. The naked-eye 3D video display process of the call video and non-call scenarios during the video call process can refer to the above-mentioned video ringback tone rendering display process, which will not be repeated here.

[0139] In an embodiment of the present invention, the terminal side can automatically and accurately identify the video format of the received video ringback tone or call video, determine whether to perform 3D rendering display according to the actual received video format, and if it is in 3D format, perform 3D rendering display in combination with the current user's eye position to improve the naked-eye 3D video display effect on the terminal side; if it is in 2D format, directly perform rendering display in 2D format. On the one hand, the embodiment of the present invention can realize the control of 3D rendering on and off without additional signaling or application layer protocol interaction, and on the other hand, it can avoid the picture abnormality caused by the mismatch between the 3D rendering display switch on the terminal side and the actual received video format (for example, 3D format video is rendered and displayed in 2D format, or 2D format video is rendered and displayed in 3D format). At the same time, in an embodiment of the present invention, the terminal side only needs to add a 3D logic management module, a 3D rendering capability module, and create a 3D video display control and a 2D video display control in the call application, so that the naked-eye 3D video display can be realized in combination with the naked-eye 3D film source, and the terminal side is less modified, which can effectively reduce the cost of realizing naked-eye 3D video display on existing terminals.

[0140] Specifically, the performing video format identification on the first video includes:

[0141] For each frame in the first video, performing 3D format identification on the current frame;

[0142] When the current frame is identified as being in 3D format, determining whether the number of frames of the image identified as being in 3D format is greater than a preset first frame number threshold;

[0143] If yes, determining that the first video is in 3D format;

[0144] If not, determining whether the number of frames of the identified picture is greater than a preset second frame number threshold;

[0145] When the number of frames of the identified picture is greater than the second frame number threshold, determining that the first video is in 2D format;

[0146] When the number of frames of the identified picture is not greater than the second frame number threshold, 3D format identification is performed on the next frame.

[0147] Furthermore, before performing video format identification on the first video, the method further includes:

[0148] Extracting the first non-monochrome image in the first video;

[0149] Convert the non-monochrome image into a first grayscale image of a set size, and calculate a hash value of the first grayscale image;

[0150] Calculating the Hamming distance between the hash value of the first grayscale image and the hash value in the preset database;

[0151] When the Hamming distance is less than a preset distance threshold, obtaining a video format recognition result corresponding to a corresponding hash value in the database as a video format recognition result of the first video;

[0152] When the Hamming distance is not less than the distance threshold, the hash value is used as the key and the video format recognition result of the first video is used as the value and saved in a preset database, and the video format recognition is performed on the first video.

[0153] Further, after performing video format identification on the first video, the method further includes:

[0154] Read the resolution and bit rate of the first video;

[0155] When the resolution is less than a preset resolution threshold and the bit rate is less than a preset bit rate threshold, switching the first video to a 2D display mode;

[0156] When the resolution is not less than the resolution threshold or the bit rate is not less than the bit rate threshold, the 3D display mode is maintained.

[0157] Considering that the first terminal may have received the first video in 2D format due to platform negotiation failure or other reasons, if the first terminal still directly performs interleaving processing in 3D format, it will cause abnormal double images. Therefore, in an embodiment of the present invention, the initial frames of the first video stream (such as RTP (Real-time Transport Protocol)) are monitored in real time and compatible processing is performed: for frames in SBS / TAB format, they are regarded as 3D content and need to be interleaved through 3D rendering process; for frames in 2D format, they are regarded as ordinary 2D content and displayed directly. Figure 5 As shown, the process of video format identification of the first terminal is as follows:

[0158] Step A: The first video is prepared and 3D format recognition is enabled; when the first terminal receives the first video, the 3D logic management module enables 3D format recognition.

[0159] Step B: temporarily not displaying the video frame; the first terminal temporarily does not display the first video when it cannot determine whether the current first video is in 3D format or 2D format. Subsequently, 3D format identification is performed in sequence according to the frame sequence to be analyzed of the first video, for example, determining whether a frame belongs to the SBS / TAB format. If so, the corresponding frame is regarded as 3D format, otherwise the corresponding frame is regarded as 2D format.

[0160] Step C: Determine whether the frame number of the picture identified as 3D format is greater than the first frame number threshold; if so, complete the 3D format identification process of the first video, regard the first video as 3D format (i.e., 3D video), and execute step G; if not, execute step D.

[0161] Step D: Whether the number of frames of the picture identified by the first frame number threshold exceeds the second frame number threshold; if so, the first video is regarded as a 2D format (i.e., 2D video) and step F is executed; if not, step E is executed. The second frame number threshold is a preset maximum number of frames for 3D format identification.

[0162] Step E: Determine whether the next frame is in 3D format. No matter whether the next frame is in 3D format or 2D format, return to step C.

[0163] Step F: For the first video in 2D format, directly render and display it in 2D format.

[0164] Step G: For the first video in 3D format, 3D interlaced rendering is performed according to the 3D format.

[0165] Step H: Cache the recognition result of this time, and store it in a local database with the hash value of the first non-monochrome image of the first video as the key and the 3D format recognition result as the value. Before performing the video format recognition of the video ringback tone next time, you can first query the database to see whether there is the same video ringback tone recognition result. If there is, you can directly read the corresponding recognition result without the need to perform the subsequent 3D format recognition offline, thereby effectively reducing the 2D / 3D content judgment time of the same video ringback tone next time.

[0166] Taking the first video as a video ring back tone as an example, the first non-monochrome image of the video ring back tone is first converted into a first grayscale image of a fixed size; then the image hash calculation is performed on the first grayscale image to obtain a corresponding hash value, for example, the image hash calculation is performed on the first grayscale image of 8×8 size using an average hash algorithm, and a hexadecimal aHash string can be obtained; the hash value of the first non-monochrome image of the video ring back tone is used as a key, and the above-obtained 2D / 3D format recognition result is used as a value, and is saved in the local database of the first terminal. When the user initiates a call again and receives a new video ring back tone, the hash value corresponding to the first non-monochrome image of the newly received video ring back tone is calculated, and the newly calculated hash value is matched with the hash value stored in the database, for example, the Hamming distance between the hash value of the first non-monochrome image of the newly received video ring back tone and the hash value stored in the database is calculated. If the Hamming distance is less than or equal to the distance threshold, for example, the Hamming distance <= 1, it is considered that the newly received video ring back tone is the same as the video ring back tone corresponding to the corresponding hash value in the database, and the recognition result corresponding to the corresponding hash value in the database is directly read as the recognition result of the newly received video ring back tone.

[0167] Step I: Read the resolution and bit rate of the first video. If the resolution is less than a preset resolution threshold and the bit rate is less than a preset bit rate threshold, for example, the resolution is less than 720P and the bit rate is less than 2000KBps, it is considered that the clarity may not be sufficient to support the accuracy of the recognition result. Switch to 2D display mode and display a pop-up window to prompt the user to manually switch between 3D display mode and 2D display mode, thereby avoiding 2D / 3D display mode mismatch caused by inaccurate recognition results due to low video clarity and avoiding abnormal video playback.

[0168] Specifically, the step of identifying the 3D format of the current frame includes:

[0169] Perform monochrome image recognition on the current frame;

[0170] Perform splicing image recognition on the current frame;

[0171] When it is identified that the current frame is not a monochrome image and the current frame is formed by splicing two images, it is determined that the current frame is in 3D format; otherwise, it is determined that the current frame is in 2D format.

[0172] In an embodiment of the present invention, the 3D format recognition of each frame of the first video mainly includes two recognition processes, one is to recognize whether the picture is a monochrome image, and the other is to recognize whether the picture is a spliced ​​image. First, by identifying whether the picture is a monochrome image, the black screen when the network is not good and the single-color invalid content such as the pure color image that may be mistaken for the 3D format can be excluded. The misjudgment effect on the 3D format recognition of the first video can be eliminated. Then, based on the principle that the center line edge of the 3D format picture is clearly distinguished or the 3D format picture is spliced ​​by similar phase images, the non-monochrome image in the first video is further recognized in 3D format, which can improve the accuracy of video format recognition of the first terminal.

[0173] The monochrome image recognition for the current frame includes but is not limited to the following two schemes.

[0174] The first monochrome image recognition scheme is based on the histogram analysis method to determine whether the current frame is a monochrome image, as follows:

[0175] Calculate the color histogram of the current frame, and determine the color corresponding to the maximum value in the color histogram as the target color;

[0176] Calculate the pixel ratio of the target color in the current frame.

[0177] When the pixel ratio is greater than or equal to a preset ratio threshold, determining that the current frame is a monochrome image;

[0178] When the pixel ratio is less than the ratio threshold, it is determined that the current frame is not a monochrome image.

[0179] Exemplarily, for each frame of the first video, according to the frame sequence to be analyzed (generally sorted in chronological order of the frames), the following operations are performed frame by frame: the color histogram of the picture is calculated; the color histogram displays the number of pixels of different colors in the picture, and displays the distribution of each color in the form of a histogram; the color corresponding to the maximum value is found in the color histogram (that is, the color that appears most frequently in the picture). The pixel ratio of the pixel corresponding to the color in the entire picture is calculated; if the pixel ratio is greater than or equal to a preset ratio threshold, the corresponding picture is considered to be a monochrome image, otherwise the corresponding picture is considered not to be a monochrome image. It should be noted that in the embodiment of the present invention, the value of the ratio threshold is not specifically limited, for example, it can be set to 0.9.

[0180] The second monochrome image recognition scheme is to determine whether the current frame is a monochrome image based on the grayscale image standard deviation, as follows:

[0181] Convert the current frame into a grayscale image, and calculate the standard deviation of the grayscale value of the grayscale image;

[0182] When the standard deviation is greater than a preset standard deviation threshold, determining that the current frame is not a monochrome image;

[0183] When the standard deviation is less than or equal to the standard deviation threshold, it is determined that the current frame is a monochrome image.

[0184] For example, for each frame of the first video, according to the frame sequence to be analyzed (generally sorted in the time sequence of the frames), the following operations are performed frame by frame: the picture is converted into a grayscale image, and the standard deviation of the grayscale image is calculated using the standard deviation formula. If the standard deviation is greater than a preset standard deviation threshold, the corresponding picture is considered to be a monochrome image, otherwise the corresponding picture is considered not to be a monochrome image. It should be noted that in the embodiment of the present invention, the value of the standard deviation threshold is not specifically limited, for example, it can be set to 10.

[0185] The image splicing and recognition for the current frame includes but is not limited to the following three schemes.

[0186] The first type of image splicing recognition is based on the continuity of the edges near the center line to determine whether the current frame is spliced ​​by two images, as follows:

[0187] Convert the current frame into a grayscale image, and perform Gaussian filtering on the grayscale image;

[0188] Perform edge detection on the grayscale image after Gaussian filtering to obtain a binary image;

[0189] Scan edge points of a center line area of ​​the binary image; wherein the center line area is an area within a first preset range from a center line of a current frame;

[0190] Performing continuity analysis on the edge points of the centerline area to determine whether the length of the continuous edge of the centerline area is greater than a preset length threshold;

[0191] When the length of the continuous edge of the center line area is greater than the length threshold, it is determined that the current frame is formed by splicing two images.

[0192] Exemplarily, for the picture that is not a monochrome picture in the first video, the picture is first converted to grayscale to obtain a grayscale image of the picture; then the grayscale image is Gaussian filtered to smooth the picture and reduce noise; the filtered picture is edge detected to output a binary image; Exemplarily, the Canny edge detection algorithm is used to perform edge detection, the edge is marked as white (value 1), and the non-edge area is black (value 0). Then the center line area is scanned; wherein the center line area is the range from half the width of the picture minus the offset to half the width of the picture plus the offset, that is, [x / 2-offset, x / 2+offset], x represents the width of the picture, and offset represents the offset, which is generally 2 pixels. For the SBS format picture, the center line area defined is scanned from top to bottom, and for the TAB format picture, the center line area defined is scanned from left to right, and the edge points detected in the center line area are recorded, and continuity analysis is performed to calculate the length of the continuous edge. Finally, it is determined whether the length of the continuous edge of the center line area is greater than a preset length threshold. If so, it is considered that there is an obvious edge in the middle of the picture and the picture is a spliced ​​image. Otherwise, it is considered that the picture is not a spliced ​​image.

[0193] by Figure 6 Taking the SBS format picture shown as an example, the length of the continuous edge of the center line area can be understood as the maximum value hit1 of the number of continuous rows with edge points in the center line area, then:

[0194] hit1 = max(number of consecutive rows with edge points in the centerline area) > TH1 (1);

[0195] Wherein, hit1 represents that the current continuous edge meets the requirement. TH1 represents a preset length threshold. It should be noted that in the embodiment of the present invention, the value of the length threshold is not specifically limited, and the user can set it according to actual needs.

[0196] The second type of image splicing recognition is based on the mutation near the center line to determine whether the current frame is spliced ​​by two images, as follows:

[0197] Convert the current frame into a YUV color space image;

[0198] For each component image in the YUV color space image, respectively calculating the absolute difference between adjacent pixels on both sides of a center line of the component image and the absolute difference between adjacent pixels on the same side of the center line;

[0199] When any one of the component images satisfies a preset component mutation condition, determining that the current frame is composed of two images spliced ​​together;

[0200] Among them, the component mutation conditions include: adjacent pixels on both sides of the center line of the component image simultaneously satisfy the first condition and the second condition; the first condition includes that the difference between the absolute difference of adjacent pixels on both sides of the center line of the component image and the absolute difference of adjacent pixels on the same side of the center line is greater than a preset jump threshold; the second condition includes that the number of adjacent pixels on both sides of the center line of the component image that satisfy the first condition exceeds a preset first number threshold.

[0201] For example, for the picture that is not a monochrome picture in the first video, the picture is first converted into a YUV color space image, including brightness information (Y component) and color information (U component and V component). Then, the absolute difference of the adjacent pixels on both sides of the center line of each component image and the absolute difference of the adjacent pixels on the same side of the center line are calculated. Taking the Y component image as an example, the absolute difference of the adjacent pixels on both sides of the center line of the Y component image and the absolute difference of the adjacent pixels on the same side of the center line are calculated, and the two absolute differences are compared. If the difference y_hit_cnt between the absolute difference of the adjacent pixels on both sides of the center line and the absolute difference of the adjacent pixels on the same side is greater than the preset jump threshold TH2, then:

[0202] y_hit_cnt = count(abs(abs(y[x / 2-1]-y[x / 2+1])-abs(y[x / 2+1]-y[x / 2+2]))> TH2) (2);

[0203] At this time, it can be considered that the corresponding component differences of the pixels on both sides of the center line in the Y component image are large enough. Among them, x / 2 represents the center line, y[x / 2-1] and y[x / 2+1] represent the pixels on both sides of the center line, abs represents the absolute value function, count represents the statistical number function, abs(y[x / 2-1]-y[x / 2+1]) represents the absolute difference between adjacent pixels on both sides of the center line, y[x / 2+1] and y[x / 2+2] represent the pixels on the same side of the center line, and abs(y[x / 2+1]-y[x / 2+2] represents the absolute difference between adjacent pixels on the same side of the center line.

[0204] The above analysis is also performed for the U component image and the V component image. If the difference u_hit_cnt between the absolute difference of the adjacent pixels on both sides of the center line of the U component image and the absolute difference of the adjacent pixels on the same side is greater than the preset jump threshold TH2, then:

[0205] u_hit_cnt = count(abs(abs(y[x / 2-1]-y[x / 2+1])-abs(y[x / 2+1]-y[x / 2+2]))> TH2) (3);

[0206] At this time, it can be considered that the difference between the corresponding components of the pixels on both sides of the center line in the U component image is large enough.

[0207] If the difference v_hit_cnt between the absolute difference of the adjacent pixels on both sides of the center line of the V component image and the absolute difference of the adjacent pixels on the same side is greater than the preset jump threshold TH2, then:

[0208] v_hit_cnt = count(abs(abs(y[x / 2-1]-y[x / 2+1])-abs(y[x / 2+1]-y[x / 2+2]))> TH2) (4);

[0209] At this time, it can be considered that the difference between the corresponding components of the pixels on both sides of the center line in the V component image is large enough.

[0210] If the number of adjacent pixels on both sides of the center line of any one of the Y component image, the U component image and the V component image that satisfies the above formulas (2), (3) and (4) exceeds a preset first quantity threshold, it can be considered that there is an obvious mutation in the middle of the image, and the image is a spliced ​​image. Otherwise, the image is not a spliced ​​image. It should be noted that in the embodiment of the present invention, the value of the first quantity threshold is not specifically limited. For example, it can be taken as half of the height of the component image, that is, half of the number of pixels in a column of the component image. In this case,

[0211] hit 2= max(y_hit_cnt, u_hit_cnt, v_hit_cnt) > height / 2 (5);

[0212] Wherein, hit2 represents that the current component meets the requirement. height represents half of the height of the component image. In the embodiment of the present invention, when the difference between the corresponding components of the pixels on both sides of the cross-center line is large enough (for example, larger than the difference between the adjacent pixels not crossing the center line), and the number is large enough (for example, the number of components among the Y, U, and V components that meet the condition exceeds half), the picture is considered to be a spliced ​​image.

[0213] The third type of image splicing recognition is to determine whether the current frame is spliced ​​by two images based on the similarity of the two images in the 3D format, as follows:

[0214] Convert the current frame into a grayscale image, and perform an average division process on the grayscale image to obtain two segmented images;

[0215] Sampling the segmented image to obtain a gray value matrix of the corresponding segmented image; wherein the gray value matrix includes gray values ​​of a plurality of sampled rows in the corresponding segmented image;

[0216] Calculate the average value of the grayscale value, the standard deviation of the grayscale value, the position of the maximum grayscale value, and the position of the minimum grayscale value of the sampled rows of each segmented image;

[0217] According to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value and the position of the minimum grayscale value, it is determined whether the current frame is formed by splicing two images.

[0218] Further, determining whether the current frame is composed of two images spliced ​​together according to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value, and the position of the minimum grayscale value includes:

[0219] Calculate the difference between the average value of the grayscale value of the i-th sampling row of the segmented image and the average value of the grayscale value of the i-th sampling row of another segmented image to obtain a first difference; i∈N, N represents the number of sampling rows;

[0220] Calculate the difference between the standard deviation of the grayscale value of the i-th sampling row of the segmented image and the standard deviation of the grayscale value of the i-th sampling row of another segmented image to obtain a second difference;

[0221] Calculate the difference between the position of the maximum gray value of the i-th sampling row of the segmented image and the position of the maximum gray value of the i-th sampling row of another segmented image to obtain a third difference;

[0222] Calculate the difference between the position where the minimum grayscale value of the i-th sampling row of the segmented image is located and the position where the minimum grayscale value of the i-th sampling row of another segmented image is located to obtain a fourth difference;

[0223] When the two segmented images meet a preset similarity condition, determining that the current frame is formed by splicing the two images;

[0224] Among them, the similarity condition includes: the two segmented images simultaneously satisfy the third condition and the fourth condition; the third condition includes that the first difference between the i-th sampling row of the segmented image and the i-th sampling row of the other segmented image is less than a preset first difference threshold, the second difference is less than a preset second difference threshold, the third difference is less than a preset third difference threshold, and the fourth difference is less than a preset fourth difference threshold; the fourth condition includes that the number of sampling rows satisfying the third condition exceeds a preset second number threshold.

[0225] For example, for the images in the first video that are not identified as monochrome images, taking the SBS format as an example, according to the characteristic that there is left-right parallax between the two images in the image, the pixel feature analysis is performed in the same row. Left-right parallax means that the two images are obtained by cameras simulating binocular positions, and there is horizontal parallax. The positions of the same point of the object in the two images are offset in parallel directions, such as Figure 7 As shown. Based on this feature, some rows of the two images are sampled and the gray value features are compared to determine whether they are left and right disparity maps. The specific process is as follows:

[0226] Convert the image to a grayscale image, and then divide the grayscale matrix into left and right parts to obtain left and right divided images, and take N sampling rows (for example, N=20) from the left and right divided images respectively to obtain the grayscale value matrices L and R corresponding to the left and right divided images. Among them, the grayscale value matrices L and R both have N rows and width / 2 (half the width of the image) columns. For example, L[i, j] represents the grayscale value corresponding to the pixel in the i-th row and j-th column in the left divided image. Calculate the mean value Mean_L and Mean_R of the grayscale values ​​of the grayscale value matrices L and R corresponding to the left and right divided images row by row, the standard deviation S_L and S_R of the grayscale values, the location MaxIndex_L and MaxIndex_R of the maximum grayscale value, and the location MinIndex_L and MinIndex_R of the minimum grayscale value, and make the following judgments:

[0227] hit3= abs(Mean_L - Mean_R) < M_TH (6);

[0228] && abs(S_L - S_R) < S_TH (7);

[0229] &&abs(MaxIndex_L-MaxIndex_R) <INDEX_TH1(8);

[0230] && abs(MinIndex_L - MinIndex_R) < INDEX_TH2 (9);

[0231] Among them, hit3 represents that the current row meets the requirements. M_TH represents the first difference threshold, S_TH represents the second difference threshold, INDEX_TH1 represents the third difference threshold, and INDEX_TH2 represents the fourth difference threshold. It should be noted that in the embodiment of the present invention, the values ​​of the first difference threshold, the second difference threshold, the third difference threshold, and the fourth difference threshold are not specifically limited. For example, the first difference threshold can be 25, the second difference threshold can be 15, the third difference threshold can be the screen width / 10, and the fourth difference threshold can be the screen width / 10.

[0232] The number of sampling rows that meet the requirements of the above formulas (6), (7), (8), and (9) is calculated. If the number of sampling rows that meet the requirements is greater than the second number threshold, it is considered that the picture is composed of two similar images. Otherwise, it is considered that the picture is not composed of two similar images. It should be noted that in the embodiment of the present invention, the value of the second number threshold is not specifically limited. For example, the second number threshold can be N×80%.

[0233] In an embodiment of the present invention, one or more of the above recognition methods may be used to perform joint recognition of 3D formats to improve the accuracy of 3D format recognition. Figure 8 As shown, it is started to determine whether the current frame is in 3D format, and then according to the method of histogram analysis or grayscale standard deviation, it is determined whether the current frame is a monochrome image; if not, the next frame is extracted, and it is restarted to determine whether the next frame is in 3D format; if so, based on the principle that the center line edge has obvious difference, it is determined whether the current frame is composed of two images spliced ​​together; if not, the next frame is extracted, and it is restarted to determine whether the next frame is in 3D format; if so, based on the principle of dual image similarity, it is determined whether the current frame is composed of two similar images spliced ​​together; if not, the next frame is extracted, and it is restarted to determine whether the next frame is in 3D format; if so, it is considered that the current frame is in 3D format, and the next frame is continuously extracted, and it is restarted to determine whether the next frame is in 3D format.

[0234] Specifically, performing 3D rendering on the picture in the first video according to the human eye position or the position parameter to obtain a second video, and playing the second video includes:

[0235] According to the eye position or the position parameter, interlacing the images in the first video is performed by a pre-deployed 3D rendering capability module to obtain a second video;

[0236] Input the second video into a 3D video display control of a call application, so that the 3D video display control performs the following operations:

[0237] For each 3D image frame of the second video, convert the current 3D image frame into a texture image;

[0238] According to the display size parameter of the current frame 3D video display control and the preset transformation matrix, the texture image is interleaved to obtain an updated texture image after grating splitting;

[0239] The updated texture image is rendered, and the rendered updated texture image is displayed.

[0240] In an embodiment of the present invention, the rendering display of the first video in 3D format includes two processes: 3D interlaced rendering and OpenGL standard rendering; wherein the 3D interlaced rendering is performed in the 3D rendering capability module, and the OpenGL standard rendering is performed in the 3D video display control, taking the user's eye position and the first video being a video ringback tone in SBS format as an example, combined with Fig. 9 The 3D rendering process is described in detail as follows:

[0241] Step A': Create a GLSurfaceView for displaying the video ringback tone.

[0242] A GLSurfaceView will be created in the call application as a 3D video display control for displaying the video ringback tone, and the Renderer of the GLSurfaceView will be set. Optionally, the rendering mode can be set to render when necessary (such as setting the RENDERMODE_WHEN_DIRTY instruction).

[0243] Step B': Create texture ID A (such as TextureId-A), and create SurfaceTexture (surface texture) and Surface (surface) associated with texture ID A. For example, use GLES20.glGenTextures (a texture drawing algorithm of OpenGL) method to create texture ID.

[0244] Step C': Get the VideoCall object, set the VideoCall display surface (DisplaySurface), and bind the above created Surface to the VideoCall as a consumer.

[0245] For example, the call application obtains the VideoCall object provided by the Telephony framework of the terminal operating system, and sets the VideoCall display surface through the setDisplaySurface (a terminal screen display setting method of the terminal operating system) method, so as to bind the above created Surface to the VideoCall as a consumer.

[0246] Step D': Combined with the 3D rendering capability module, input texture ID A, use OpenGL to rearrange the pixels of the frame, and output a new texture ID B (TextureId-B).

[0247] For example, the arrival of SurfaceTexture frames is monitored through the setOnFrameAvailableListener (a terminal video frame monitoring method). When each video ringtone frame arrives, the onFrameAvailable callback method of the listener is triggered, and the requestRender method of GLSurfaceView is executed in the method to apply for rendering a frame.

[0248] In the onDrawFrame (rendering instruction) callback of GLSurfaceView Render, the video ringtone frame rendering is implemented through the OpenGL interface.

[0249] After completing the above settings, the 3D rendering capability module updates the video ringback tone to the OpenGL texture space through surfaceTexture.updateTexImage (a terminal screen update display method of the terminal operating system), and obtains the texture image of each frame for subsequent OpenGL 3D interlaced rendering. Specifically:

[0250] Get the transformation matrix, GLSurfaceView width and height (i.e. the display size parameters of the above 3D video display control) and other basic parameters for subsequent OpenGL 3D interlaced rendering. For example, the transformation matrix can be obtained through the surfaceTexture.getTransformMatrix (a surface texture transformation matrix acquisition method);

[0251] In combination with the above parameters, 3D interlacing processing is performed on the picture corresponding to texture ID A (TextureId-A). For example, for the first video in SBS format, the corresponding views of the left and right eyes are obtained from a frame of the picture, and the pixels of the left and right views are rearranged based on the position of the human eyes to ensure that they match the grating on the device, so that the image seen by the left eye of the user is the left view after grating spectroscopy, and the image seen by the right eye is the right view after grating spectroscopy. The new texture ID B (TextureId-B) of the frame is output and input into the 3D video display control.

[0252] Step E': According to the new texture ID B (TextureId-B), draw to the GLSurfaceView created above according to the OpenGL standard rendering process. That is, execute the OpenGL standard rendering process in the 3D video display control to achieve the naked eye 3D video display of the terminal. Among them, the OpenGL standard rendering process can be referred to above, and will not be repeated here.

[0253] It should be noted that, in general, the video ringback tone and video call of the terminal operating system (such as the Android system) specifically implement the reuse of the same set of view components of the call application. Therefore, the above-mentioned process of rendering 3D format video to the specified GLSurfaceView is also applicable to the video call service. It is only necessary that the call video conforms to the SBS / TAB format to realize the terminal's naked-eye 3D video call function.

[0254] Specifically, when the first video is a video ringback tone, the method further includes:

[0255] Initiating a 3D video ringback tone subscription to the video ringback tone platform;

[0256] Acquire a most recently updated 3D format recognition algorithm from a 3D content platform; wherein the 3D format recognition algorithm is used to perform video format recognition on the video ringback tone sent by the video ringback tone platform;

[0257] Performing video ring back tone media negotiation with the video ring back tone platform, so that the video ring back tone platform queries the 3D content platform for the tag information of the 3D video material to be sent before completing the video ring back tone media negotiation; and when it is found that the 3D video material has the tag information, sending the 3D video material as a video ring back tone to the first terminal; when it is found that the video material does not have the tag information, obtaining a 2D video material as a video ring back tone and sending it to the first terminal;

[0258] The marking information is generated by the 3D content platform after the video format verification of the 3D video material is passed according to the most recently updated 3D format recognition algorithm.

[0259] Considering the possibility of misjudgment of the automatic identification of the 3D format by the first terminal, the embodiment of the present invention introduces a platform-side pre-verification process, with the 3D format as the positive class and the 2D format as the negative class. The 3D format identification algorithm aims at a high accuracy rate (fewer false positive examples), focusing on the identification of 3D videos, so as to improve the success rate of the terminal side in identifying the received video format. It should be understood that the 3D format identification algorithm is the algorithm flow involved in the above-mentioned 3D format identification of the current frame, which will not be repeated here.

[0260] Taking the first video as a video ringback tone as an example, the following Fig.10 , the pre-verification process of the 3D format recognition algorithm is described in detail, which specifically includes the following steps:

[0261] Step 1: The first terminal completes the 3D video ringback tone subscription; specifically, the user initiates the 3D video ringback tone subscription to the video ringback tone platform through the first terminal.

[0262] Step 2: The first terminal uploads the customized 2D video material to the video ringback tone platform.

[0263] Step 3: The video ringback tone platform initiates a 3D content production application to the 3D content platform. The 3D content production application carries 2D video material, so that the 3D content platform converts the 2D video material into a video ringback tone in 3D format by calling a third-party webpage / website.

[0264] Step 4: The administrator can also upload the prepared 3D video material as a video ringback tone to the 3D content platform through a third-party webpage / website.

[0265] Step 5: The administrator maintains the 3D format recognition algorithm and uploads the latest 3D format recognition algorithm.

[0266] Step 6: Regardless of whether it is a video ringback tone corresponding to a prepared 3D video material or a video ringback tone obtained by converting a 2D video material, the 3D content platform uses the latest uploaded 3D format recognition algorithm to perform pre-verification, confirm which video ringback tones can be correctly recognized as 3D format, and mark the video ringback tones that can be correctly recognized as 3D format. It should be noted that the use of the latest uploaded 3D format recognition algorithm for pre-verification can refer to the above-mentioned process of format recognition of the first video, and will not be repeated here.

[0267] Step 7: The first terminal periodically downloads the latest 3D format recognition algorithm from the 3D content platform.

[0268] Step 8: The first terminal performs a video ring back tone negotiation signaling process with the video ring back tone platform. After completion, the video ring back tone platform (including the ring back tone call node) can play the video ring back tone.

[0269] Step 9: Before the video ringback tone platform sends the video ringback tone, it checks the identification information of the current video ringback tone to determine whether the current video ringback tone can be automatically recognized by the latest 3D format recognition algorithm. If it can be recognized, it will be sent normally; if it cannot be recognized, it will enter the Fallback (contingency plan) process and return the video ringback tone or audio and video ringback tone in 2D format. For example, when the identification information of the video ringback tone is 1, the video ringback tone can be automatically recognized by the latest 3D format recognition algorithm, and when the identification information of the video ringback tone is 0, the video ringback tone cannot be automatically recognized by the latest 3D format recognition algorithm.

[0270] Step 10: Assuming that the current video ringback tone can be automatically recognized by the latest 3D format recognition algorithm, the 3D content platform returns the video ringback tone to be sent to the video ringback tone platform.

[0271] Step 11: The video ringback tone platform sends the video ringback tone to the first terminal, and the first terminal calls the latest downloaded 3D format automatic recognition algorithm to complete the recognition and then performs 3D rendering display.

[0272] By introducing the platform-side pre-verification process, the embodiment of the present invention allows the terminal to regularly download the latest 3D content format algorithm, thereby improving the success rate of the terminal side in identifying the received video format.

[0273] Compared with the prior art, the beneficial effects of the embodiments of the present invention are:

[0274] The embodiment of the present invention introduces a 3D format automatic identification algorithm on the terminal side, so that the terminal side can automatically and accurately identify the video format of the received video ringback tone or call video, and then determine whether to perform 3D rendering display according to the actual received video format. On the one hand, it is possible to control the turning on and off of 3D rendering without additional signaling or application layer protocol interaction. On the other hand, it can avoid the picture abnormality caused by the mismatch between the 3D rendering display switch on the terminal side and the actual received video format (for example, 3D format video is rendered and displayed in 2D format, or 2D format video is rendered and displayed in 3D format), thereby improving the naked-eye 3D video display effect on the terminal side, which is suitable for video ringback tone, video call or non-call scenarios.

[0275] The embodiment of the present invention adds a 3D logic management module and a 3D rendering capability module on the terminal side, and creates a 3D video display control and a 2D video display control in the call application, so as to realize naked-eye 3D video display in combination with naked-eye 3D film sources. The terminal side requires little modification, which can effectively reduce the cost of realizing naked-eye 3D video display on existing terminals.

[0276] In an embodiment of the present invention, the 3D format recognition algorithm combines a method for monochrome image recognition based on histogram analysis or grayscale image standard deviation, a method for image stitching recognition based on the principle that center lines and edges are clearly distinguished, and an algorithm for image stitching based on the principle of dual image similarity, which can effectively improve the accuracy of 3D format recognition.

[0277] By introducing the platform-side pre-verification process, the embodiment of the present invention allows the terminal to regularly download the latest 3D content format algorithm, thereby improving the success rate of the terminal side in identifying the received video format.

[0278] See also Fig.11 , Fig.11 The embodiment of the present invention provides a structural block diagram of a naked-eye 3D video display device, wherein the naked-eye 3D video display device comprises:

[0279] The video receiving module 11 is used to receive a first video;

[0280] A video format identification module 12, configured to identify the video format of the first video when the first terminal turns on the 3D display mode;

[0281] The 3D rendering and display module 13 is used to perform 3D rendering on the pictures in the first video to obtain a second video when it is identified that the first video is in 3D format, and play the second video.

[0282] In an optional embodiment, the video receiving module 11 includes:

[0283] A video receiving unit, configured to receive the first video when the first terminal establishes a call connection with the second terminal;

[0284] The first video includes a video ringback tone issued by a video ringback tone platform after the first terminal completes media negotiation or a call video between the first terminal and the second terminal.

[0285] In an optional embodiment, the video format identification module 12 includes:

[0286] A 3D format identification unit, configured to perform 3D format identification on a current frame of each frame in the first video;

[0287] A first judging unit is used to judge whether the number of frames of the picture identified as the 3D format is greater than a preset first frame number threshold when the current frame is identified as the 3D format;

[0288] A 3D format determining unit, configured to determine that the first video is in 3D format;

[0289] A second determination unit, for determining whether the frame number of the identified picture is greater than a preset second frame number threshold;

[0290] a 2D format determining unit, configured to determine that the first video is in 2D format when the number of frames of the identified picture is greater than the second frame number threshold;

[0291] The 3D format identification unit is further configured to perform 3D format identification on a next frame of the picture when the number of frames of the identified picture is not greater than the second frame number threshold.

[0292] In an optional embodiment, the 3D format identification unit includes:

[0293] A monochrome image recognition subunit is used to perform monochrome image recognition on the current frame;

[0294] A splicing image recognition subunit is used to perform splicing image recognition on the current frame;

[0295] When it is identified that the current frame is not a monochrome image and the current frame is formed by splicing two images, it is determined that the current frame is in 3D format; otherwise, it is determined that the current frame is in 2D format.

[0296] In an optional embodiment, the monochrome image recognition subunit includes:

[0297] A target color determination subunit is used to calculate a color histogram of the current frame and determine a color corresponding to a maximum value in the color histogram as a target color;

[0298] The pixel ratio calculation subunit is used to calculate the pixel ratio of the pixels corresponding to the target color in the current frame;

[0299] The first monochrome image determination subunit is used to determine that the current frame image is a monochrome image when the pixel ratio is greater than or equal to a preset ratio threshold; when the pixel ratio is less than the ratio threshold, determine that the current frame image is not a monochrome image.

[0300] In an optional embodiment, the monochrome image recognition subunit includes:

[0301] A standard deviation calculation subunit, used for converting the current frame into a grayscale image and calculating the standard deviation of the grayscale value of the grayscale image;

[0302] The second monochrome image determination subunit is used to determine that the current frame image is not a monochrome image when the standard deviation is greater than a preset standard deviation threshold; and to determine that the current frame image is a monochrome image when the standard deviation is less than or equal to the standard deviation threshold.

[0303] In an optional embodiment, the spliced ​​image recognition subunit includes:

[0304] A Gaussian filter subunit, used for converting the current frame into a grayscale image and performing Gaussian filtering on the grayscale image;

[0305] The edge detection subunit is used to perform edge detection on the grayscale image after Gaussian filtering to obtain a binary image;

[0306] A scanning subunit, configured to scan edge points of a center line area of ​​the binary image; wherein the center line area is an area within a first preset range from a center line of a current frame;

[0307] The third judgment subunit is used to perform continuity analysis on the edge points of the center line area to determine whether the length of the continuous edge of the center line area is greater than a preset length threshold; when the length of the continuous edge of the center line area is greater than the length threshold, it is determined that the current frame is composed of two images spliced ​​together.

[0308] In an optional embodiment, the spliced ​​image recognition subunit includes:

[0309] A YUV color space conversion subunit is used to convert the current frame image into a YUV color space image;

[0310] an absolute difference calculation subunit, for calculating, for each component image in the YUV color space image, the absolute difference between adjacent pixels on both sides of a center line of the component image and the absolute difference between adjacent pixels on the same side of the center line;

[0311] A fourth judgment subunit is used to determine that the current frame is composed of two images when any one of the component images meets a preset component mutation condition;

[0312] Among them, the component mutation conditions include: adjacent pixels on both sides of the center line of the component image simultaneously satisfy the first condition and the second condition; the first condition includes that the difference between the absolute difference of adjacent pixels on both sides of the center line of the component image and the absolute difference of adjacent pixels on the same side of the center line is greater than a preset jump threshold; the second condition includes that the number of adjacent pixels on both sides of the center line of the component image that satisfy the first condition exceeds a preset first number threshold.

[0313] In an optional embodiment, the spliced ​​image recognition subunit includes:

[0314] The image segmentation subunit is used to convert the current frame into a grayscale image and perform an average division process on the grayscale image to obtain two segmented images;

[0315] A sampling subunit, used for sampling the segmented image to obtain a gray value matrix of the corresponding segmented image; wherein the gray value matrix includes gray values ​​of a plurality of sampling rows in the corresponding segmented image;

[0316] A sampling row parameter calculation subunit, used to calculate the average grayscale value, the standard deviation of the grayscale value, the position of the maximum grayscale value and the position of the minimum grayscale value of each sampling row of the segmented image;

[0317] The fourth judgment subunit is used to determine whether the current frame is composed of two images spliced ​​together according to the average grayscale value of the sampling rows of the two segmented images, the standard deviation of the grayscale value, the position of the maximum grayscale value and the position of the minimum grayscale value.

[0318] Wherein, the fourth judgment subunit is specifically used for:

[0319] Calculate the difference between the average value of the grayscale value of the i-th sampling row of the segmented image and the average value of the grayscale value of the i-th sampling row of another segmented image to obtain a first difference; i∈N, N represents the number of sampling rows;

[0320] Calculate the difference between the standard deviation of the grayscale value of the i-th sampling row of the segmented image and the standard deviation of the grayscale value of the i-th sampling row of another segmented image to obtain a second difference;

[0321] Calculate the difference between the position of the maximum gray value of the i-th sampling row of the segmented image and the position of the maximum gray value of the i-th sampling row of another segmented image to obtain a third difference;

[0322] Calculate the difference between the position where the minimum grayscale value of the i-th sampling row of the segmented image is located and the position where the minimum grayscale value of the i-th sampling row of another segmented image is located to obtain a fourth difference;

[0323] When the two segmented images meet a preset similarity condition, determining that the current frame is formed by splicing the two images;

[0324] Among them, the similarity condition includes: the two segmented images simultaneously satisfy the third condition and the fourth condition; the third condition includes that the first difference between the i-th sampling row of the segmented image and the i-th sampling row of the other segmented image is less than a preset first difference threshold, the second difference is less than a preset second difference threshold, the third difference is less than a preset third difference threshold, and the fourth difference is less than a preset fourth difference threshold; the fourth condition includes that the number of sampling rows satisfying the third condition exceeds a preset second number threshold.

[0325] In an optional embodiment, the method further includes:

[0326] An image extraction module, used for extracting the first non-monochrome image in the first video before performing video format recognition on the first video;

[0327] A hash calculation module, used for converting the non-monochromatic image into a first grayscale image of a set size, and calculating a hash value of the first grayscale image;

[0328] A Hamming distance calculation module, used for calculating the Hamming distance between the hash value of the first grayscale image and the hash value in a preset database;

[0329] an identification result acquisition module, configured to acquire, when the Hamming distance is less than a preset distance threshold, a video format identification result corresponding to a corresponding hash value in the database as a video format identification result of the first video;

[0330] The recognition result storage module is used to save the video format recognition result of the first video into a preset database with the hash value as the key and the video format recognition result of the first video as the value when the Hamming distance is not less than the distance threshold, and perform video format recognition on the first video.

[0331] In an optional embodiment, the device further includes:

[0332] A video parameter reading module, configured to read the resolution and bit rate of the first video after identifying the video format of the first video;

[0333] A display mode switching module, configured to switch the first video to a 2D display mode when the resolution is less than a preset resolution threshold and the bit rate is less than a preset bit rate threshold;

[0334] The display mode maintaining module is used to maintain the 3D display mode when the resolution is not less than the resolution threshold or the bit rate is not less than the bit rate threshold.

[0335] In an optional embodiment, the 3D rendering display module 13 includes:

[0336] A position parameter acquisition unit, used to acquire a front-view image of a user of the first terminal, and perform eye tracking on the front-view image to determine the eye position of the user; or to acquire a preset position parameter;

[0337] A rendering and display unit is used to perform 3D rendering on the picture in the first video according to the human eye position or the position parameter to obtain a second video and play the second video.

[0338] In an optional embodiment, the rendering and display unit includes:

[0339] a 3D interlacing subunit, configured to interlace the images in the first video according to the eye position or the position parameter through a pre-deployed 3D rendering capability module to obtain a second video;

[0340] The video input subunit is used to input the second video into the 3D video display control of the call application, so that the 3D video display control performs the following operations:

[0341] For each 3D image frame of the second video, convert the current 3D image frame into a texture image;

[0342] According to the display size parameter of the current frame 3D video display control and the preset transformation matrix, the texture image is interleaved to obtain an updated texture image after grating splitting;

[0343] The updated texture image is rendered, and the rendered updated texture image is displayed.

[0344] In an optional embodiment, when the first video is a video ring back tone, the device further includes:

[0345] A 3D video ringback tone subscription module, used to initiate a 3D video ringback tone subscription to the video ringback tone platform;

[0346] A 3D format algorithm acquisition module, used to acquire the most recently updated 3D format recognition algorithm from the 3D content platform; wherein the 3D format recognition algorithm is used to perform video format recognition on the video ringback tone sent by the video ringback tone platform;

[0347] a video ring back tone media negotiation module, configured to perform video ring back tone media negotiation with the video ring back tone platform, so that the video ring back tone platform queries the 3D content platform for the tag information of the 3D video material to be sent before completing the video ring back tone media negotiation; and when it is found that the 3D video material has the tag information, the 3D video material is sent to the first terminal as a video ring back tone, and when it is found that the video material does not have the tag information, the 2D video material is obtained and sent to the first terminal as a video ring back tone;

[0348] The marking information is generated by the 3D content platform after the video format verification is performed on the 3D video material according to the most recently updated 3D format recognition algorithm and after the video format verification passes.

[0349] It should be noted that the working process of each module in the naked-eye 3D video display device described in the embodiment of the present invention can refer to the working process of the naked-eye 3D video display method described in the above embodiment, and the technical effect achieved is also the same as the naked-eye 3D video display method described in the above embodiment, which will not be repeated here.

[0350] See also Fig.12 , Fig.12 1 is a block diagram of a naked-eye 3D video display device provided by an embodiment of the present invention. The naked-eye 3D video display device includes a processor 21, a memory 22, and a computer program stored in the memory 22 and executable on the processor 21. When the processor 21 executes the computer program, the steps in the above-mentioned naked-eye 3D video display method embodiments are implemented, such as steps S11 to S13.

[0351] Exemplarily, the computer program may be divided into one or more modules / units, which are stored in the memory 22 and executed by the processor 21 to implement the present invention. The one or more modules / units may be a series of computer program instruction segments capable of implementing specific functions, which are used to describe the execution process of the computer program in the naked-eye 3D video display device.

[0352] The naked-eye 3D video display device may include, but is not limited to, a processor 21 and a memory 22. Those skilled in the art will appreciate that the schematic diagram is merely an example of a naked-eye 3D video display device and does not constitute a limitation on the naked-eye 3D video display device, and may include more or fewer components than shown in the diagram, or may combine certain components, or different components, for example, the naked-eye 3D video display device may also include input and output devices, network access devices, buses, etc.

[0353] The processor 21 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor 21 is the control center of the naked-eye 3D video display device, and uses various interfaces and lines to connect various parts of the entire naked-eye 3D video display device.

[0354] The memory 22 can be used to store the computer program and / or module, and the processor 21 realizes various functions of the naked eye 3D video display device by running or executing the computer program and / or module stored in the memory 22, and calling the data stored in the memory 22. The memory 22 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory 22 can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SecureDigital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0355] Wherein, if the module / unit integrated in the naked eye 3D video display device is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor 21. Wherein, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signal, telecommunication signal and software distribution medium, etc.

[0356] It should be noted that the device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. In addition, in the accompanying drawings of the device embodiments provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines. A person of ordinary skill in the art may understand and implement it without paying any creative effort.

[0357] The above is a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, many improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications are also considered to be within the scope of protection of the present invention.

Claims

1. A naked eye 3D video display method, characterized in that: Applied to the first terminal, comprising: receiving a first video; When the first terminal turns on the 3D display mode, identifying the video format of the first video; When it is identified that the first video is in 3D format, 3D rendering is performed on the images in the first video to obtain a second video, and the second video is played.

2. The naked eye 3D video display method according to claim 1, characterized in that: The receiving the first video includes: When the first terminal establishes a call connection with the second terminal, receiving the first video; The first video includes a video ringback tone issued by a video ringback tone platform after the first terminal completes media negotiation or a call video between the first terminal and the second terminal.

3. The naked eye 3D video display method according to claim 1, characterized in that: The performing video format identification on the first video includes: For each frame in the first video, performing 3D format identification on the current frame; When the current frame is identified as being in 3D format, determining whether the number of frames of the image identified as being in 3D format is greater than a preset first frame number threshold; If yes, determining that the first video is in 3D format; If not, determining whether the number of frames of the identified picture is greater than a preset second frame number threshold; When the number of frames of the identified picture is greater than the second frame number threshold, determining that the first video is in 2D format; When the number of frames of the identified picture is not greater than the second frame number threshold, 3D format identification is performed on the next frame.

4. The naked eye 3D video display method according to claim 3, characterized in that: The performing 3D format identification on the current frame includes: Perform monochrome image recognition on the current frame; Perform splicing image recognition on the current frame; When it is identified that the current frame is not a monochrome image and the current frame is formed by splicing two images, it is determined that the current frame is in 3D format; otherwise, it is determined that the current frame is in 2D format.

5. The naked eye 3D video display method according to claim 4, characterized in that: The performing monochrome image recognition on the current frame includes: Calculate the color histogram of the current frame, and determine the color corresponding to the maximum value in the color histogram as the target color; Calculate the pixel ratio of the target color in the current frame. When the pixel ratio is greater than or equal to a preset ratio threshold, determining that the current frame is a monochrome image; When the pixel ratio is less than the ratio threshold, it is determined that the current frame is not a monochrome image.

6. The naked eye 3D video display method according to claim 4, characterized in that: The performing monochrome image recognition on the current frame includes: Convert the current frame into a grayscale image, and calculate the standard deviation of the grayscale value of the grayscale image; When the standard deviation is greater than a preset standard deviation threshold, determining that the current frame is not a monochrome image; When the standard deviation is less than or equal to the standard deviation threshold, it is determined that the current frame is a monochrome image.

7. The naked eye 3D video display method according to claim 4, characterized in that: The image splicing and recognition of the current frame includes: Convert the current frame into a grayscale image, and perform Gaussian filtering on the grayscale image; Perform edge detection on the grayscale image after Gaussian filtering to obtain a binary image; Scan edge points of a center line area of ​​the binary image; wherein the center line area is an area within a first preset range from a center line of a current frame; Performing continuity analysis on the edge points of the centerline area to determine whether the length of the continuous edge of the centerline area is greater than a preset length threshold; When the length of the continuous edge of the center line area is greater than the length threshold, it is determined that the current frame is formed by splicing two images.

8. The naked eye 3D video display method according to claim 4, characterized in that: The image splicing and recognition of the current frame includes: Convert the current frame into a YUV color space image; For each component image in the YUV color space image, respectively calculating the absolute difference between adjacent pixels on both sides of a center line of the component image and the absolute difference between adjacent pixels on the same side of the center line; When any one of the component images satisfies a preset component mutation condition, determining that the current frame is composed of two images spliced ​​together; Among them, the component mutation conditions include: adjacent pixels on both sides of the center line of the component image simultaneously satisfy the first condition and the second condition; the first condition includes that the difference between the absolute difference of adjacent pixels on both sides of the center line of the component image and the absolute difference of adjacent pixels on the same side of the center line is greater than a preset jump threshold; the second condition includes that the number of adjacent pixels on both sides of the center line of the component image that satisfy the first condition exceeds a preset first number threshold.

9. The naked eye 3D video display method according to claim 4, characterized in that: The performing splicing image recognition on the current frame includes: Convert the current frame into a grayscale image, and perform an average division process on the grayscale image to obtain two segmented images; Sampling the segmented image to obtain a gray value matrix of the corresponding segmented image; wherein the gray value matrix includes gray values ​​of a plurality of sampled rows in the corresponding segmented image; Calculate the average value of the grayscale value, the standard deviation of the grayscale value, the position of the maximum grayscale value, and the position of the minimum grayscale value of the sampled rows of each segmented image; According to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value and the position of the minimum grayscale value, it is determined whether the current frame is formed by splicing two images.

10. The naked eye 3D video display method according to claim 9, characterized in that: The step of determining whether the current frame is composed of two images spliced ​​together according to the average value of the grayscale values ​​of the sampled rows of the two segmented images, the standard deviation of the grayscale values, the position of the maximum grayscale value, and the position of the minimum grayscale value comprises: Calculate the difference between the average value of the grayscale value of the i-th sampling row of the segmented image and the average value of the grayscale value of the i-th sampling row of another segmented image to obtain a first difference; i∈N, N represents the number of sampling rows; Calculate the difference between the standard deviation of the grayscale value of the i-th sampling row of the segmented image and the standard deviation of the grayscale value of the i-th sampling row of another segmented image to obtain a second difference; Calculate the difference between the position of the maximum gray value of the i-th sampling row of the segmented image and the position of the maximum gray value of the i-th sampling row of another segmented image to obtain a third difference; Calculate the difference between the position where the minimum grayscale value of the i-th sampling row of the segmented image is located and the position where the minimum grayscale value of the i-th sampling row of another segmented image is located to obtain a fourth difference; When the two segmented images meet a preset similarity condition, determining that the current frame is formed by splicing the two images; Among them, the similarity condition includes: the two segmented images simultaneously satisfy the third condition and the fourth condition; the third condition includes that the first difference between the i-th sampling row of the segmented image and the i-th sampling row of the other segmented image is less than a preset first difference threshold, the second difference is less than a preset second difference threshold, the third difference is less than a preset third difference threshold, and the fourth difference is less than a preset fourth difference threshold; the fourth condition includes that the number of sampling rows satisfying the third condition exceeds a preset second number threshold.

11. The naked eye 3D video display method according to claim 3, characterized in that: Before the video format identification is performed on the first video, the method further includes: Extracting the first non-monochrome image in the first video; Convert the non-monochrome image into a first grayscale image of a set size, and calculate a hash value of the first grayscale image; Calculating the Hamming distance between the hash value of the first grayscale image and the hash value in the preset database; When the Hamming distance is less than a preset distance threshold, obtaining a video format recognition result corresponding to a corresponding hash value in the database as a video format recognition result of the first video; When the Hamming distance is not less than the distance threshold, the hash value is used as the key and the video format recognition result of the first video is used as the value and saved in a preset database, and the video format recognition is performed on the first video.

12. The naked eye 3D video display method according to claim 2, characterized in that: After performing video format identification on the first video, the method further includes: Read the resolution and bit rate of the first video; When the resolution is less than a preset resolution threshold and the bit rate is less than a preset bit rate threshold, switching the first video to a 2D display mode; When the resolution is not less than the resolution threshold or the bit rate is not less than the bit rate threshold, the 3D display mode is maintained.

13. The naked eye 3D video display method according to claim 1 or 2, characterized in that: The performing 3D rendering on the picture in the first video to obtain a second video, and playing the second video includes: Acquire a front-view image of a user of the first terminal, and perform eye tracking on the front-view image to determine the eye position of the user; or acquire preset position parameters; According to the human eye position or the position parameter, the picture in the first video is rendered in 3D to obtain a second video, and the second video is played.

14. The naked eye 3D video display method according to claim 13, characterized in that: The performing 3D rendering on the picture in the first video according to the human eye position or the position parameter to obtain a second video, and playing the second video includes: According to the human eye position or the position parameter, interlacing the images in the first video is performed by a pre-deployed 3D rendering capability module to obtain a second video; Input the second video into a 3D video display control of a call application, so that the 3D video display control performs the following operations: For each 3D image frame of the second video, convert the current 3D image frame into a texture image; According to the display size parameter of the current frame 3D video display control and the preset transformation matrix, the texture image is interleaved to obtain an updated texture image after grating splitting; The updated texture image is rendered, and the rendered updated texture image is displayed.

15. The naked eye 3D video display method according to claim 2, characterized in that: When the first video is a video ringback tone, the method further includes: Initiating a 3D video ringback tone subscription to the video ringback tone platform; Acquire a most recently updated 3D format recognition algorithm from a 3D content platform; wherein the 3D format recognition algorithm is used to perform video format recognition on the video ringback tone sent by the video ringback tone platform; Performing video ring back tone media negotiation with the video ring back tone platform, so that the video ring back tone platform queries the 3D content platform for the tag information of the 3D video material to be sent before completing the video ring back tone media negotiation; and when it is found that the 3D video material has the tag information, sending the 3D video material as a video ring back tone to the first terminal; when it is found that the video material does not have the tag information, obtaining a 2D video material as a video ring back tone and sending it to the first terminal; The marking information is generated by the 3D content platform after the video format verification of the 3D video material is passed according to the most recently updated 3D format recognition algorithm.

16. A naked-eye 3D video display device, characterized in that: include: A video receiving module, used for receiving a first video; A video format identification module, configured to identify the video format of the first video when the first terminal turns on the 3D display mode; The 3D rendering and display module is used to perform 3D rendering on the pictures in the first video to obtain a second video and play the second video when it is recognized that the first video is in 3D format.

17. A naked eye 3D video display device, characterized in that: include: A processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the naked-eye 3D video display method according to any one of claims 1 to 15 when executing the computer program.

18. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located is controlled to execute the naked-eye 3D video display method according to any one of claims 1 to 15.

19. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instruction is executed by a processor, the naked-eye 3D video display method described in any one of claims 1 to 15 is implemented.

Citation Information

Cited By

  • Remote driving and remote monitoring method and system based on unmanned platform

    CN120276441A