CN109901710B - Media file processing method and device, storage medium and terminal - Google Patents

Media file processing method and device, storage medium and terminal Download PDF

Info

Publication number
CN109901710B
CN109901710B CN201910055011.2A CN201910055011A CN109901710B CN 109901710 B CN109901710 B CN 109901710B CN 201910055011 A CN201910055011 A CN 201910055011A CN 109901710 B CN109901710 B CN 109901710B
Authority
CN
China
Prior art keywords
display area
display
depth
field
area
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910055011.2A
Other languages
Chinese (zh)
Other versions
CN109901710A (en
Inventor
王曜
钱靖
余志雄
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910055011.2A priority Critical patent/CN109901710B/en
Publication of CN109901710A publication Critical patent/CN109901710A/en
Application granted granted Critical
Publication of CN109901710B publication Critical patent/CN109901710B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/011Arrangements for interaction with the human body, e.g. for user immersion in virtual reality
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T19/00Manipulating 3D models or images for computer graphics
    • G06T19/006Mixed reality

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Graphics (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Human Computer Interaction (AREA)
  • Controls And Circuits For Display Device (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention discloses a media file processing method and device, a storage medium and a terminal. Wherein, the method comprises the following steps: determining the depth of field of each pixel point in the display area; detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; taking the average value of the depth of field of all the pixels in the first display area as the depth of field of the first display area, or taking the maximum value of the depth of field of the pixels in the first display area as the depth of field of the first display area, or taking the minimum value of the depth of field of the pixels in the first display area as the depth of field of the first display area, or taking the weighted average value of the pixels in the first display area as the depth of field of the first display area; and adjusting the definition of the display area in the display interface based on the depth of field of the first display area. The invention solves the technical problem of convergence regulation conflict.

Description

Media file processing method and device, storage medium and terminal
Technical Field
The invention relates to the field of virtual reality control, in particular to a media file processing method and device, a storage medium and a terminal.
Background
The human visual system provides convergence accommodation (both eyes normally look inward when looking at near objects; the visual axis diverges when looking at distant objects) and focus accommodation (the crystalline lens is adjusted to focus light on the retina) when viewing different near and far objects. In real life, when the human visual system views an object, convergence adjustment and focus adjustment occur at the same time, and humans have become accustomed to this manner.
In a virtual reality system, the scenes seen by human beings are all displayed by a display screen. However, the light from the screen has no depth information and the focal point of the eyes is fixed on the screen, so that the accommodation of the focal points of the eyes is not matched with the depth sense of the scenery, thereby causing a convergence accommodation conflict.
Disclosure of Invention
The embodiment of the invention provides a media file processing method and device, a storage medium and a terminal, which are used for at least solving the technical problem of convergence regulation conflict.
According to an aspect of an embodiment of the present invention, there is provided a method for processing a media file, the method including: determining the depth of field of each pixel point in the display area; detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; taking an average value of the depths of field of all the pixels in the first display area as the depth of field of the first display area, or taking a maximum value of the depths of field of the pixels in the first display area as the depth of field of the first display area, or taking a minimum value of the depths of field of the pixels in the first display area as the depth of field of the first display area, or taking a weighted average value of the pixels in the first display area as the depth of field of the first display area; and adjusting the definition of a display area in the display interface based on the depth of field of the first display area, wherein the definition of the adjusted first display area is higher than that of the adjusted second display area, and the second display area is all or part of the display interface except the first display area.
As an optional example, the adjusting the definition of the presentation area in the presentation interface based on the depth of field of the first presentation area comprises: determining a display area with different depth of field from the first display area in the display interface of the media file as the second display area; setting the definition of a second display area in the display interface to be lower than the definition of the first display area.
As an alternative example, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface includes: acquiring the depth of field of each sub-display area in the second display area; determining a depth difference between the depth of field of each sub-presentation area in the second presentation area and the depth of field of the first presentation area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
As an alternative example, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface includes: gradually reducing a sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area.
As an alternative example, detecting a first presentation area at which the user gazes in the presentation interface of the media file comprises: detecting a point of regard of the user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
As an optional example, the adjusting the definition of the presentation area in the presentation interface based on the depth of field of the first presentation area comprises: adjusting a display resolution of a display area in the display interface based on the depth of field of the first display area.
As an alternative example, the media file comprises a static file.
As an optional example, the determining the depth of field of each pixel point in the display area includes: determining a parallax of a user of a presentation device viewing a media file using the presentation device; and calculating the depth of field of each pixel point in each display area of the media file by using the parallax.
According to another aspect of the embodiments of the present invention, there is also provided a method for processing a media file, the method including: detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; acquiring the depth of field of the first display area in the display interface of the media file; acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a sub-display area, which is farther away from the first display area than a preset distance, in the third display area to be lower than the definition of the first display area, wherein the definition of the display block in the sub-display area is lower the farther the sub-display area is away from the first display area.
As an optional example, in the presentation interface for acquiring the media file, before a third presentation area having the same depth of field as the first presentation area, the method further includes: determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; setting the definition of a second display area in the display interface to be lower than the definition of the first display area.
As an alternative example, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface includes: acquiring the depth of field of each sub-display area in the second display area; determining a depth difference between the depth of field of each sub-presentation area in the second presentation area and the depth of field of the first presentation area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
As an alternative example, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface includes: gradually reducing a sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area.
As an alternative example, detecting a first presentation area at which a user of the presentation device gazes in a presentation interface of a media file comprises: detecting a point of regard of the user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
As an optional example, adjusting the definition of the presentation area in the presentation interface based on the depth of field includes: adjusting a display resolution of a display area in the display interface based on the depth of field.
As an alternative example, the media file comprises a static file.
According to another aspect of the embodiments of the present invention, there is also provided a media file processing apparatus, including: the first determining unit is used for determining the depth of field of each pixel point in the display area; the device comprises a detection unit, a display unit and a control unit, wherein the detection unit is used for detecting a first display area watched by a user of display equipment in a display interface of a media file, the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; a second determining unit, configured to use an average of the depths of field of all the pixels in the first display area as the depth of field of the first display area, or use a maximum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a minimum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a weighted average of the pixels in the first display area as the depth of field of the first display area; and the adjusting unit is used for adjusting the definition of the display area in the display interface based on the depth of field of the first display area, wherein the definition of the adjusted first display area is higher than that of the adjusted second display area, and the second display area is all or part of the display interface except the first display area.
As an optional example, the adjusting unit includes: the first determining module is used for determining a display area with different depth of field from the first display area in the display interface of the media file as the second display area; the display interface comprises a setting module, a display module and a display module, wherein the setting module is used for setting the definition of a second display area in the display interface to be lower than that of the first display area.
As an optional example, the setting module includes: the acquisition submodule is used for acquiring the depth of field of each sub-display area in the second display area; a determining submodule, configured to determine a depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; the first setting submodule is used for setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
As an optional example, the setting module includes: and the second setting submodule is used for gradually reducing the definition of the sub display area in the second display area which takes the first display area as the center and is arranged along a preset radiation path, wherein the preset radiation path is a radiation path far away from the first display area.
As an alternative example, the detection unit includes: the detection module is used for detecting the point of regard of the user in the display interface of the media file; and the acquisition module is used for acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
As an optional example, the adjusting unit includes: and the adjusting module is used for adjusting the display resolution of the display area in the display interface based on the depth of field of the first display area.
As an optional example, the adjusting unit includes: and the adjusting module is used for adjusting the display resolution of the display area in the display interface based on the depth of field of the first display area.
As an alternative example, the media file comprises a static file.
As an optional example, the first determination unit includes: a second determining module, configured to determine a parallax of a user of a presentation device viewing a media file using the presentation device; and the calculating module is used for calculating the depth of field of each pixel point in each display area of the media file by using the parallax.
According to another aspect of the embodiments of the present invention, there is also provided a media file processing apparatus, including: the device comprises a detection unit, a display unit and a control unit, wherein the detection unit is used for detecting a first display area watched by a user of display equipment in a display interface of a media file, the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; the first obtaining unit is used for obtaining the depth of field of the first display area in the display interface of the media file; the second obtaining unit is used for obtaining a third display area which has the same depth of field as the first display area in the display interface of the media file; the first setting unit is used for setting the definition of a sub-display area, which is located in the third display area and is away from the first display area by a preset distance, to be lower than the definition of the first display area, wherein the farther the sub-display area is away from the first display area, the lower the definition of the display block in the sub-display area is.
As an optional example, the apparatus further comprises: a determining unit, configured to determine, in the presentation interface for obtaining the media file, a display area, which has a depth of field different from that of the first presentation area, in the presentation interface for the media file as a second presentation area before a third presentation area, which has the same depth of field as that of the first presentation area; the second setting unit is used for setting the definition of a second display area in the display interface to be lower than that of the first display area.
As an alternative example, the second setting unit includes: the first acquisition module is used for acquiring the depth of field of each sub-display area in the second display area; a determining module, configured to determine a depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; the first setting module is used for setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
As an alternative example, the second setting unit includes: and the second setting module is used for gradually reducing the definition of a sub display area in a second display area which takes the first display area as the center and is arranged along a preset radiation path, wherein the preset radiation path is a radiation path far away from the first display area.
As an alternative example, the detection unit includes: the detection module is used for detecting the point of regard of the user in the display interface of the media file; and the second acquisition module is used for acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
As an optional example, the apparatus further comprises: and the adjusting unit is used for adjusting the display resolution of the display area in the display interface based on the depth of field.
As an alternative example, the media file comprises a static file.
According to still another aspect of the embodiments of the present invention, there is also provided a storage medium having a computer program stored therein, wherein the computer program is configured to execute the above-mentioned media file processing method when running.
According to another aspect of the embodiments of the present invention, there is also provided a terminal, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the processing method of the media file through the computer program.
In the embodiment of the invention, after the first display area watched by the user of the display equipment is detected, the depth of field of the first display area is determined according to the depth of field of each pixel point in the first display area, and the definition of the display area is further adjusted based on the depth of field of the first display area, so that when the focus of the visual system of the user is positioned on the screen of the display equipment, the focus adjustment of the eyes is matched with the depth information of the display interface, the convergence adjustment and the focus adjustment occur simultaneously, the convergence adjustment conflict is eliminated, and the technical problem of the convergence adjustment conflict is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
FIG. 1 is a schematic view of convergence adjustment and focus adjustment;
FIG. 2 is a diagram of a hardware environment for a method of processing a media file according to an embodiment of the invention;
FIG. 3 is a flow chart of an alternative method of processing media files in accordance with an embodiment of the present invention;
FIG. 4 is a first interface diagram illustrating an alternative method for processing a media file according to an embodiment of the present invention;
FIG. 5 is a second schematic interface diagram illustrating an alternative method for processing a media file according to an embodiment of the present invention;
FIG. 6 is a third interface diagram illustrating an alternative media file processing method according to an embodiment of the present invention;
FIG. 7 is a fourth interface diagram illustrating an alternative media file processing method according to an embodiment of the present invention;
FIG. 8 is a schematic diagram of an alternative media file processing device according to an embodiment of the invention; and
fig. 9 is a block diagram of a terminal according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
First, partial terms or terms appearing in the description of the embodiments of the present invention are applied to the following explanations:
GPU: graphics Processing Unit, Graphics processor.
VR: virtual Reality is a computer simulation system which can create and experience a Virtual world, and the system utilizes a computer to generate a simulated Virtual environment, and is a system simulation of multi-source information fusion interactive three-dimensional dynamic views and entity behaviors.
Rendering: the process of making the content into a final effect or animation.
Convergence adjustment: the examinee is instructed to watch the object, usually the tip of the examiner's index, out of the predetermined distance, and gradually approach the object to the base of the examinee's nose, and at this time, the cohesion of the examinee's eyes is observed, which is called vergence reflex. Specifically, as shown in fig. 1, the radial axis adjustment and the focal length adjustment in the real world are consistent, and the visual perception of the human visual system for viewing scenes at different depths is different, for example, the dashed line in fig. 1 represents the information module to be viewed, i.e., the left and right edges are blurred, and the middle is clear; in a virtual reality scene, a human uses the head-mounted equipment to watch scenery, the radial axis adjustment and the focal length adjustment are inconsistent, the visual perception that the human visual system watches different depths is the same, and all data have the same definition. This conflict of vergence accommodation, shown in fig. 1, is contrary to the human daily physiological laws, resulting in fatigue and vertigo of the human visual system.
That is, in the virtual reality system, the scene viewed by human beings is displayed on the flat display screen, and the focus and convergence adjustment are inconsistent, which causes the conflict of the convergence and convergence adjustment, resulting in visual fatigue and vertigo feeling after the virtual reality device is worn.
In view of the above problem of the convergence adjustment conflict, embodiments of the present invention provide an embodiment of a method for processing a media file, which can solve the problems.
The above-described media file processing method can be applied to a hardware environment formed by the server 202 and the terminal 204 as shown in fig. 2. As shown in fig. 2, a server 202 is connected to a terminal 204 through a network including, but not limited to: the terminal 204 is not limited to a PC, a mobile phone, a tablet computer, etc. the terminal may be a wide area network, a metropolitan area network, or a local area network. The media file processing method according to the embodiment of the present invention may be executed by the server 202, the terminal 204, or both the server 202 and the terminal 204. The terminal 104 may execute the media file processing method according to the embodiment of the present invention by a client installed thereon.
Optionally, the terminal may be a display device of a media file, the display device may provide a virtual reality scene in which the media file is displayed, and the display device may include virtual reality hardware, for example, a virtual reality head display device (head mounted display), a binocular omnidirectional display, liquid crystal shutter glasses, a virtual reality display system, smart glasses, and the like.
The virtual reality head display device is a head-mounted stereoscopic display which utilizes the difference of information acquired by the left eye and the right eye of a person to guide a user to generate a feeling of the user in a virtual environment. A binocular omnidirectional display is a stereoscopic display device coupled to a head. Liquid crystal shutter glasses: two images of the left and right eyes are generated by a computer respectively, and are displayed on corresponding screens in a time-sharing alternating mode after being subjected to synthesis processing.
Fig. 3 is a flowchart of an alternative media file processing method according to an embodiment of the present invention, and as shown in fig. 3, the method may include the following steps:
step S302, detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
optionally, before step S302, the depth of field of each pixel in a display area may also be determined, where the number of the display areas is multiple, and each display area corresponds to one or more pixels.
Step S304, obtaining the depth of field of the first display area in the display interface of the media file;
optionally, in step S304, the obtaining of the depth of field of the first display area in the display interface of the media file may be that an average value of the depth of field of all the pixels in the first display area is used as the depth of field of the first display area, or a maximum value of the depth of field of the pixels in the first display area is used as the depth of field of the first display area, or a minimum value of the depth of field of the pixels in the first display area is used as the depth of field of the first display area, or a weighted average value of the pixels in the first display area is used as the depth of field of the first display area.
Step S306, adjusting the definition of the display area in the display interface based on the depth of field, where the definition of the adjusted first display area is higher than the definition of the adjusted second display area, and the second display area is all or part of the display interface except the first display area.
Through the steps S302 to S306, after detecting the first display area watched by the user in the display interface of the media file, based on the depth of field of the first display area in the display interface, the definition of the media file in the display area is adjusted so that the definition of the adjusted first display area is higher than the definition of all or part of the other areas, in the above embodiment, the definition of the display interface of the media file is adjusted through the depth of field of the area watched by the user so that the definitions of different display areas on the display interface are different, so that the information displayed on the display interface includes depth of field information, and thus when the focus of the visual system of the user is fixed on the screen of the display device, the focus adjustment of the eyes is matched with the depth information of the display interface, and the convergence adjustment and the focus adjustment occur simultaneously, thereby eliminating the convergence adjustment conflict, the technical problem of convergence and adjustment conflict of vision is solved.
In the above embodiment, the clarity of the files viewed by the vision system is different, and the conflict of convergence adjustment is eliminated, that is, when the media files are viewed in the virtual reality scene provided by the display device, the focus adjustment and the convergence adjustment occur simultaneously, and the user does not feel visual fatigue and vertigo.
The display device of the embodiment of the application may be a head-mounted display device, and in the technical scheme provided in step S202, the display device is configured to provide a virtual reality scene, a user (i.e., a user of the display device) may operate an operation interface in the virtual reality scene to start playing of a media file, and after the playing of the media file is started, a first display area watched by the user in the display interface of the media file is detected. Optionally, after the display device is started, the image capturing device may be used to capture motion information of a visual system of a user of the display device, and the captured motion information of the visual system is used to determine a first display area, where the first display area may include one or more pixel points. Wherein, image acquisition equipment includes: cameras, webcams, lenses or other imagers, etc.
The above-mentioned motion information of the user's visual system using the image capturing device to capture the display device can be achieved by eye tracking, and the user can operate the screen without touching the screen (the screen may be a screen in a virtual reality scene) by using this technique.
When the eyes of a person look at different directions, the eyes can slightly change, the changes can generate extractable features, and the computer can extract the features through image capture or scanning, so that the change of the eyes can be tracked, the state and the demand of a user can be predicted based on the change of the eyes, the response is carried out, and the purpose of controlling the equipment by using the eyes is achieved.
Wherein the eye tracking may be achieved by at least one of: tracking according to the eyeball and the characteristic change around the eyeball, tracking according to the angle change of the iris, and transmitting the infrared light beam to the iris to extract the characteristics.
In the technical solution provided in step S304, after detecting the first display area in the playing interface of the media file watched by the user, the depth of field of the first display area in the display interface of the media file may be obtained.
The depth of field is a range of a distance between the front and rear of a subject measured at the front edge of a camera lens or other imager, where a sharp image can be obtained. After the focusing is finished, a clear image can be formed in the range before and after the focus, and the distance range before and after the focus is the depth of field. After the image is acquired, the depth of field of the image can be determined based on the circle of confusion, where before and after the focus, the rays diverge from focus to point, the image of the point diverges from the circle to the focus and then to the circle, and the circles before and after the focus are called circle of confusion.
In the embodiment, the depth of field of each display area in the display interface of the media file can be obtained in advance, and after the first display area in the playing interface of the media file watched by the user is detected, the depth of field of the first display area in the display interface of the media file is directly read from the obtained depth of field; or after detecting the first display area in the playing interface of the media file watched by the user, determining the depth of field of each display area in the display interface of the media file, and acquiring the depth of field of the first display area.
According to the embodiment of the invention, before the depth of field of the first display area in the display interface of the media file is obtained, the parallax of the user viewing the media file by using the display device can be determined; calculating the depth of field of each display area in the display interface of the media file by using the parallax; saving the depth of field of each display area to obtain a depth of field file of the media file; the acquiring the depth of field of the display area in the media file comprises the following steps: and reading the depth of field of the first display area from the depth of field file.
In a virtual reality application scene, 3D files seen by the left eye and the right eye of a human vision system have parallax, the depth of field of each display area in a display interface of a media file seen by the left eye is obtained, the depth of field of each display area in the display interface of the media file seen by the right eye is obtained, the depth of field of each display area in the display interface of the media file is calculated by using the parallax of the left eye and the right eye of human eyes when display equipment is used, and further, the depth of field of each pixel point can be recorded. And storing the acquired depth of field data to obtain a depth of field file. After detecting the first presentation area, the depth of view of the first presentation area may be quickly determined using the depth of view file. For example, the average of the depths of field of all the pixels in the first display area may be used as the depth of field of the first display area, the maximum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, the minimum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, and the weighted average of the pixels in the first display area may be used as the depth of field of the first display area.
In the technical solution provided in step S306, the definition of each display area in the display interface of the media file may be adjusted based on the depth of field of the first display area in the display interface of the media file, so as to adjust the definition of the first display area to be the highest, and adjust the definitions of the other display areas to be less clear than the definition of the first display area, for example, the definitions of the other display areas may be adjusted to be clearer or less clear.
In an alternative embodiment, all areas except the first display area in the display interface of the media file may be determined as the second display area, or a part of areas except the first display area in the display interface of the media file may be determined as the second display area, for example, the definition of the adjusted first display area is the display area with the highest definition in the display interface of the entire media file, but other display areas with the same definition as the first display area may be included in the display interface of the adjusted media file.
In an alternative embodiment, adjusting the sharpness of the presentation area in the presentation interface based on the depth of field may include: determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; the definition of the second display area in the display interface is set to be lower than that of the first display area.
The depth of field of each display area in the display interface of the media file is obtained, and each display area can be determined based on a display object (or object) in the display interface of the media file, or can be determined based on whether the depth of field in the display interface is the same, for example, a display area is formed by pixel points belonging to the same display object in the display interface, or a through area formed by pixel points with the same depth of field in the display interface is a display area. Alternatively, a plurality of discrete points may be provided, and a point having a distance from the same center smaller than a predetermined distance may be determined as a point belonging to the same display area, with each of the discrete points as a center.
Of course, there are other methods for determining the display area, which are not limited in this application.
In this embodiment, the definition of the other region having the depth of field different from that of the first presentation region may be set lower than that of the first presentation region.
Specifically, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface may include: acquiring the depth of field of each sub-display area in the second display area; determining the depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
By the embodiment, the information of the media files with depth can be acquired, and the user does not have visual axis convergence conflict and fatigue when watching the information.
In this embodiment, the average value of the depths of field of all the pixels in the sub-display area may be used as the depth of field of the sub-display area, the maximum value of the depths of field of the pixels in the sub-display area may be used as the depth of field of the sub-display area, the minimum value of the depths of field of the pixels in the sub-display area may be used as the depth of field of the sub-display area, and the weighted average value of the pixels in the sub-display area may be used as the depth of field of the sub-display area. This is not limited in this application.
In the above embodiment, the definitions of the second display area may be set to be lower than the definition of the first display area, the definitions of the sub-display areas in the second display area may be set to be the same, and the definitions of the sub-display areas in the second display area may also be set to be different.
The resolution of the region of the second presentation region having a larger depth difference from the depth of field of the first presentation region may be set to a lower resolution, and the resolution of the region of the second presentation region having a smaller depth difference from the depth of field of the first presentation region may be set to a higher resolution.
Here lower and higher for each sub-presentation area in the second presentation area. As shown in fig. 4, the sharpness is represented by the density of the hatched lines, and the higher the density of the hatched lines, the higher the sharpness.
The presentation interface 40 of the media file in fig. 4 comprises three areas, wherein the first area 401 is a first presentation area, i.e. the area where the detected user gazes at the presentation interface of the media file, the second area 402 is a first sub-presentation area in the second presentation area, the depth of field difference between the sub-presentation area and the first presentation area is a, the third area 403 is a second sub-presentation area in the second presentation area, the depth of field difference between the sub-presentation area and the first presentation area is B, assuming a > B, a lower definition can be set for the first sub-presentation area and a higher definition can be set for the second presentation sub-area, but the definition of both the first sub-presentation area and the second sub-presentation area can be lower than that of the first presentation area, so that the definition of the first presentation area is higher than that of the second sub-presentation area, the definition of the second sub-display area is higher than that of the first sub-display area.
Of course, the embodiment shown in fig. 4 is only illustrated as an example, and the shapes of the display area and the sub-display areas in the specific implementation may be irregular shapes, which is not limited in this application, and the second display area may be divided into the number of sub-display areas, which is also not limited in this application.
In another alternative embodiment, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface may comprise: gradually reducing the sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area. By the embodiment, the definition of the display area is selectively reduced, and the data processing amount is reduced under the condition that a user watches the file.
Specifically, the definition may be set according to the distance from the first display area, for example, a second display area located outside the first display area and surrounding the first display area is divided along a predetermined radiation path by taking the first display area as a center or as a reference, as shown in fig. 5, the second display area may include a first sub-display area and a second sub-display area, of course, in a specific implementation, the second display area may include more sub-display areas, and the present application only takes the first sub-display area and the second sub-display area as an example for description.
In the presentation interface 50 of a media file shown in fig. 5, the first sub-presentation area 502 is closer to the first presentation area 501 (compared with the second sub-presentation area), the definition of the first sub-presentation area is set to be higher, the second sub-presentation area 503 is farther from the first presentation area (compared with the first sub-presentation area), the definition of the second sub-presentation area is set to be slightly lower, the definition is represented by the density of the lines filled with the hatching in fig. 5, and the density of the lines filled with the hatching is higher.
Alternatively, in determining the distance between the sub-presentation area and the first presentation area, the distance may be determined by calculating the euclidean distance between the sub-presentation area and the first presentation area.
In another alternative embodiment, adjusting the sharpness of the presentation area in the presentation interface based on the depth of field may include: acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a part of the display interface in the third display area as the definition of the first display area.
Specifically, the setting of the definition of the partial region in the third display region in the display interface to the definition of the first display region may include: and setting the definition of the sub-display area, which is positioned at a distance exceeding the preset distance from the first display area, in the third display area to be lower than that of the first display area.
According to the embodiment, an area with the same depth of field as the first presentation area in the presentation interface of the media file can be determined as the third presentation area, and the definition of a partial area in the third presentation area is set to be the same as the definition of the first presentation area.
In an alternative embodiment, the definition may be set according to the distance from the first display area, for example, the third display area is divided along a predetermined radiation path by taking the first display area as a center or as a reference, the pixel points within a predetermined distance from the first display area are divided into the pixel points in the first sub-display area, and the definition of the first sub-display area in the third display area may be set to be the same as the definition of the first display area.
Dividing the pixel points which are away from the first display area by a preset distance to the pixel points in the second sub-display area, and setting the definition of the second sub-display area in the third display area to be lower than that of the first display area.
Further optionally, the display tiles in the second sub-display area may be set to different resolutions, for example, along the predetermined radiation path, the lower the resolution setting of the display tiles in the second sub-display area farther from the first display area, the higher the resolution setting of the display tiles in the second sub-display area closer to the first display area.
In the above embodiment, adjusting the definition of the presentation area in the presentation interface based on the depth of field may include: and adjusting the display resolution of the display area in the display interface based on the depth of field.
Specifically, the definition of the display area may be adjusted by adjusting the display resolution of the display area. For example, the higher the resolution of the adjustment, the higher the corresponding sharpness; the lower the resolution of the adjustment, the lower the corresponding sharpness.
In an optional embodiment, the definition of the display area may be adjusted by using a gaussian blur processing manner, for example, the higher the set blur parameter is, the lower the definition of the corresponding display area is; the lower the set blur parameter, the higher the definition of the corresponding presentation area.
In yet another alternative embodiment, the definition of the display area may also be adjusted by adjusting the number of grids of different faces of the media file, for example, the greater the number of grids of information on the display interface of the adjusted media file, the higher the definition of the adjusted display area; the less the number of grids of information on the presentation interface of the adjusted media file, the lower the sharpness of the adjusted presentation area.
Of course, the definition of the display area may also be adjusted by using other processing manners for adjusting the definition, which is not limited in this application.
According to an embodiment of the present invention, detecting a first presentation area at which a user of a presentation apparatus gazes in a presentation interface of a media file may include: detecting a point of regard of a user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the watching point, and determining the view range as a first display area.
The gaze point of the user in the presentation interface of the media file may be detected according to the above-mentioned eye tracking technique, and the gaze point may be a pixel point in the presentation interface corresponding to the media file, and since the field of view is at an angle when the human eye gazes at a position, the field of view range of the user's gaze may be determined based on the angle, and the range is determined as a first presentation area, which may include one or more pixel points.
It should be noted that the media files in the above embodiments may include static files, such as pictures, or dynamic files, such as animation, video, and other files.
The present invention also provides a preferred embodiment, and the following describes in detail a preferred embodiment of the present application with reference to fig. 6 and 7, by which a file can be actively rendered according to a depth of field.
This scheme can obtain using in virtual reality's helmet, and specifically, the user can wear this virtual reality helmet, and the user can utilize the motion of handle or eyeball to control the virtual reality helmet.
When the virtual reality helmet is controlled by using the movement of the eyeballs, the eyepoint of the human eyes in a screen (the screen may be a virtual screen of the virtual reality helmet) may be determined by using an eyeball tracking technology, and the eyepoint may be one or more pixel points.
Since the human eye is gazing at a position, the effective comfortable visual field has a predetermined angle, for example, 60 degrees, objects exceeding the predetermined angle range are not sensitive to the human eye, and the subjective feeling of human vision is not affected by the clarity of rendering the part of the scene, so that the GPU rendering task can be reduced by using this characteristic, as shown in fig. 6. In fig. 6, the length of a line segment in a broken line indicates the resolution, and the longer the length of the line segment, the lower the resolution, and the higher the resolution indicated by a solid line than a broken line.
As shown in fig. 6, the embodiment includes three display areas, the first display area having the highest definition, the second display area having the second highest definition, and the third display area having the lowest definition. The first display area includes the gazing point, that is, the definition of the display area in which the gazing point is located is set to be the highest. The remaining settings are lower, which can reduce the amount of computation.
As can be seen from fig. 6, this approach takes into account the human eye gaze point location and renders all foreground and background objects at that location with the same definition.
In particular, the embodiment shown in fig. 6 may render a media file based on a point of gaze. In this scheme, how to reduce the amount of computation of the GPU can be considered from the perspective of the two-dimensional plane. The region level is divided according to the Euclidean distance from the fixation point, and the region far away from the fixation point can be rendered in a lower resolution mode to reduce the definition, so that different definitions can be displayed in one display interface.
This embodiment, which is not visible to the human eye or does not reduce the resolution rendering in the regions near the fixation point of the human eye, because the human eye is not sensitive to those regions, something like the human eye's afterlight is more blurred, which does not affect the user's viewing, and at the same time, reduces the data processing amount.
In an optional manner, the definition of the presentation interface of the media file may be adjusted according to the depth of field of the user's gaze point, as shown in fig. 7, when a person focuses on a certain scene (which may be a presentation area), the depth of other scenes may be blurred based on the depth of the scene.
As shown in fig. 7, the small black triangle indicates the visual focus, the visual focus in the left image is near, the visual focus in the right image is far, and for different focal lengths of the same scene, there is a certain difference between the display areas obtained by processing, but the areas focused by the eyes have high definition, wherein the definition indicated by the dotted line in the image is lower than that indicated by the solid line.
Specifically, in the scheme shown in fig. 7, based on depth rendering, from the perspective of a three-dimensional space, depth information is used to clearly process depth corresponding to a gaze point, and other depths are blurred. The scheme can relieve the uncomfortable feeling caused by the conflict of the visual convergence and adjustment.
With the above-described embodiment, the content in the visual scene is displayed differently depending on the depth of field of the gaze point (depth of field corresponds to focus), and the sense of discomfort due to the convergence accommodation conflict can be alleviated to some extent.
In the virtual reality system, the left eye and the right eye have independent file contents (such as video contents), and the depth map corresponding to each object can be calculated according to the video contents of the left eye and the right eye. Specifically, the disparity of the left and right eyes of the head-mounted device can be utilized to calculate the depth map of the whole scene. When the depth of the scenery at the gazing point is known, the object corresponding to the depth of field can be clarified, and the other objects in the depth of field can be blurred, so that the effect as shown in fig. 7 is achieved.
The discomfort caused by the visual convergence adjustment conflict can be relieved by rendering according to the depth of field, and by the scheme, the feeling of a human eye watching the real world is simulated, and when the human eye focuses on one point, objects with other depth of field can be out of focus and blurred.
It should be further noted that the embodiments shown in fig. 6 and fig. 7 may be combined, that is, the optimized rendering method based on the gazing point area and the gazing point depth.
The two modes are combined, and different renderings are carried out in the visual fixation point area according to the depth of field; reducing resolution rendering in a non-fixation point area; the GPU load can be reduced, and the uncomfortable feeling of the visual convergence adjustment conflict can be relieved, so that the fatigue feeling and dizziness feeling of a user caused by watching under a virtual reality scene are relieved.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
According to another aspect of the embodiment of the invention, a method for processing the media file is also provided. Optionally, as shown in fig. 3, the method may comprise the steps of:
step S302, detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
step S304, obtaining the depth of field of the first display area in the display interface of the media file;
step S306, adjusting the definition of the display area in the display interface based on the depth of field, where the definition of the adjusted first display area is higher than the definition of the adjusted second display area, and the second display area is a partial area of the display interface except for the first display area.
The step S306 may be to adjust the definitions of the second display area and the third display area except the first display area. When the third display area is adjusted, the whole area of the third display area can be adjusted, or the partial area of the third display area can be adjusted, and when the partial area of the third display area is adjusted, the definition of the sub-display area, which is in the third display area and is away from the first display area by a preset distance, is set to be lower than that of the first display area, wherein the farther the sub-display area is away from the first display area, the lower the definition of the display block in the sub-display area is.
Through the above steps S302 to S306, after detecting the first display area watched by the user in the display interface of the media file, based on the depth of field of the first display area in the display interface, the definition of the media file in the display area is adjusted, so that the definition of the adjusted first display area is higher than that of the other part of area, in the above-described embodiment, the definition of the presentation interface of the media file is adjusted by the depth of field of the area at which the user gazes, so that the definition of different display areas on the display interface is different, and the information displayed on the display interface comprises depth-of-field information, therefore, when the focus of the visual system of the user is positioned on the screen of the display equipment, the focus adjustment of the eyes is matched with the depth information of the display interface, the convergence adjustment and the focus adjustment occur simultaneously, the convergence adjustment conflict is eliminated, and the technical problem of the convergence adjustment conflict is solved.
In the above embodiment, the clarity of the files viewed by the vision system is different, and the conflict of convergence adjustment is eliminated, that is, when the media files are viewed in the virtual reality scene provided by the display device, the focus adjustment and the convergence adjustment occur simultaneously, and the user does not feel visual fatigue and vertigo.
The display device of the embodiment of the application may be a head-mounted display device, and in the technical scheme provided in step S202, the display device is configured to provide a virtual reality scene, a user (i.e., a user of the display device) may operate an operation interface in the virtual reality scene to start playing of a media file, and after the playing of the media file is started, a first display area watched by the user in the display interface of the media file is detected. Optionally, after the display device is started, the image capturing device may be used to capture motion information of a visual system of a user of the display device, and the captured motion information of the visual system is used to determine a first display area, where the first display area may include one or more pixel points. Wherein, image acquisition equipment includes: a camera is provided.
The above-mentioned motion information of the user's visual system using the image capturing device to capture the display device can be achieved by eye tracking, and the user can operate the screen without touching the screen (the screen may be a screen in a virtual reality scene) by using this technique.
When the eyes of a person look at different directions, the eyes can slightly change, the changes can generate extractable features, and the computer can extract the features through image capture or scanning, so that the change of the eyes can be tracked, the state and the demand of a user can be predicted based on the change of the eyes, the response is carried out, and the purpose of controlling the equipment by using the eyes is achieved.
Wherein the eye tracking may be achieved by at least one of: tracking according to the eyeball and the characteristic change around the eyeball, tracking according to the angle change of the iris, and transmitting the infrared light beam to the iris to extract the characteristics.
In the technical solution provided in step S304, after detecting the first display area in the playing interface of the media file watched by the user, the depth of field of the first display area in the display interface of the media file may be obtained.
The depth of field is a range of a distance between the front and rear of a subject measured at the front edge of a camera lens or other imager, where a sharp image can be obtained. After the focusing is finished, a clear image can be formed in the range before and after the focus, and the distance range before and after the focus is the depth of field. After the image is acquired, the depth of field of the image can be determined based on the circle of confusion, where before and after the focus, the rays diverge from focus to point, the image of the point diverges from the circle to the focus and then to the circle, and the circles before and after the focus are called circle of confusion.
In the embodiment, the depth of field of each display area in the display interface of the media file can be obtained in advance, and after the first display area in the playing interface of the media file watched by the user is detected, the depth of field of the first display area in the display interface of the media file is directly read from the obtained depth of field; or after detecting the first display area in the playing interface of the media file watched by the user, determining the depth of field of each display area in the display interface of the media file, and acquiring the depth of field of the first display area.
According to the embodiment of the invention, before the depth of field of the first display area in the display interface of the media file is obtained, the parallax of the user viewing the media file by using the display device can be determined; calculating the depth of field of each display area in the display interface of the media file by using the parallax; saving the depth of field of each display area to obtain a depth of field file of the media file; the acquiring the depth of field of the display area in the media file comprises the following steps: and reading the depth of field of the first display area from the depth of field file.
In a virtual reality application scene, 3D files seen by the left eye and the right eye of a human vision system have parallax, the depth of field of each display area in a display interface of a media file seen by the left eye is obtained, the depth of field of each display area in the display interface of the media file seen by the right eye is obtained, the depth of field of each display area in the display interface of the media file is calculated by using the parallax of the left eye and the right eye of human eyes when display equipment is used, and further, the depth of field of each pixel point can be recorded. And storing the acquired depth of field data to obtain a depth of field file. After detecting the first presentation area, the depth of view of the first presentation area may be quickly determined using the depth of view file. For example, the average of the depths of field of all the pixels in the first display area may be used as the depth of field of the first display area, the maximum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, the minimum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, and the weighted average of the pixels in the first display area may be used as the depth of field of the first display area.
In the technical solution provided in step S306, the definition of each display area in the display interface of the media file may be adjusted based on the depth of field of the first display area in the display interface of the media file, so as to adjust the definition of the first display area to be the highest, and adjust the definitions of the other display areas to be less clear than the definition of the first display area, for example, the definitions of the other display areas may be adjusted to be clearer or less clear.
In an alternative embodiment, a part of the display interface of the media file except for the first display area may be determined as the second display area, for example, the definition of the adjusted first display area is the highest definition display area in the display interface of the entire media file, and the definition of the second display area is lower than that of the first display area, but other display areas with the same definition as that of the first display area may be included in the display interface of the adjusted media file. Is a third display area.
In an alternative embodiment, adjusting the sharpness of the presentation area in the presentation interface based on the depth of field may include: determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; the definition of the second display area in the display interface is set to be lower than that of the first display area. An area having the same depth of field as the first presentation area is determined as a third presentation area.
The depth of field of each display area in the display interface of the media file is obtained, and each display area can be determined based on a display object (or object) in the display interface of the media file, or can be determined based on whether the depth of field in the display interface is the same, for example, a display area is formed by pixel points belonging to the same display object in the display interface, or a through area formed by pixel points with the same depth of field in the display interface is a display area. Alternatively, a plurality of discrete points may be provided, and a point having a distance from the same center smaller than a predetermined distance may be determined as a point belonging to the same display area, with each of the discrete points as a center.
Of course, there are other methods for determining the display area, which are not limited in this application.
In this embodiment, the definition of the other region having the depth of field different from that of the first presentation region may be set lower than that of the first presentation region.
Specifically, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface may include: acquiring the depth of field of each sub-display area in the second display area; determining the depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
By the embodiment, the information of the media files with depth can be acquired, and the user does not have visual axis convergence conflict and fatigue when watching the information.
In this embodiment, the average value of the depths of field of all the pixels in the sub-display area may be used as the depth of field of the sub-display area, the maximum value of the depths of field of the pixels in the sub-display area may be used as the depth of field of the sub-display area, the minimum value of the depths of field of the pixels in the sub-display area may be used as the depth of field of the sub-display area, and the weighted average value of the pixels in the sub-display area may be used as the depth of field of the sub-display area. This is not limited in this application.
In the above embodiment, the definitions of the second display area may be set to be lower than the definition of the first display area, the definitions of the sub-display areas in the second display area may be set to be the same, and the definitions of the sub-display areas in the second display area may also be set to be different.
The resolution of the region of the second presentation region having a larger depth difference from the depth of field of the first presentation region may be set to a lower resolution, and the resolution of the region of the second presentation region having a smaller depth difference from the depth of field of the first presentation region may be set to a higher resolution.
Here lower and higher for each sub-presentation area in the second presentation area. As shown in fig. 4, the sharpness is represented by the density of the hatched lines, and the higher the density of the hatched lines, the higher the sharpness.
The presentation interface 40 of the media file in fig. 4 comprises three areas, wherein the first area 401 is a first presentation area, i.e. the area where the detected user gazes at the presentation interface of the media file, the second area 402 is a first sub-presentation area in the second presentation area, the depth of field difference between the sub-presentation area and the first presentation area is a, the third area 403 is a second sub-presentation area in the second presentation area, the depth of field difference between the sub-presentation area and the first presentation area is B, assuming a > B, a lower definition can be set for the first sub-presentation area and a higher definition can be set for the second presentation sub-area, but the definition of both the first sub-presentation area and the second sub-presentation area can be lower than that of the first presentation area, so that the definition of the first presentation area is higher than that of the second sub-presentation area, the definition of the second sub-display area is higher than that of the first sub-display area.
Of course, the embodiment shown in fig. 4 is only illustrated as an example, and the shapes of the display area and the sub-display areas in the specific implementation may be irregular shapes, which is not limited in this application, and the second display area may be divided into the number of sub-display areas, which is also not limited in this application.
In another alternative embodiment, setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface may comprise: gradually reducing the sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area. By the embodiment, the definition of the display area is selectively reduced, and the data processing amount is reduced under the condition that a user watches the file.
Specifically, the definition may be set according to the distance from the first display area, for example, a second display area located outside the first display area and surrounding the first display area is divided along a predetermined radiation path by taking the first display area as a center or as a reference, as shown in fig. 5, the second display area may include a first sub-display area and a second sub-display area, of course, in a specific implementation, the second display area may include more sub-display areas, and the present application only takes the first sub-display area and the second sub-display area as an example for description.
In the presentation interface 50 of a media file shown in fig. 5, the first sub-presentation area 502 is closer to the first presentation area 501 (compared with the second sub-presentation area), the definition of the first sub-presentation area is set to be higher, the second sub-presentation area 503 is farther from the first presentation area (compared with the first sub-presentation area), the definition of the second sub-presentation area is set to be slightly lower, the definition is represented by the density of the lines filled with the hatching in fig. 5, and the density of the lines filled with the hatching is higher.
Alternatively, in determining the distance between the sub-presentation area and the first presentation area, the distance may be determined by calculating the euclidean distance between the sub-presentation area and the first presentation area.
In another alternative embodiment, adjusting the sharpness of the presentation area in the presentation interface based on the depth of field may include: acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a part of the display interface in the third display area as the definition of the first display area.
Specifically, the setting of the definition of the partial region in the third display region in the display interface to the definition of the first display region may include: and setting the definition of the sub-display area, which is positioned at a distance exceeding the preset distance from the first display area, in the third display area to be lower than that of the first display area.
According to the embodiment, an area with the same depth of field as the first presentation area in the presentation interface of the media file can be determined as the third presentation area, and the definition of a partial area in the third presentation area is set to be the same as the definition of the first presentation area.
In an alternative embodiment, the definition may be set according to the distance from the first display area, for example, the third display area is divided along a predetermined radiation path by taking the first display area as a center or as a reference, the pixel points within a predetermined distance from the first display area are divided into the pixel points in the first sub-display area, and the definition of the first sub-display area in the third display area may be set to be the same as the definition of the first display area.
Dividing the pixel points which are away from the first display area by a preset distance to the pixel points in the second sub-display area, and setting the definition of the second sub-display area in the third display area to be lower than that of the first display area.
Further optionally, the display tiles in the second sub-display area may be set to different resolutions, for example, along the predetermined radiation path, the lower the resolution setting of the display tiles in the second sub-display area farther from the first display area, the higher the resolution setting of the display tiles in the second sub-display area closer to the first display area.
In the above embodiment, adjusting the definition of the presentation area in the presentation interface based on the depth of field may include: and adjusting the display resolution of the display area in the display interface based on the depth of field.
Specifically, the definition of the display area may be adjusted by adjusting the display resolution of the display area. For example, the higher the resolution of the adjustment, the higher the corresponding sharpness; the lower the resolution of the adjustment, the lower the corresponding sharpness.
In an optional embodiment, the definition of the display area may be adjusted by using a gaussian blur processing manner, for example, the higher the set blur parameter is, the lower the definition of the corresponding display area is; the lower the set blur parameter, the higher the definition of the corresponding presentation area.
In yet another alternative embodiment, the definition of the display area may also be adjusted by adjusting the number of grids of different faces of the media file, for example, the greater the number of grids of information on the display interface of the adjusted media file, the higher the definition of the adjusted display area; the less the number of grids of information on the presentation interface of the adjusted media file, the lower the sharpness of the adjusted presentation area.
Of course, the definition of the display area may also be adjusted by using other processing manners for adjusting the definition, which is not limited in this application.
According to an embodiment of the present invention, detecting a first presentation area at which a user of a presentation apparatus gazes in a presentation interface of a media file may include: detecting a point of regard of a user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the watching point, and determining the view range as a first display area.
The gaze point of the user in the presentation interface of the media file may be detected according to the above-mentioned eye tracking technique, and the gaze point may be a pixel point in the presentation interface corresponding to the media file, and since the field of view is at an angle when the human eye gazes at a position, the field of view range of the user's gaze may be determined based on the angle, and the range is determined as a first presentation area, which may include one or more pixel points.
It should be noted that the media files in the above embodiments may include static files, such as pictures, or dynamic files, such as animation, video, and other files.
The present invention also provides a preferred embodiment, and the following describes in detail a preferred embodiment of the present application with reference to fig. 6 and 7, by which a file can be actively rendered according to a depth of field.
This scheme can obtain using in virtual reality's helmet, and specifically, the user can wear this virtual reality helmet, and the user can utilize the motion of handle or eyeball to control the virtual reality helmet.
When the virtual reality helmet is controlled by using the movement of the eyeballs, the eyepoint of the human eyes in a screen (the screen may be a virtual screen of the virtual reality helmet) may be determined by using an eyeball tracking technology, and the eyepoint may be one or more pixel points.
Since the human eye is gazing at a position, the effective comfortable visual field has a predetermined angle, for example, 60 degrees, objects exceeding the predetermined angle range are not sensitive to the human eye, and the subjective feeling of human vision is not affected by the clarity of rendering the part of the scene, so that the GPU rendering task can be reduced by using this characteristic, as shown in fig. 6. In fig. 6, the length of a line segment in a broken line indicates the resolution, and the longer the length of the line segment, the lower the resolution, and the higher the resolution indicated by a solid line than a broken line.
As shown in fig. 6, the embodiment includes three display areas, the first display area having the highest definition, the second display area having the second highest definition, and the third display area having the lowest definition. The first display area includes the gazing point, that is, the definition of the display area in which the gazing point is located is set to be the highest. The remaining settings are lower, which can reduce the amount of computation.
As can be seen from fig. 6, this approach takes into account the human eye gaze point location and renders all foreground and background objects at that location with the same definition.
In particular, the embodiment shown in fig. 6 may render a media file based on a point of gaze. In this scheme, how to reduce the amount of computation of the GPU can be considered from the perspective of the two-dimensional plane. The region level is divided according to the Euclidean distance from the fixation point, and the region far away from the fixation point can be rendered in a lower resolution mode to reduce the definition, so that different definitions can be displayed in one display interface.
This embodiment, which is not visible to the human eye or does not reduce the resolution rendering in the regions near the fixation point of the human eye, because the human eye is not sensitive to those regions, something like the human eye's afterlight is more blurred, which does not affect the user's viewing, and at the same time, reduces the data processing amount.
In an optional manner, the definition of the presentation interface of the media file may be adjusted according to the depth of field of the user's gaze point, as shown in fig. 7, when a person focuses on a certain scene (which may be a presentation area), the depth of other scenes may be blurred based on the depth of the scene.
As shown in fig. 7, the small black triangle indicates the visual focus, the visual focus in the left image is near, the visual focus in the right image is far, and for different focal lengths of the same scene, there is a certain difference between the display areas obtained by processing, but the areas focused by the eyes have high definition, wherein the definition indicated by the dotted line in the image is lower than that indicated by the solid line.
Specifically, in the scheme shown in fig. 7, based on depth rendering, from the perspective of a three-dimensional space, depth information is used to clearly process depth corresponding to a gaze point, and other depths are blurred. The scheme can relieve the uncomfortable feeling caused by the conflict of the visual convergence and adjustment.
With the above-described embodiment, the content in the visual scene is displayed differently depending on the depth of field of the gaze point (depth of field corresponds to focus), and the sense of discomfort due to the convergence accommodation conflict can be alleviated to some extent.
In the virtual reality system, the left eye and the right eye have independent file contents (such as video contents), and the depth map corresponding to each object can be calculated according to the video contents of the left eye and the right eye. Specifically, the disparity of the left and right eyes of the head-mounted device can be utilized to calculate the depth map of the whole scene. When the depth of the scenery at the gazing point is known, the object corresponding to the depth of field can be clarified, and the other objects in the depth of field can be blurred, so that the effect as shown in fig. 7 is achieved.
The discomfort caused by the visual convergence adjustment conflict can be relieved by rendering according to the depth of field, and by the scheme, the feeling of a human eye watching the real world is simulated, and when the human eye focuses on one point, objects with other depth of field can be out of focus and blurred.
It should be further noted that the embodiments shown in fig. 6 and fig. 7 may be combined, that is, the optimized rendering method based on the gazing point area and the gazing point depth.
The two modes are combined, and different renderings are carried out in the visual fixation point area according to the depth of field; reducing resolution rendering in a non-fixation point area; the GPU load can be reduced, and the uncomfortable feeling of the visual convergence adjustment conflict can be relieved, so that the fatigue feeling and dizziness feeling of a user caused by watching under a virtual reality scene are relieved.
According to another aspect of the embodiment of the present invention, a processing device for implementing the above media file processing method is also provided. Fig. 8 is a schematic diagram of an alternative media file processing apparatus according to an embodiment of the present invention, and as shown in fig. 8, the apparatus may include:
a detecting unit 81, configured to detect a first display area watched by a user of a display device in a display interface of a media file, where the media file is displayed in a virtual reality scene, and the display device is configured to provide the virtual reality scene;
the obtaining unit 83 is configured to obtain a depth of field of the first display area in the display interface of the media file;
the adjusting unit 85 is configured to adjust the definition of a display area in the display interface based on the depth of field, where the definition of the adjusted first display area is higher than the definition of the adjusted second display area, and the second display area is all or a part of the display interface except the first display area.
Optionally, the apparatus is further configured to determine a depth of field of each pixel in the display area before detecting the first display area, where the number of the display areas may be multiple, and each display area corresponds to one or more pixels.
The obtaining unit 83 may use an average of the depths of field of all the pixels in the first display area as the depth of field of the first display area, or use a maximum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a minimum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a weighted average of the pixels in the first display area as the depth of field of the first display area.
After detecting a first display area watched by a user in a display interface of the media file, adjusting the definition of the media file in the display area based on the depth of field of the first display area in the display interface, so that the definition of the adjusted first display area is higher than that of all or part of the other display areas, in the above-described embodiment, the definition of the presentation interface of the media file is adjusted by the depth of field of the area at which the user gazes, so that the definition of different display areas on the display interface is different, and the information displayed on the display interface comprises depth-of-field information, therefore, when the focus of the visual system of the user is positioned on the screen of the display equipment, the focus adjustment of the eyes is matched with the depth information of the display interface, the convergence adjustment and the focus adjustment occur simultaneously, the convergence adjustment conflict is eliminated, and the technical problem of the convergence adjustment conflict is solved.
In the above embodiment, the clarity of the files viewed by the vision system is different, and the conflict of convergence adjustment is eliminated, that is, when the media files are viewed in the virtual reality scene provided by the display device, the focus adjustment and the convergence adjustment occur simultaneously, and the user does not feel visual fatigue and vertigo.
The display device of the embodiment of the application may be a head-mounted display device, and in the technical scheme provided in step S202, the display device is configured to provide a virtual reality scene, a user (i.e., a user of the display device) may operate an operation interface in the virtual reality scene to start playing of a media file, and after the playing of the media file is started, a first display area watched by the user in the display interface of the media file is detected. Optionally, after the display device is started, the image capturing device may be used to capture motion information of a visual system of a user of the display device, and the captured motion information of the visual system is used to determine a first display area, where the first display area may include one or more pixel points. Wherein, image acquisition equipment includes: a camera is provided.
The above-mentioned motion information of the user's visual system using the image capturing device to capture the display device can be achieved by eye tracking, and the user can operate the screen without touching the screen (the screen may be a screen in a virtual reality scene) by using this technique.
When the eyes of a person look at different directions, the eyes can slightly change, the changes can generate extractable features, and the computer can extract the features through image capture or scanning, so that the change of the eyes can be tracked, the state and the demand of a user can be predicted based on the change of the eyes, the response is carried out, and the purpose of controlling the equipment by using the eyes is achieved.
Wherein the eye tracking may be achieved by at least one of: tracking according to the eyeball and the characteristic change around the eyeball, tracking according to the angle change of the iris, and transmitting the infrared light beam to the iris to extract the characteristics.
In the technical scheme, the depth of field of the first display area in the display interface of the media file can be acquired after the first display area in the play interface of the media file watched by the user is detected.
The depth of field is a range of a distance between the front and rear of a subject measured at the front edge of a camera lens or other imager, where a sharp image can be obtained. After the focusing is finished, a clear image can be formed in the range before and after the focus, and the distance range before and after the focus is the depth of field. After the image is acquired, the depth of field of the image can be determined based on the circle of confusion, where before and after the focus, the rays diverge from focus to point, the image of the point diverges from the circle to the focus and then to the circle, and the circles before and after the focus are called circle of confusion.
In the embodiment, the depth of field of each display area in the display interface of the media file can be obtained in advance, and after the first display area in the playing interface of the media file watched by the user is detected, the depth of field of the first display area in the display interface of the media file is directly read from the obtained depth of field; or after detecting the first display area in the playing interface of the media file watched by the user, determining the depth of field of each display area in the display interface of the media file, and acquiring the depth of field of the first display area.
According to the embodiment of the invention, before the depth of field of the first display area in the display interface of the media file is obtained, the parallax of the user viewing the media file by using the display device can be determined; calculating the depth of field of each display area in the display interface of the media file by using the parallax; saving the depth of field of each display area to obtain a depth of field file of the media file; the acquiring the depth of field of the display area in the media file comprises the following steps: and reading the depth of field of the first display area from the depth of field file.
In a virtual reality application scene, 3D files seen by the left eye and the right eye of a human vision system have parallax, the depth of field of each display area in a display interface of a media file seen by the left eye is obtained, the depth of field of each display area in the display interface of the media file seen by the right eye is obtained, the depth of field of each display area in the display interface of the media file is calculated by using the parallax of the left eye and the right eye of human eyes when display equipment is used, and further, the depth of field of each pixel point can be recorded. And storing the acquired depth of field data to obtain a depth of field file. After detecting the first presentation area, the depth of view of the first presentation area may be quickly determined using the depth of view file. For example, the average of the depths of field of all the pixels in the first display area may be used as the depth of field of the first display area, the maximum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, the minimum of the depths of field of the pixels in the first display area may be used as the depth of field of the first display area, and the weighted average of the pixels in the first display area may be used as the depth of field of the first display area.
In the above embodiment, the definition of each display area in the display interface of the media file may be adjusted based on the depth of field of the first display area in the display interface of the media file, so as to adjust the definition of the first display area to be the highest, and adjust the definitions of the other display areas to be less clear than the definition of the first display area, for example, the definitions of the other display areas may be adjusted to be clearer or less clear.
In an alternative embodiment, all areas except the first display area in the display interface of the media file may be determined as the second display area, or a partial area except the first display area in the display interface of the media file may be determined as the second display area, for example, the definition of the adjusted first display area is the highest definition display area in the display interface of the entire media file, but other display areas with the same definition as the first display area may be included in the display interface of the adjusted media file.
According to the above embodiment of the present invention, the adjusting unit may include: the first determining module is used for determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; the first setting module is used for setting the definition of the second display area in the display interface to be lower than that of the first display area.
Specifically, the first setting module may include: the acquisition submodule is used for acquiring the depth of field of each sub-display area in the second display area; the determining submodule is used for determining the depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; the first setting submodule is used for setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
According to the above embodiment of the present invention, the first setting module may include: and the second setting submodule is used for gradually reducing the definition of the sub display area in the second display area which takes the first display area as the center and is arranged along a preset radiation path, wherein the preset radiation path is a radiation path far away from the first display area.
By the embodiment, the information of the media files with depth can be acquired, and the user does not have visual axis convergence conflict and fatigue when watching the information.
In an alternative embodiment, the adjusting unit may include: the first acquisition module is used for acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and the second setting module is used for setting the definition of a part of the third display area in the display interface as the definition of the first display area.
Specifically, the second setting module is specifically configured to: and setting the definition of the sub-display area, which is positioned at a distance exceeding the preset distance from the first display area, in the third display area to be lower than that of the first display area.
By the embodiment, the definition of the display area is selectively reduced, and the data processing amount is reduced under the condition that a user watches the file.
Further, the detection unit may include: the detection module is used for detecting a fixation point of a user in a display interface of the media file; the acquisition module is used for acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as a first display area.
In an optional embodiment, the adjusting unit is specifically configured to: and adjusting the display resolution of the display area in the display interface based on the depth of field.
According to the embodiment of the invention, before the depth of field of the first display area in the display interface of the media file is acquired, the processing unit is configured to determine a parallax for a user to view the media file by using the display device; calculating the depth of field of each display area in the media file by using the parallax; and saving the depth of field of each display area to obtain a depth of field file of the media file. The obtaining unit is specifically configured to: and reading the depth of field of the first display area from the depth of field file.
It should be noted that the media files in the above embodiments may include static files, such as pictures, or dynamic files, such as animation, video, and other files.
It should be noted here that the modules described above are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the disclosure of the above embodiments. It should be noted that the modules described above as a part of the apparatus may be run in a hardware environment as shown in fig. 2, may be implemented by software, and may also be implemented by hardware, where the hardware environment includes a network environment.
As another example of the present solution, the processing device of the media file includes:
a detecting unit 81, configured to detect a first display area watched by a user of a display device in a display interface of a media file, where the media file is displayed in a virtual reality scene, and the display device is configured to provide the virtual reality scene;
the obtaining unit 83 is configured to obtain a depth of field of the first display area in the display interface of the media file;
the adjusting unit 85 is configured to adjust the definition of a display area in the display interface based on the depth of field, where the definition of the adjusted first display area is higher than the definition of the adjusted second display area, and the second display area is a partial area of the display interface except the first display area.
The adjusting unit 85 is configured to adjust the definitions of the second display area and the third display area except the first display area. When the third display area is adjusted, the whole area of the third display area can be adjusted, or the partial area of the third display area can be adjusted, and when the partial area of the third display area is adjusted, the definition of the sub-display area, which is in the third display area and is away from the first display area by a preset distance, is set to be lower than that of the first display area, wherein the farther the sub-display area is away from the first display area, the lower the definition of the display block in the sub-display area is.
According to another aspect of the embodiment of the present invention, a server or a terminal for implementing the above media file processing method is also provided.
Fig. 9 is a block diagram of a terminal according to an embodiment of the present invention, and as shown in fig. 9, the terminal may include: one or more processors 201 (only one of which is shown), a memory 203, and a transmission device 205 (such as the transmission device in the above embodiment), as shown in fig. 9, the terminal may further include an input/output device 207.
The memory 203 may be used to store software programs and modules, such as program instructions/modules corresponding to the method and apparatus for processing a media file in the embodiment of the present invention, and the processor 201 executes various functional applications and data processing by running the software programs and modules stored in the memory 203, that is, implements the above-mentioned method for processing a media file. The memory 203 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 203 may further include memory located remotely from the processor 201, which may be connected to the terminal over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 205 is used for receiving or sending data via a network, and can also be used for data transmission between a processor and a memory. Examples of the network may include a wired network and a wireless network. In one example, the transmission device 205 includes a Network adapter (NIC) that can be connected to a router via a Network cable and other Network devices to communicate with the internet or a local area Network. In one example, the transmission device 205 is a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
Wherein the memory 203 is specifically used for storing application programs.
The processor 201 may call the application stored in the memory 203 via the transmission means 205 to perform the following steps: detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; acquiring the depth of field of a first display area in a display interface of a media file; and adjusting the definition of a display area in the display interface based on the depth of field, wherein the definition of the adjusted first display area is higher than that of the adjusted second display area, and the second display area is all or part of the display interface except the first display area.
The processor 201 is further configured to perform the following steps: determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; the definition of the second display area in the display interface is set to be lower than that of the first display area.
The processor 201 is further configured to perform the following steps: acquiring the depth of field of each sub-display area in the second display area; determining the depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
The processor 201 is further configured to perform the following steps: gradually reducing the sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area.
The processor 201 is further configured to perform the following steps: acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a part of the display interface in the third display area as the definition of the first display area.
The processor 201 is further configured to perform the following steps: and setting the definition of the sub-display area, which is positioned at a distance exceeding the preset distance from the first display area, in the third display area to be lower than that of the first display area.
The processor 201 is further configured to perform the following steps: detecting a point of regard of a user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the watching point, and determining the view range as a first display area.
The processor 201 is further configured to perform the following steps: and adjusting the display resolution of the display area in the display interface based on the depth of field.
The processor 201 is further configured to perform the following steps: before the depth of field of the first display area in the display interface of the media file is obtained, determining the parallax of a user for watching the media file by using display equipment; calculating the depth of field of each display area in the media file by using the parallax; saving the depth of field of each display area to obtain a depth of field file of the media file; and reading the depth of field of the first display area from the depth of field file.
The processor 201 is further configured to perform the following steps: the media files include static files.
After detecting a first display area watched by a user in a display interface of the media file, adjusting the definition of the media file in the display area based on the depth of field of the first display area in the display interface, so that the definition of the adjusted first display area is higher than that of all or part of the other display areas, in the above-described embodiment, the definition of the presentation interface of the media file is adjusted by the depth of field of the area at which the user gazes, so that the definition of different display areas on the display interface is different, and the information displayed on the display interface comprises depth-of-field information, therefore, when the focus of the visual system of the user is positioned on the screen of the display equipment, the focus adjustment of the eyes is matched with the depth information of the display interface, the convergence adjustment and the focus adjustment occur simultaneously, the convergence adjustment conflict is eliminated, and the technical problem of the convergence adjustment conflict is solved.
Optionally, the specific examples in this embodiment may refer to the examples described in embodiment 1 and embodiment 2, and this embodiment is not described herein again.
It can be understood by those skilled in the art that the structure shown in fig. 9 is only an illustration, and the terminal may be a terminal device such as a smart phone (e.g., an Android phone, an iOS phone, etc.), a tablet computer, a palm computer, and a Mobile Internet Device (MID), a PAD, etc. Fig. 9 is a diagram illustrating a structure of the electronic device. For example, the terminal may also include more or fewer components (e.g., network interfaces, display devices, etc.) than shown in FIG. 9, or have a different configuration than shown in FIG. 9.
Those skilled in the art will appreciate that all or part of the steps in the methods of the above embodiments may be implemented by a program instructing hardware associated with the terminal device, where the program may be stored in a computer-readable storage medium, and the storage medium may include: flash disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
There is also provided, in accordance with an embodiment of the present invention, a storage medium. Alternatively, in this embodiment, the storage medium may be a program code for executing a processing method of a media file.
Optionally, in this embodiment, the storage medium may be located on at least one of a plurality of network devices in a network shown in the above embodiment.
Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps:
detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene; acquiring the depth of field of a first display area in a display interface of a media file; and adjusting the definition of a display area in the display interface based on the depth of field, wherein the definition of the adjusted first display area is higher than that of the adjusted second display area, and the second display area is all or part of the display interface except the first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area; the definition of the second display area in the display interface is set to be lower than that of the first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: acquiring the depth of field of each sub-display area in the second display area; determining the depth difference between the depth of field of each sub-display area in the second display area and the depth of field of the first display area; and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
Optionally, the storage medium is further arranged to store program code for performing the steps of: gradually reducing the sharpness of a sub-display area in a second display area centered on the first display area along a predetermined radiation path, wherein the predetermined radiation path is a radiation path away from the first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a part of the display interface in the third display area as the definition of the first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: and setting the definition of the sub-display area, which is positioned at a distance exceeding the preset distance from the first display area, in the third display area to be lower than that of the first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: detecting a point of regard of a user in a display interface of the media file; and acquiring a view range in a display interface of the media file corresponding to the watching point, and determining the view range as a first display area.
Optionally, the storage medium is further arranged to store program code for performing the steps of: and adjusting the display resolution of the display area in the display interface based on the depth of field.
Optionally, the storage medium is further arranged to store program code for performing the steps of: before the depth of field of the first display area in the display interface of the media file is obtained, determining the parallax of a user for watching the media file by using display equipment; calculating the depth of field of each display area in the media file by using the parallax; saving the depth of field of each display area to obtain a depth of field file of the media file; and reading the depth of field of the first display area from the depth of field file.
Optionally, the storage medium is further arranged to store program code for performing the steps of: the media files include static files.
After detecting a first display area watched by a user in a display interface of the media file, adjusting the definition of the media file in the display area based on the depth of field of the first display area in the display interface, so that the definition of the adjusted first display area is higher than that of all or part of the other display areas, in the above-described embodiment, the definition of the presentation interface of the media file is adjusted by the depth of field of the area at which the user gazes, so that the definition of different display areas on the display interface is different, and the information displayed on the display interface comprises depth-of-field information, therefore, when the focus of the visual system of the user is positioned on the screen of the display equipment, the focus adjustment of the eyes is matched with the depth information of the display interface, the convergence adjustment and the focus adjustment occur simultaneously, the convergence adjustment conflict is eliminated, and the technical problem of the convergence adjustment conflict is solved.
Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, and this embodiment is not described herein again.
Optionally, in this embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
The integrated unit in the above embodiments, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing one or more computer devices (which may be personal computers, servers, network devices, etc.) to execute all or part of the steps of the method according to the embodiments of the present invention.
In the above embodiments of the present invention, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other manners. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.

Claims (15)

1. A method for processing a media file, comprising:
determining the depth of field of each pixel point in the display area;
detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
taking an average value of the depths of field of all the pixels in the first display area as the depth of field of the first display area, or taking a maximum value of the depths of field of the pixels in the first display area as the depth of field of the first display area, or taking a minimum value of the depths of field of the pixels in the first display area as the depth of field of the first display area, or taking a weighted average value of the pixels in the first display area as the depth of field of the first display area;
adjusting the definition of a display area in the display interface based on the depth of field of the first display area, wherein the definition of the adjusted first display area is higher than that of an adjusted second display area, and the second display area is all or part of the display interface except the first display area;
acquiring a third display area with the same depth of field as the first display area in the display interface of the media file;
and setting the definition of a sub-display area, which is farther away from the first display area than a preset distance, in the third display area to be lower than the definition of the first display area, wherein the definition of the display block in the sub-display area is lower the farther the sub-display area is away from the first display area.
2. The method of claim 1, wherein adjusting the sharpness of the presentation area in the presentation interface based on the depth of field of the first presentation area comprises:
determining a display area with different depth of field from the first display area in the display interface of the media file as the second display area;
setting the definition of a second display area in the display interface to be lower than the definition of the first display area.
3. The method of claim 2, wherein setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface comprises:
acquiring the depth of field of each sub-display area in the second display area;
determining a depth difference between the depth of field of each sub-presentation area in the second presentation area and the depth of field of the first presentation area;
and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
4. The method of claim 2, wherein setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface comprises:
gradually reducing the sharpness of sub-presentation areas in a second presentation area along a predetermined radiation path centered on the first presentation area,
wherein the predetermined radiation path is a radiation path remote from the first display area.
5. The method of any one of claims 1 to 4, wherein detecting a first presentation area at which the user gazes in the presentation interface of the media file comprises:
detecting a point of regard of the user in a display interface of the media file;
and acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
6. The method of claim 1, wherein determining the depth of field for each pixel in the presentation area comprises:
determining a parallax of a user of a presentation device viewing a media file using the presentation device;
and calculating the depth of field of each pixel point in each display area of the media file by using the parallax.
7. A method for processing a media file, comprising:
detecting a first display area watched by a user of display equipment in a display interface of a media file, wherein the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
acquiring the depth of field of the first display area in the display interface of the media file;
acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a sub-display area, which is farther away from the first display area than a preset distance, in the third display area to be lower than the definition of the first display area, wherein the definition of the display block in the sub-display area is lower the farther the sub-display area is away from the first display area.
8. The method according to claim 7, wherein the obtaining of the media file in the presentation interface before a third presentation area having the same depth of view as the first presentation area further comprises:
determining a display area with different depth of field from the first display area in the display interface of the media file as a second display area;
setting the definition of a second display area in the display interface to be lower than the definition of the first display area.
9. The method of claim 8, wherein setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface comprises:
acquiring the depth of field of each sub-display area in the second display area;
determining a depth difference between the depth of field of each sub-presentation area in the second presentation area and the depth of field of the first presentation area;
and setting the definition of different sub-display areas according to the depth difference, wherein the larger the depth difference corresponding to the sub-display areas is, the lower the definition of the set sub-display areas is.
10. The method of claim 8, wherein setting the definition of the second presentation area to be lower than the definition of the first presentation area in the presentation interface comprises:
gradually reducing the sharpness of sub-presentation areas in a second presentation area along a predetermined radiation path centered on the first presentation area,
wherein the predetermined radiation path is a radiation path remote from the first display area.
11. The method of any one of claims 7 to 10, wherein detecting the first presentation area at which a user of the presentation device gazes in the presentation interface for the media file comprises:
detecting a point of regard of the user in a display interface of the media file;
and acquiring a view range in a display interface of the media file corresponding to the point of regard, and determining the view range as the first display area.
12. An apparatus for processing a media file, comprising:
the first determining unit is used for determining the depth of field of each pixel point in the display area;
the device comprises a detection unit, a display unit and a control unit, wherein the detection unit is used for detecting a first display area watched by a user of display equipment in a display interface of a media file, the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
a second determining unit, configured to use an average of the depths of field of all the pixels in the first display area as the depth of field of the first display area, or use a maximum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a minimum of the depths of field of the pixels in the first display area as the depth of field of the first display area, or use a weighted average of the pixels in the first display area as the depth of field of the first display area;
the adjusting unit is used for adjusting the definition of a display area in the display interface based on the depth of field of the first display area, wherein the definition of the adjusted first display area is higher than that of an adjusted second display area, and the second display area is all or part of the display interface except the first display area;
the device is further used for acquiring a third display area with the same depth of field as the first display area in the display interface of the media file; and setting the definition of a sub-display area, which is farther away from the first display area than a preset distance, in the third display area to be lower than the definition of the first display area, wherein the definition of the display block in the sub-display area is lower the farther the sub-display area is away from the first display area.
13. An apparatus for processing a media file, comprising:
the device comprises a detection unit, a display unit and a control unit, wherein the detection unit is used for detecting a first display area watched by a user of display equipment in a display interface of a media file, the media file is displayed in a virtual reality scene, and the display equipment is used for providing the virtual reality scene;
the first obtaining unit is used for obtaining the depth of field of the first display area in the display interface of the media file;
the second obtaining unit is used for obtaining a third display area which has the same depth of field as the first display area in the display interface of the media file;
the first setting unit is used for setting the definition of a sub-display area, which is located in the third display area and is away from the first display area by a preset distance, to be lower than the definition of the first display area, wherein the farther the sub-display area is away from the first display area, the lower the definition of the display block in the sub-display area is.
14. A storage medium storing a computer program, characterized in that the computer program executes the method of any of claims 1 to 6 or 7 to 11.
15. A terminal comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method of any of claims 1 to 6 or 7 to 11 by means of the computer program.
CN201910055011.2A 2016-10-19 2016-10-19 Media file processing method and device, storage medium and terminal Active CN109901710B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910055011.2A CN109901710B (en) 2016-10-19 2016-10-19 Media file processing method and device, storage medium and terminal

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610911557.XA CN106484116B (en) 2016-10-19 2016-10-19 The treating method and apparatus of media file
CN201910055011.2A CN109901710B (en) 2016-10-19 2016-10-19 Media file processing method and device, storage medium and terminal

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
CN201610911557.XA Division CN106484116B (en) 2016-07-14 2016-10-19 The treating method and apparatus of media file

Publications (2)

Publication Number Publication Date
CN109901710A CN109901710A (en) 2019-06-18
CN109901710B true CN109901710B (en) 2020-12-01

Family

ID=58270923

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201910055011.2A Active CN109901710B (en) 2016-10-19 2016-10-19 Media file processing method and device, storage medium and terminal
CN201610911557.XA Active CN106484116B (en) 2016-07-14 2016-10-19 The treating method and apparatus of media file

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN201610911557.XA Active CN106484116B (en) 2016-07-14 2016-10-19 The treating method and apparatus of media file

Country Status (1)

Country Link
CN (2) CN109901710B (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018010677A1 (en) 2016-07-14 2018-01-18 腾讯科技(深圳)有限公司 Information processing method, wearable electric device, processing apparatus, and system
CN108694601B (en) * 2017-04-07 2021-05-14 腾讯科技(深圳)有限公司 Media file delivery method and device
CN109242943B (en) 2018-08-21 2023-03-21 腾讯科技(深圳)有限公司 Image rendering method and device, image processing equipment and storage medium
CN108924629B (en) * 2018-08-28 2021-01-05 恒信东方文化股份有限公司 VR image processing method
CN109741463B (en) * 2019-01-02 2022-07-19 京东方科技集团股份有限公司 Rendering method, device and equipment of virtual reality scene
CN110378914A (en) * 2019-07-22 2019-10-25 北京七鑫易维信息技术有限公司 Rendering method and device, system, display equipment based on blinkpunkt information
CN113452986A (en) * 2020-03-24 2021-09-28 杨建刚 Display method and device applied to head-mounted display equipment and storage medium
CN112261408B (en) * 2020-09-16 2023-04-25 青岛小鸟看看科技有限公司 Image processing method and device for head-mounted display equipment and electronic equipment
CN112528107A (en) * 2020-12-07 2021-03-19 支付宝(杭州)信息技术有限公司 Content data display method and device and server
CN113376837A (en) * 2021-06-09 2021-09-10 Oppo广东移动通信有限公司 Near-eye display optical system, near-eye display apparatus and method
CN115686181A (en) * 2021-07-21 2023-02-03 华为技术有限公司 Display method and electronic equipment
CN115793841A (en) * 2021-09-09 2023-03-14 华为技术有限公司 Display method and electronic equipment
CN115793848B (en) * 2022-11-04 2023-11-24 浙江舜为科技有限公司 Virtual reality information interaction method, virtual reality device and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101753844A (en) * 2008-12-18 2010-06-23 三洋电机株式会社 Image display apparatus and image sensing apparatus
CN104052981A (en) * 2013-03-13 2014-09-17 联想(北京)有限公司 Information processing method and electronic equipment

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102520970A (en) * 2011-12-28 2012-06-27 Tcl集团股份有限公司 Dimensional user interface generating method and device
CN102842301B (en) * 2012-08-21 2015-05-20 京东方科技集团股份有限公司 Display frame adjusting device, display device and display method
JP5962393B2 (en) * 2012-09-28 2016-08-03 株式会社Jvcケンウッド Image processing apparatus, image processing method, and image processing program
US9241146B2 (en) * 2012-11-02 2016-01-19 Nvidia Corporation Interleaved approach to depth-image-based rendering of stereoscopic images
CN103093416B (en) * 2013-01-28 2015-11-25 成都索贝数码科技股份有限公司 A kind of real time field depth analogy method of graphic based processor fuzzy partition
KR102270699B1 (en) * 2013-03-11 2021-06-28 매직 립, 인코포레이티드 System and method for augmented and virtual reality
CN103605208B (en) * 2013-08-30 2016-09-28 北京智谷睿拓技术服务有限公司 content projection system and method
JP6201058B2 (en) * 2013-09-17 2017-09-20 アマゾン テクノロジーズ インコーポレイテッド Approach for 3D object display

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101753844A (en) * 2008-12-18 2010-06-23 三洋电机株式会社 Image display apparatus and image sensing apparatus
CN104052981A (en) * 2013-03-13 2014-09-17 联想(北京)有限公司 Information processing method and electronic equipment

Also Published As

Publication number Publication date
CN106484116B (en) 2019-01-08
CN109901710A (en) 2019-06-18
CN106484116A (en) 2017-03-08

Similar Documents

Publication Publication Date Title
CN109901710B (en) Media file processing method and device, storage medium and terminal
KR102239686B1 (en) Single depth tracking acclimatization-convergence solution
US10846927B2 (en) Method and apparatus for displaying a bullet-style comment in a virtual reality system
US11455032B2 (en) Immersive displays
EP3035681B1 (en) Image processing method and apparatus
US10885651B2 (en) Information processing method, wearable electronic device, and processing apparatus and system
US10715791B2 (en) Virtual eyeglass set for viewing actual scene that corrects for different location of lenses than eyes
US10241329B2 (en) Varifocal aberration compensation for near-eye displays
CN105894567B (en) Scaling pixel depth values of user-controlled virtual objects in a three-dimensional scene
CN108762496B (en) Information processing method and electronic equipment
CN106774929B (en) Display processing method of virtual reality terminal and virtual reality terminal
CN106293561B (en) Display control method and device and display equipment
CN109901290B (en) Method and device for determining gazing area and wearable device
Hwang et al. Instability of the perceived world while watching 3D stereoscopic imagery: a likely source of motion sickness symptoms
JP2023515205A (en) Display method, device, terminal device and computer program
CN109799899B (en) Interaction control method and device, storage medium and computer equipment
CN207216145U (en) A kind of Wearable
US11543655B1 (en) Rendering for multi-focus display systems
US11237413B1 (en) Multi-focal display based on polarization switches and geometric phase lenses
KR20160041403A (en) Method for gernerating 3d image content using information on depth by pixels, and apparatus and computer-readable recording medium using the same
Gurrieri Improvements in the visualization of stereoscopic 3D imagery
CN115512092A (en) VR (virtual reality) glasses 3D anti-dizziness method, system, equipment and computer readable storage medium
CN117412020A (en) Parallax adjustment method, parallax adjustment device, storage medium and computing device
CN118092626A (en) Display control method and device and head-mounted display equipment
CN115867238A (en) Visual aid

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant