CN103297729A - Video processing method and device - Google Patents
Video processing method and device Download PDFInfo
- Publication number
- CN103297729A CN103297729A CN201310239567XA CN201310239567A CN103297729A CN 103297729 A CN103297729 A CN 103297729A CN 201310239567X A CN201310239567X A CN 201310239567XA CN 201310239567 A CN201310239567 A CN 201310239567A CN 103297729 A CN103297729 A CN 103297729A
- Authority
- CN
- China
- Prior art keywords
- video
- height
- width
- effective area
- output
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000003672 processing method Methods 0.000 title abstract description 14
- 239000003086 colorant Substances 0.000 claims description 11
- 238000000034 method Methods 0.000 claims description 11
- 238000010586 diagram Methods 0.000 description 7
- 230000000007 visual effect Effects 0.000 description 4
- 230000006835 compression Effects 0.000 description 3
- 238000007906 compression Methods 0.000 description 3
- 241000282326 Felis catus Species 0.000 description 2
- AWSBQWZZLBPUQH-UHFFFAOYSA-N mdat Chemical compound C1=C2CC(N)CCC2=CC2=C1OCO2 AWSBQWZZLBPUQH-UHFFFAOYSA-N 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Landscapes
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
Abstract
An embodiment of the invention relates to a video processing method and device. The video processing method includes: obtaining video playing parameters, wherein the video playing parameters include original aspect ratio of videos; obtaining width and height of a screen of a user device; calculating the width and the height of an effective area in video output according to the original aspect ratio of the videos and the width and the height of the screen of the user device; outputting the videos according to the width and the height of the effective area in video output.
Description
Technical Field
The present invention relates to the field of video technologies, and in particular, to a video processing method and apparatus.
Background
Most current user equipment only plays video in equal proportion according to the aspect ratio of the current effective area of the video. The aspect ratio of the current effective area of the video is provided by the part of the user equipment according to the options of 4:3, 16:9, original ratio and the like, so that the user is helped to adjust the ratio of the video, and the user can obtain the best video watching experience.
If the aspect ratio is 5: a ratio of 4 records a video with an original aspect ratio of 5: and 4, changing the aspect ratio of the video to 16:9, the aspect ratio of the current active area of the video is 16:9, then the video is displayed with a screen aspect ratio of 4: and 3, playing on the user equipment. Because the prior art can only stretch the video according to the aspect ratio (16: 9) of the current effective area of the video, if the recorded content of the video is a square, the video played on the screen of the user equipment (with the aspect ratio of 4: 3) cannot be guaranteed to be a square, and the user can only manually select the proportion of the video to be played.
Therefore, according to the prior art, the width and the height of the video playing can only be set manually by a user or the video playing can be carried out according to the fixed width and height, and the video can not be ensured to be played on the screen of the user equipment at the original aspect ratio of the video.
Disclosure of Invention
In view of this, embodiments of the present invention provide a video processing method and apparatus, where a user does not need to manually set a width and a height of a video during playing, and the video can automatically adapt to the size of a screen of a user equipment and is played at an original aspect ratio of the video.
In a first aspect, an embodiment of the present invention provides a video processing method, where the method includes:
acquiring playing parameters of a video, wherein the playing parameters comprise: the original aspect ratio of the video;
acquiring the width and height of a screen of user equipment;
calculating the width and height of an effective area when the video is output according to the original aspect ratio of the video and the width and height of the screen of the user equipment;
and outputting the video according to the calculated width and height of the effective area when the video is output.
In a first possible implementation manner of the first aspect, the playing parameters further include: the width and height of the current effective area of the video; the outputting the video according to the calculated width and height of the effective area when the video is output specifically comprises: and stretching or scaling the width and the height of the current effective area of the video so as to output the video with the calculated width and the calculated height of the effective area when the video is output.
With reference to the first aspect or the first possible implementation manner of the first aspect, in a second possible implementation manner, the acquiring the playing parameter of the video specifically includes: reading a data block included in the video; acquiring the playing parameters from the data blocks; wherein the data block stores the playing parameter.
With reference to the first aspect or the first possible implementation manner of the first aspect, in a third possible implementation manner, the acquiring the playing parameter of the video specifically includes: reading a file suffix name of the video; acquiring the playing parameters from the file suffix name; wherein the file suffix name contains the playing parameter.
With reference to the first possible implementation manner of the first aspect, in a fourth possible implementation manner, the acquiring the playing parameter of the video specifically includes: reading a frame of the video; acquiring the playing parameters through preset colors in the frame of the video or the width and the height of the preset colors and color areas; wherein, the color is used for representing the original aspect ratio of the video, and the width and height of the color area are used for representing the width and height of the current effective area of the video.
With reference to the first aspect, or the first possible implementation manner of the first aspect, or the second possible implementation manner of the first aspect, or the third possible implementation manner of the first aspect, or the fourth possible implementation manner of the first aspect, in a fifth possible implementation manner, the calculating the width and height of the effective area when the video is output specifically is: when in useTime, calculatey = b; when in useWhen x = a, y = b is calculated; when in useWhen, x = a is calculated,wherein,and in order to obtain the original aspect ratio of the video, a is the width of the screen of the user equipment, b is the height of the screen of the user equipment, x is the width of an effective area during video output, and y is the height of the effective area during video output.
In a second aspect, an embodiment of the present invention provides a video processing apparatus, including:
a first obtaining unit, configured to obtain a playing parameter of a video, where the playing parameter includes: the original aspect ratio of the video;
the second acquisition unit is used for acquiring the width and the height of a screen of the user equipment;
the calculating unit is used for calculating the width and the height of an effective area when the video is output according to the original aspect ratio of the video and the width and the height of the screen of the user equipment;
and an output unit configured to output the video according to the calculated width and height of the effective area when the video is output.
In a first possible implementation manner of the second aspect, the playing parameters further include: the width and height of the current effective area of the video; the output unit is specifically configured to: and stretching or scaling the width and the height of the current effective area of the video so as to output the video with the calculated width and the calculated height of the effective area when the video is output.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner, the first obtaining unit is specifically configured to: reading a data block included in the video; acquiring the playing parameters from the data blocks; wherein the data block stores the playing parameter.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a third possible implementation manner, the first obtaining unit is specifically configured to: reading a file suffix name of the video; acquiring the playing parameters from the file suffix name; wherein the file suffix name contains the playing parameter.
With reference to the first possible implementation manner of the second aspect, in a fourth possible implementation manner, the first obtaining unit is specifically configured to: reading a frame of the video; acquiring the playing parameters through preset colors in the frame of the video or the width and the height of the preset colors and color areas; wherein, the color is used for representing the original aspect ratio of the video, and the width and height of the color area are used for representing the width and height of the current effective area of the video.
In combination with the second aspect or the first possible implementation manner of the second aspect or the second possible implementation manner of the second aspect or the third possible implementation manner of the second aspect or the fourth possible implementation manner of the second aspect, in a fifth possible implementation manner, whenTime, calculatey = b; when in useWhen x = a, y = b is calculated; when in useWhen, x = a is calculated,wherein,and in order to obtain the original aspect ratio of the video, a is the width of the screen of the user equipment, b is the height of the screen of the user equipment, x is the width of an effective area during video output, and y is the height of the effective area during video output.
According to the scheme, the width and the height of the effective area of the video output in the original width-to-height ratio can be calculated by acquiring the original width-to-height ratio of the video and the width and the height of the screen of the user equipment, and then the video is played according to the calculated width and the calculated height of the effective area of the video output. According to the scheme, manual setting by a user is not needed, the video can automatically adapt to the screen size of user equipment, and the video is guaranteed to be played in the original proportion.
Drawings
Fig. 1 is a schematic flowchart of a video processing method according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating the width and height of the currently active area of a video according to one embodiment of the present invention;
FIG. 3 is a diagram illustrating a structure of a data block for storing playback parameters according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a video processing apparatus according to a second embodiment of the present invention;
fig. 5 is a schematic structural diagram of a user equipment according to a third embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, 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.
Fig. 1 is a schematic flowchart illustrating a video processing method according to a first embodiment of the present invention in detail, and fig. 1 is a schematic flowchart illustrating the video processing method according to the first embodiment of the present invention. The execution subject of the video processing method is user equipment. As shown in fig. 1, the video processing method includes the steps of:
step S101, obtaining the playing parameters of the video.
The video playing parameters comprise: the original aspect ratio of the videoVideo original aspect ratioRefers to the aspect ratio of the video recording.
Optionally, the video playing parameters may further include: the width w and height h of the currently active area of the video. As shown in fig. 2, the width w and the height h of the current effective area of the video refer to the width and the height of the actual visible picture of the video with the black border removed under the current format (e.g., avi, rm, mov, etc.).
Three ways to obtain the playing parameters are described below, but this is only an example and not a limitation. In the following three ways, the playing parameters all include the original aspect ratio of the videoAnd the width w and the height h of the current effective area of the video, but this is only for convenience of description, and in fact, the playing parameters may only include the original aspect ratio of the videoBecause the width w and the height h of the active area when outputting the video are calculated as will be described later, the width w and the height h of the current active area of the video may not necessarily be required, and refer to the detailed description of steps s103 and s104 later.
Alternatively, the video playing parameters may be stored in a data block of the video, and the user equipment obtains the playing parameters of the video by reading the data block of the video. The data block may be added to any data block in the original video by the transcoder when the transcoder transcodes the original video.
Specifically, as shown in fig. 3, the data block may be 24 bytes, wherein the first 4 bytes are used to identify the data block as 24 bytes in length. The 5 to 7 bytes are used to identify the type of the data block, which may be an mdat data block, for example. 8 to 24 bytes are used to store video playback parameters. Therefore, when the user equipment reads the data block, the playing parameters of the video can be obtained. It should be noted that the present invention is described only by the structure of the data block, and the present invention is not limited thereto.
Optionally, the file suffix name of the video may contain the video playing parameter, and the user equipment obtains the playing parameter of the video by reading the file suffix name of the video. For example, when the transcoder transcodes the original video, the transcoder adds the video playing parameters to the file suffix name of the video.
Specifically, the file name may be: filename. w _ h _ m _ n.3gp. For example, the existing video file is named<<Gaffea cat 3gp>>The width w of the current effective area of the video is 800, the height h is 450, and the original aspect ratio of the videoIs composed ofThis video naming can be modified to<<Gaffefield cat 800_450_16_9.3gp>>. Therefore, when the user equipment reads the file name of the video, the playing parameters of the video can be obtained.
Optionally, the user equipment reads a frame of the video to obtain the playing parameters of the video. Wherein the color of the frame is used to represent the original aspect ratio of the videoThe width and height of the color area are used to indicate the width w and height h of the currently active area of the video. The frame may be any frame of the video, and may be the first frame added to the original video by the transcoder when the transcoder transcodes the original video.
For example, red indicates that the original aspect ratio of the video is 5: 4. if the first frame of the video is red, and the actual effective area width of the red area is 800, and the actual effective area height is 540, the user equipment can know by reading the first frame of the video,w =800, h = 540. It should be noted that the original aspect ratio of the video is represented by red only, and is 5: 4, the actual effective area width of the red area is 800, and the height is 540 for the illustration, which is not to limit the invention. Also, the frame may be used to represent the original aspect ratio of the video with only preset colors.
Step S102, acquiring the width a and the height b of the screen of the user equipment.
Step S103, according to the original aspect ratio of the videoAnd the width a and height b of the screen of the user equipment, and the width x and height y of the effective area when the video is output are calculated.
Specifically, when calculating the width x and the height y of the effective area in the video output, the following cases can be classified:
When aspect ratio of the screen of the user equipmentGreater than the original aspect ratio of the videoAccording to the original aspect ratio of the videoOutputting the video and playing the video in the maximum range on the screen of the user equipment, directly taking the height b of the screen of the user equipment as the height y of an effective area when the video is output, and then according to the original aspect ratio of the videoAnd the height y of the effective area when the video is output is determined, and the width x of the effective area when the video is output is calculated.
When in useWhen x = a, y = b is calculated.
When aspect ratio of the screen of the user equipmentEqual to the original aspect ratio of the videoAccording to the original aspect ratio of the videoAnd outputting the video and playing the video in the maximum range on the screen of the user equipment, wherein the width a of the screen of the user equipment can be directly used as the width x of an effective area when the video is output, and the height b of the screen of the user equipment can be used as the height y of the effective area when the video is output.
when aspect ratio of the screen of the user equipmentLess than the original aspect ratio of the videoAccording to the original aspect ratio of the videoOutputting video and playing in the maximum range on the screen of the user equipment, the width a of the screen of the user equipment can be directly used as the width x of an effective area when the video is output, and then the video is output according to the original aspect ratio of the videoAnd the determined width x of the effective area when the video is output calculates the height y of the effective area when the video is output.
Step S104, according to the calculated width x and height y of the effective area when the video is output, the video is output.
Thus, according to the calculated width x and height y of the effective area when the video is output, the video is output to ensure that the video is played in the original proportion and in the maximum visible range.
Optionally, after the width x and the height y of the effective area in the video output are calculated, the width w and the height h of the current effective area of the video can be stretched or scaled according to x and y, respectively, so that the video is played on the screen in the maximum visual range according to the original scale.
With the video processing method provided by the first embodiment of the present invention, since the video may be a video after compression transcoding, the aspect ratio of the current effective area of the video may not be the aspect ratio of the video when recording, by obtaining the original aspect ratio of the video, and using the original aspect ratio of the video and the width and height of the screen of the user equipment, the original ratio of the video can be calculated, and in the case of playing in the maximum range on the user equipment, the width and height of the effective area that should be output are calculated, and then the video is played according to the calculated width and height of the effective area when the video is output. The method does not need manual setting of a user, can enable the video to automatically adapt to the screen size of user equipment, and ensures that the video is played in the original proportion and in the maximum visual range.
Fig. 4 is a schematic diagram illustrating a video processing apparatus according to a second embodiment of the present invention, and fig. 4 is a schematic diagram illustrating a structure of the video processing apparatus according to the second embodiment of the present invention. The video apparatus is used for a user equipment to implement the video processing method provided by the first embodiment of the present invention, and similar parts are not described again.
As shown in fig. 4, the video processing apparatus includes: a first obtaining unit 210, a second obtaining unit 220, a calculating unit 230 and an output unit 240.
The first obtaining unit 210 is configured to obtain a playing parameter of a video.
The video playing parameters comprise: the original aspect ratio of the videoVideo original aspect ratioRefers to the aspect ratio of the video recording.
Optionally, the video playing parameters may further include: the width w and height h of the currently active area of the video.
Optionally, the first obtaining unit 210 is specifically configured to read a data block of the video, and obtain the playing parameter from the first data block, where the playing parameter is stored in the data block. The data block may be added to any data block in the original video by the transcoder when the transcoder transcodes the original video.
Specifically, the data block may be 24 bytes, wherein the first 4 bytes are used to identify the data block as 24 bytes in length. The 5 to 7 bytes are used to identify the type of the data block, which may be an mdat data block, for example. 8 to 24 bytes are used to store video playback parameters. Therefore, when the first obtaining unit 210 reads the first data block of the video, the playing parameters of the video can be known. It should be noted that the present invention is described only by the structure of the data block, and the present invention is not limited thereto.
Optionally, the first obtaining unit 210 is specifically configured to read a file suffix name of the video, and obtain the playing parameter from the file suffix name, where the file suffix name of the video includes the video playing parameter. For example, when the transcoder transcodes the original video, the transcoder adds the video playing parameters to the file suffix name of the video.
Optionally, the first obtaining unit 210 is specifically configured to read one frame of the video; the playback parameters are obtained by the color of the frame and the width and height of the color area. Wherein the color of the frame is used to represent the original aspect ratio of the videoThe width and height of the color area are used to indicate the width w and height h of the currently active area of the video. The frame may be any frame of the video that may be added to the original video by the transcoder when the transcoder transcodes the original video.
The second obtaining unit 220 is used for obtaining the width a and the height b of the screen of the user equipment.
The computing unit 230 is used for calculating the original aspect ratio of the videoAnd the width a and height b of the screen of the user equipment, and the width x and height y of the effective area when the video is output are calculated.
Specifically, when calculating the width x and the height y of the effective area when outputting the video, the calculating unit 230 may be divided into the following cases:
When aspect ratio of the screen of the user equipmentGreater than the original aspect ratio of the videoAccording to the original aspect ratio of the videoOutputting the video and playing the video in the maximum range on the screen of the user equipment, directly taking the height b of the screen of the user equipment as the height y of an effective area when the video is output, and then according to the original aspect ratio of the videoAnd the height y of the effective area when the video is output is determined, and the width x of the effective area when the video is output is calculated.
When aspect ratio of the screen of the user equipmentEqual to the original aspect ratio of the videoAccording to the original aspect ratio of the videoAnd outputting the video and playing the video in the maximum range on the screen of the user equipment, wherein the width a of the screen of the user equipment can be directly used as the width x of an effective area when the video is output, and the height b of the screen of the user equipment can be used as the height y of the effective area when the video is output.
when aspect ratio of the screen of the user equipmentLess than the original aspect ratio of the videoAccording to the original aspect ratio of the videoOutputting video and playing in the maximum range on the screen of the user equipment, the width a of the screen of the user equipment can be directly used as the width x of an effective area when the video is output, and then the video is output according to the original aspect ratio of the videoAnd the determined width x of the effective area when the video is output calculates the height y of the effective area when the video is output.
The output unit 240 is configured to output the video according to the calculated width x and height y of the effective area when the video is output.
Optionally, after the calculating unit 230 calculates the width x and the height y of the effective area when the video is output, the output unit 240 is specifically configured to stretch or scale the width w and the height h of the current effective area of the video according to x and y, respectively, so that the video is played on the screen in the maximum visible range according to the original scale.
It should be noted that, similar to the method embodiment, the playing parameters may also include only the original aspect ratio of the videoThe width w and height h of the currently active area of the video may not necessarily be required.
With the video processing apparatus provided in the second embodiment of the present invention, since the video may be a video after compression transcoding, the aspect ratio of the current effective area of the video may not be the aspect ratio of the video when recording, by obtaining the original aspect ratio of the video, and using the original aspect ratio of the video and the width and height of the screen of the user equipment, the width and height of the effective area that should be output can be calculated, and when playing is performed in the maximum range on the user equipment, the width and height of the effective area that should be output are calculated, and then the video is played according to the calculated width and height of the effective area when the video is output. The device can automatically adapt to the screen size of the user equipment without manual setting of a user, and ensures that the video is played in the original proportion and in the maximum visual range.
Fig. 5 is a schematic structural diagram of a user equipment according to a third embodiment of the present invention. The user equipment includes a transceiver 310, a memory 320, and a processor 330 connected to the transceiver 310 and the memory 320, respectively. Of course, the user equipment may further include general components such as an antenna, a baseband processing component, a medium radio frequency processing component, and an input/output device, and the embodiment of the present invention is not limited in any way here.
Wherein the memory 320 stores a set of program codes therein, and the processor 330 is configured to call the program codes stored in the memory 320 for performing the following operations:
acquiring playing parameters of a video, wherein the playing parameters comprise: the original aspect ratio of the video;
acquiring the width and height of a screen of user equipment;
calculating the width and height of an effective area when the video is output according to the original aspect ratio of the video and the width and height of the screen of the user equipment;
and outputting the video according to the calculated width and height of the effective area when the video is output.
Further, the playing parameters further include: the width and height of the current effective area of the video; the outputting the video according to the calculated width and height of the effective area when the video is output specifically comprises: and stretching or scaling the width and the height of the current effective area of the video so as to output the video with the calculated width and the calculated height of the effective area when the video is output.
Further, the acquiring of the playing parameters of the video specifically includes:
reading a data block included in the video; acquiring the playing parameters from the data blocks; wherein the data block stores the playing parameter.
Further, the acquiring of the playing parameters of the video specifically includes:
reading a file suffix name of the video; acquiring the playing parameters from the file suffix name; wherein the file suffix name contains the playing parameter.
Further, the acquiring of the playing parameters of the video specifically includes:
reading a frame of the video; acquiring the playing parameters through preset colors in the frame of the video or the width and the height of the preset colors and color areas; wherein, the color is used for representing the original aspect ratio of the video, and the width and height of the color area are used for representing the width and height of the current effective area of the video.
Further, the calculating the width and height of the effective area when the video is output specifically includes:
when in useTime, calculatey = b; when in useWhen x = a, y = b is calculated; when in useWhen, x = a is calculated,
with the user equipment provided by the third embodiment of the present invention, since the video may be a video after compression transcoding, the aspect ratio of the current effective area of the video may not be the aspect ratio of the video when recording, by obtaining the original aspect ratio of the video, and using the original aspect ratio of the video and the width and height of the screen of the user equipment, the original ratio of the video can be calculated, and in the case of playing in the maximum range on the user equipment, the width and height of the effective area that should be output are calculated, and then the video is played according to the calculated width and height of the effective area when the video is output. By utilizing the user equipment, the user does not need to manually set, the video can automatically adapt to the screen size of the user equipment, and the video is ensured to be played in the original proportion and in the maximum visual range.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied in hardware, a software module executed by a processor, or a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above-mentioned embodiments are intended to illustrate the objects, technical solutions and advantages of the present invention in further detail, and it should be understood that the above-mentioned embodiments are merely exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.
Claims (12)
1. A method of video processing, the method comprising:
acquiring playing parameters of a video, wherein the playing parameters comprise: the original aspect ratio of the video;
acquiring the width and height of a screen of user equipment;
calculating the width and height of an effective area when the video is output according to the original aspect ratio of the video and the width and height of the screen of the user equipment;
and outputting the video according to the calculated width and height of the effective area when the video is output.
2. The method of claim 1, wherein the playback parameters further comprise: the width and height of the current effective area of the video;
the outputting the video according to the calculated width and height of the effective area when the video is output specifically comprises:
and stretching or scaling the width and the height of the current effective area of the video so as to output the video with the calculated width and the calculated height of the effective area when the video is output.
3. The method according to claim 1 or 2, wherein the obtaining of the video playing parameters specifically comprises:
reading a data block included in the video;
acquiring the playing parameters from the data blocks;
wherein the data block stores the playing parameter.
4. The method according to claim 1 or 2, wherein the obtaining of the video playing parameters specifically comprises:
reading a file suffix name of the video;
acquiring the playing parameters from the file suffix name;
wherein the file suffix name contains the playing parameter.
5. The method according to claim 2, wherein the obtaining of the video playing parameters specifically comprises:
reading a frame of the video;
acquiring the playing parameters through preset colors in the frame of the video or the width and the height of the preset colors and color areas;
wherein, the color is used for representing the original aspect ratio of the video, and the width and height of the color area are used for representing the width and height of the current effective area of the video.
6. The method according to any one of claims 1-5, wherein the calculating the width and height of the effective area when outputting the video is specifically:
7. A video processing apparatus, characterized in that the apparatus comprises:
a first obtaining unit, configured to obtain a playing parameter of a video, where the playing parameter includes: the original aspect ratio of the video;
the second acquisition unit is used for acquiring the width and the height of a screen of the user equipment;
the calculating unit is used for calculating the width and the height of an effective area when the video is output according to the original aspect ratio of the video and the width and the height of the screen of the user equipment;
and an output unit configured to output the video according to the calculated width and height of the effective area when the video is output.
8. The apparatus of claim 7, wherein the playback parameters further comprise: the width and height of the current effective area of the video;
the output unit is specifically configured to:
and stretching or scaling the width and the height of the current effective area of the video so as to output the video with the calculated width and the calculated height of the effective area when the video is output.
9. The apparatus according to claim 7 or 8, wherein the first obtaining unit is specifically configured to:
reading a data block included in the video;
acquiring the playing parameters from the data blocks;
wherein the data block stores the playing parameter.
10. The apparatus according to claim 7 or 8, wherein the first obtaining unit is specifically configured to:
reading a file suffix name of the video;
acquiring the playing parameters from the file suffix name;
wherein the file suffix name contains the playing parameter.
11. The apparatus according to claim 8, wherein the first obtaining unit is specifically configured to:
reading a frame of the video;
acquiring the playing parameters through preset colors in the frame of the video or the width and the height of the preset colors and color areas;
wherein, the color is used for representing the original aspect ratio of the video, and the width and height of the color area are used for representing the width and height of the current effective area of the video.
12. The apparatus according to any one of claims 7-11, wherein the computing unit is specifically configured to:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310239567XA CN103297729A (en) | 2013-06-17 | 2013-06-17 | Video processing method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310239567XA CN103297729A (en) | 2013-06-17 | 2013-06-17 | Video processing method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN103297729A true CN103297729A (en) | 2013-09-11 |
Family
ID=49097970
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310239567XA Pending CN103297729A (en) | 2013-06-17 | 2013-06-17 | Video processing method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103297729A (en) |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103716575A (en) * | 2013-12-11 | 2014-04-09 | 乐视致新电子科技(天津)有限公司 | Display device and display control method capable of adjusting definition |
CN103745709A (en) * | 2014-01-24 | 2014-04-23 | 福州瑞芯微电子有限公司 | Embedded self-adaptive screen displaying method |
WO2017005064A1 (en) * | 2015-07-07 | 2017-01-12 | 深圳Tcl数字技术有限公司 | Playing method and device for programme information |
CN107087158A (en) * | 2017-05-15 | 2017-08-22 | 北京奇艺世纪科技有限公司 | A kind of method for broadcasting multimedia file and device |
WO2017193576A1 (en) * | 2016-05-13 | 2017-11-16 | 乐视控股(北京)有限公司 | Video resolution adaptation method and apparatus, and virtual reality terminal |
CN109672840A (en) * | 2018-12-17 | 2019-04-23 | 蜂巢(武汉)微系统技术有限公司 | A kind of reverse image aspect ratio modification method and system |
CN110286868A (en) * | 2019-06-28 | 2019-09-27 | 北京金山安全软件有限公司 | Video display adjustment method and device, electronic equipment and storage medium |
CN112351314A (en) * | 2019-08-07 | 2021-02-09 | 腾讯数码(天津)有限公司 | Multimedia information playing method, server, terminal, system and storage medium |
CN113891167A (en) * | 2021-08-27 | 2022-01-04 | 荣耀终端有限公司 | Screen projection method and electronic equipment |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070136685A1 (en) * | 2005-12-08 | 2007-06-14 | Nikhil Bhatla | Adaptive Media Player Size |
CN101582254A (en) * | 2008-05-13 | 2009-11-18 | 深圳华为通信技术有限公司 | Method and device for presenting image |
CN101742157A (en) * | 2009-12-28 | 2010-06-16 | 深圳华为通信技术有限公司 | Video display method and device |
CN102025936A (en) * | 2010-11-26 | 2011-04-20 | 中兴通讯股份有限公司 | Video aspect ratio conversion method and device |
CN102377960A (en) * | 2010-08-24 | 2012-03-14 | 腾讯科技(深圳)有限公司 | Video picture displaying method and device |
-
2013
- 2013-06-17 CN CN201310239567XA patent/CN103297729A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070136685A1 (en) * | 2005-12-08 | 2007-06-14 | Nikhil Bhatla | Adaptive Media Player Size |
CN101582254A (en) * | 2008-05-13 | 2009-11-18 | 深圳华为通信技术有限公司 | Method and device for presenting image |
CN101742157A (en) * | 2009-12-28 | 2010-06-16 | 深圳华为通信技术有限公司 | Video display method and device |
CN102377960A (en) * | 2010-08-24 | 2012-03-14 | 腾讯科技(深圳)有限公司 | Video picture displaying method and device |
CN102025936A (en) * | 2010-11-26 | 2011-04-20 | 中兴通讯股份有限公司 | Video aspect ratio conversion method and device |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103716575A (en) * | 2013-12-11 | 2014-04-09 | 乐视致新电子科技(天津)有限公司 | Display device and display control method capable of adjusting definition |
CN103745709A (en) * | 2014-01-24 | 2014-04-23 | 福州瑞芯微电子有限公司 | Embedded self-adaptive screen displaying method |
WO2017005064A1 (en) * | 2015-07-07 | 2017-01-12 | 深圳Tcl数字技术有限公司 | Playing method and device for programme information |
WO2017193576A1 (en) * | 2016-05-13 | 2017-11-16 | 乐视控股(北京)有限公司 | Video resolution adaptation method and apparatus, and virtual reality terminal |
CN107087158A (en) * | 2017-05-15 | 2017-08-22 | 北京奇艺世纪科技有限公司 | A kind of method for broadcasting multimedia file and device |
CN109672840A (en) * | 2018-12-17 | 2019-04-23 | 蜂巢(武汉)微系统技术有限公司 | A kind of reverse image aspect ratio modification method and system |
CN109672840B (en) * | 2018-12-17 | 2020-12-08 | 蜂巢(武汉)微系统技术有限公司 | Method and system for correcting aspect ratio of reverse image |
CN110286868A (en) * | 2019-06-28 | 2019-09-27 | 北京金山安全软件有限公司 | Video display adjustment method and device, electronic equipment and storage medium |
CN112351314A (en) * | 2019-08-07 | 2021-02-09 | 腾讯数码(天津)有限公司 | Multimedia information playing method, server, terminal, system and storage medium |
CN113891167A (en) * | 2021-08-27 | 2022-01-04 | 荣耀终端有限公司 | Screen projection method and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103297729A (en) | Video processing method and device | |
EP3157242B1 (en) | Display system, display method, and display device | |
CN108737882B (en) | Image display method, image display device, storage medium and electronic device | |
WO2017193576A1 (en) | Video resolution adaptation method and apparatus, and virtual reality terminal | |
CN111552530B (en) | Terminal screen adaptation method, device and equipment of user interface | |
CN103823620B (en) | Screen adaption method and device | |
EP2953369A1 (en) | Methods, apparatuses and computer programs for adapting content | |
CN106412687B (en) | Method and device for intercepting audio and video clips | |
CN104980773B (en) | streaming media processing method and device, terminal and server | |
US20190238813A1 (en) | Method and apparatus for generating hdri | |
US20150156557A1 (en) | Display apparatus, method of displaying image thereof, and computer-readable recording medium | |
CN105469381B (en) | Information processing method and terminal | |
CN109547724B (en) | Video stream data processing method, electronic equipment and storage device | |
CN110913278B (en) | Video playing method, display terminal and storage medium | |
JP2014165764A (en) | Editing device, editing method and editing program | |
KR102327972B1 (en) | Projection image construction method and device | |
CN109785239B (en) | Image processing method and device | |
KR20180000729A (en) | Display device and control method therefor | |
US20150067721A1 (en) | Method and system for transmitting videos to mobile phones | |
CN106470353B (en) | Multimedia data processing method and device and electronic equipment | |
CN103546828B (en) | The generation method and device of previewing programs | |
US20170161875A1 (en) | Video resolution method and apparatus | |
CN110166798B (en) | Down-conversion method and device based on 4K HDR editing | |
CN110913118B (en) | Video processing method, device and storage medium | |
JP2019149785A (en) | Video conversion device and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20130911 |
|
RJ01 | Rejection of invention patent application after publication |