CN108881743B - Video image processing method, device and system based on splicing wall - Google Patents

Video image processing method, device and system based on splicing wall Download PDF

Info

Publication number
CN108881743B
CN108881743B CN201810797751.9A CN201810797751A CN108881743B CN 108881743 B CN108881743 B CN 108881743B CN 201810797751 A CN201810797751 A CN 201810797751A CN 108881743 B CN108881743 B CN 108881743B
Authority
CN
China
Prior art keywords
image
width
height
display window
scaled
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
CN201810797751.9A
Other languages
Chinese (zh)
Other versions
CN108881743A (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.)
Vtron Group Co Ltd
Original Assignee
Vtron Group 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 Vtron Group Co Ltd filed Critical Vtron Group Co Ltd
Priority to CN201810797751.9A priority Critical patent/CN108881743B/en
Publication of CN108881743A publication Critical patent/CN108881743A/en
Application granted granted Critical
Publication of CN108881743B publication Critical patent/CN108881743B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/2628Alteration of picture size, shape, position or orientation, e.g. zooming, rotation, rolling, perspective, translation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/01Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level
    • H04N7/0117Conversion of standards, e.g. involving analogue television standards or digital television standards processed at pixel level involving conversion of the spatial resolution of the incoming video signal

Abstract

The embodiment of the application discloses a video image processing method, a device, a system and equipment based on a splicing wall, which comprises the following steps: decoding the video code stream to obtain an original image; zooming the original image to the width and height corresponding to the maximum display of the original image in the display window according to the first aspect ratio of the original image to obtain a first zoomed image; zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio of the second zoomed image to the preset output resolution is equal to the first height ratio of the first zoomed image to the display window; and placing the second zooming image in a space corresponding to the preset output resolution, and obtaining an output image according to the space. The embodiment of the application solves the problem that when the resolution of the video image output by the signal source changes, the video image cannot be normally displayed.

Description

Video image processing method, device and system based on splicing wall
Technical Field
The present application relates to the field of multimedia technologies, and in particular, to a method, an apparatus, a system, and a device for processing video images based on a mosaic wall.
Background
The spliced wall has the display capacity of ultrahigh resolution, and can converge and display audio and video signals sent by various signal sources. Generally, a wall-splicing operator opens a display window for a signal source, so that a video image output by the signal source is displayed in the display window.
However, when the resolution of the video image output from the signal source is changed, the video image may not be normally displayed. For example, when a mobile phone is used as a signal source and a video image shot by the mobile phone is displayed on the wall, a user switches the mobile phone from a horizontal screen to a vertical screen in the shooting process, and at the moment, the resolution of the video image shot by the mobile phone changes, so that the image displayed on a display window is distorted and deformed; meanwhile, the decoder may restart due to the resolution change of the video image, thereby causing the display of the video image to be interrupted; both of the above situations may cause the video image not to be displayed normally.
Therefore, when the resolution of the video image output by the signal source changes, how to ensure that the video image can be normally displayed is an urgent problem to be solved by those skilled in the art.
Disclosure of Invention
The embodiment of the application provides a video image processing method, a video image processing device, a video image processing system and video image processing equipment based on a splicing wall, so that when the resolution of a video image output by a signal source changes, the video image can be normally displayed.
In view of the above, a first aspect of the present application provides a video image processing method based on a mosaic wall, where the method includes:
decoding the video code stream to obtain an original image;
zooming the original image to a width and a height which correspond to the maximum display of the original image in a display window according to the first aspect ratio of the original image to obtain a first zoomed image;
zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio of the second zoomed image to the preset output resolution is equal to the first height ratio of the first zoomed image to the display window;
and placing the second zooming image in a space corresponding to the preset output resolution, and obtaining an output image according to the space so as to display the output image in the display window.
Preferably, the scaling the original image to a width and a height corresponding to the maximum display of the original image in the display window according to the first aspect ratio of the original image, and obtaining the first scaled image specifically includes:
if the first aspect ratio of the original image is smaller than the second aspect ratio of the display window, zooming the original image according to the first aspect ratio until the height of the original image is equal to the height of the display window to obtain a first zoomed image;
otherwise, the original image is zoomed according to the first aspect ratio until the width of the original image is equal to the width of the display window, and a first zoomed image is obtained.
Preferably, the scaling the first scaled image to obtain a second scaled image, where a second width ratio of the second scaled image to a preset output resolution is equal to a first width ratio of the first scaled image to the display window, and a second height ratio of the second scaled image to the preset output resolution is equal to a first height ratio of the first scaled image to the display window specifically includes:
adjusting the width of the first scaled image to be equal to the product of the first width ratio and the width of the preset output resolution;
and adjusting the height of the first zooming image to be equal to the product of the first height ratio and the height of the preset output resolution to obtain a second zooming image.
Preferably, the placing the second zoomed image in a space corresponding to the preset output resolution, and obtaining an output image according to the space specifically includes:
and storing the pixel data of the second zooming image into a memory space distributed according to the width and the height of the preset output resolution, and obtaining an output image according to the memory space.
Preferably, the storing the pixel data of the second scaled image into the memory space allocated according to the width and height of the preset output resolution specifically includes:
storing the pixel data of the second zoomed image into a preset space of the memory space;
an initial abscissa of the preset space relative to the memory space corresponds to half of a difference between the width of the preset output resolution and the width of the second zoom image, and an initial ordinate corresponds to half of a difference between the height of the preset output resolution and the height of the second zoom image;
the preset space stores pixel data with a width of the second zoom image and a height of the second zoom image.
Preferably, before the scaling the original image to the width and the height of the original image corresponding to the maximum display of the original image in the display window according to the first aspect ratio of the original image, the obtaining a first scaled image further includes:
updating the width and height of the display window in response to a change in the width or height of the display window.
A second aspect of the present application provides a video image processing apparatus based on a mosaic wall, the apparatus comprising:
the original image acquisition module is used for decoding the video code stream to obtain an original image;
the first scaling module is used for scaling the original image to the width and the height which correspond to the maximum display of the original image in a display window according to the first aspect ratio of the original image to obtain a first scaled image;
a second scaling module, configured to scale the first scaled image to obtain a second scaled image, where a second width ratio of the second scaled image to a preset output resolution is equal to a first width ratio of the first scaled image to the display window, and a second height ratio of the second scaled image to the preset output resolution is equal to a first height ratio of the first scaled image to the display window;
and the output image generation module is used for placing the second zooming image in a space corresponding to the preset output resolution, and obtaining an output image according to the space so as to be convenient for displaying the output image in the display window.
Preferably, the method further comprises the following steps:
and the window information updating module is used for responding to the change of the width or the height of the display window and updating the width and the height of the display window.
A third aspect of the present application provides a video image processing system based on a mosaic wall, including:
a signal source, the video image processing device based on the splicing wall, the splicing processor and the splicing wall in the second aspect;
the video image processing device based on the splicing wall processes the video image sent by the signal source to obtain an output image, the output image is sent to the splicing processor, and the splicing processor displays the output image on the splicing wall.
A fourth aspect of the present application provides a video image processing apparatus based on a mosaic wall, the apparatus comprising a processor and a memory:
the memory is used for storing program codes and transmitting the program codes to the processor;
the processor is configured to execute the method for processing video images based on a mosaic wall according to the first aspect.
According to the technical scheme, the embodiment of the application has the following advantages:
in the embodiment of the application, a video image processing method based on a mosaic wall is provided, an original image is obtained by decoding a video, the original image is scaled according to a first aspect ratio of the original image, and the original image is scaled to a width and a height corresponding to the maximum display of the original image in a display window to obtain a first scaled image, wherein the true aspect ratio of the original image is maintained in the scaling process, so that the obtained first scaled image is not distorted, and the width and the height of the first scaled image are just the width and the height capable of being maximally displayed in the display window; secondly, zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio is equal to the first height ratio of the first zoomed image to the display window; the first zoom image can be understood as being adapted to the display window, and the second zoom image can be understood as being adapted to the preset output resolution, so that the process of twice zooming is a process of adapting the image from the display window to the preset output resolution, and the width ratio and the height ratio of the image before twice zooming and the image after twice zooming to the window or the resolution to which the image is adapted are kept unchanged, so that the image after twice zooming can also be adapted to the object to which the image is adapted, namely the preset output resolution, in the same maximization way as before twice zooming; the second zoom image is placed in a space corresponding to a preset output resolution, and the output image is obtained according to the space, so that the resolution of the output image is changed into the preset output resolution, and the output image comprises the content of the second zoom image.
By the method, after the original image is processed into the output image, when the output image is displayed in the display window, the output image is automatically zoomed to the size of the display window, which is equivalent to automatically performing inverse zooming on the secondary zooming, so that the part of the second zoomed image in the output image is changed back to the first zoomed image, and the first zoomed image is the image which keeps the real aspect ratio and adapts to the maximum display of the display window, so that the displayed image is not distorted and deformed. In summary, the method provided by the embodiment of the present application solves the problems of decoder restart and aspect ratio distortion caused by the change of the resolution of the signal source, thereby ensuring that the video image can be normally displayed.
Drawings
Fig. 1 is a schematic flowchart of a video image processing method based on a mosaic wall according to a first embodiment of the present disclosure;
fig. 2 is a schematic flowchart of a video image processing method based on a mosaic wall according to a second embodiment of the present disclosure;
fig. 3 is a schematic flowchart of a video image processing method based on a mosaic wall according to a third embodiment of the present disclosure;
FIG. 4 is a schematic structural diagram of an embodiment of a video image processing apparatus based on a mosaic wall according to the present application, corresponding to the method shown in FIG. 1;
FIG. 5 is an architecture diagram of an embodiment of a video image processing system based on a tiled wall as provided herein;
fig. 6 is a schematic structural diagram of an embodiment of a video image processing apparatus based on a mosaic wall according to the present application.
Detailed Description
In order to make the technical solutions of the present application better understood, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, 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 application.
The video image processing method based on the splicing wall can solve the problem that a video image cannot be normally displayed when the resolution of a signal source changes. The video image is provided by a signal source, the signal source may be various types of devices, such as a mobile phone, a video camera, a tablet computer, and the like, and any device capable of providing a video image can be used as the signal source, which is not limited herein.
The situation of the change of the resolution of the signal source is very common, for example, when the network speed delay is high, the resolution of the video image may be dynamically adjusted, or the resolution of the video image may be changed when the horizontal and vertical screen switching is performed in the mobile phone shooting process.
For easy understanding, please refer to fig. 1, in which fig. 1 is a schematic flowchart illustrating a video image processing method based on a mosaic wall according to a first embodiment of the present disclosure. The method in this embodiment comprises the steps of:
step 101: and decoding the video code stream to obtain an original image.
The video image acquired at the signal source end is usually transmitted in the form of a video code stream, and in order to perform corresponding processing on the video image, the video code stream needs to be decoded to obtain an original image. The original image may specifically be data in YUV, RGB, or other formats, and obviously, the data includes resolution information of the original image, and the resolution information correspondingly includes a width and a height of the original image.
The screen resolution refers to the resolution of the screen display, and the resolution of the screen display is expressed by the number of pixels displayed on the screen, and is usually expressed by the product of the number of pixels in the width direction and the number of pixels in the height direction, for example, the resolution of 160 × 128 means that the number of pixels in the width direction is 160, and the number of pixels in the height direction is 128; it should be understood that the resolution 160 × 128 and the resolution 128 × 160 are different resolutions, and the number of pixels in the width direction and the height direction is different although the number of pixels is the same.
According to the definition of the resolution, it should be understood that the "width" in the above "resolution information, which correspondingly includes the width and the height of the original image," should be understood as the number of pixels in the width direction, and the "height" should be understood as the number of pixels in the height direction.
Step 102: and according to the first aspect ratio of the original image, scaling the original image to the width and height corresponding to the maximum display of the original image in the display window to obtain a first scaled image.
Scaling the original image according to the first aspect ratio of the original image, so that the first scaled image obtained after scaling still keeps the real aspect ratio; it should be understood that the first scaled image is not within the display window, and the first scaled image should be independent from the display window, except that the first scaled image is displayed maximally with respect to the display window when the first scaled image is placed within the display window.
Step 103: and zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio of the second zoomed image to the preset output resolution is equal to the first height ratio of the first zoomed image to the display window.
After the first zoom image is obtained through the first zoom, the first zoom image needs to be subjected to secondary zoom, a second width ratio and a second height ratio of a second zoom image obtained after the secondary zoom and the preset output resolution are respectively corresponding to a first width ratio and a first height ratio of the first zoom image before the secondary zoom and the display window, the image after the secondary zoom is changed from being adaptive to the preset output resolution from being adaptive to the display window, and the width ratio and the height ratio when the image is adaptive to the display window are maintained, so that the second zoom image can also display the corresponding width and height in the preset output resolution to the maximum.
It is understood that the preset output resolution should be a preset resolution, and the preset output resolution may be a resolution of any size in theory, such as 1024 × 768 or 1920 × 1080, and the preset resolution can be applied to the method provided in the embodiment of the present application regardless of the set resolution.
Step 104: and placing the second zooming image in a space corresponding to the preset output resolution, and obtaining an output image according to the space so as to display the output image in the display window.
It should be understood that the output image is obtained from a space corresponding to the preset output resolution, and thus the output image should have the same resolution as the preset output resolution, and the second scaled image is placed in the space corresponding to the preset output resolution such that the output image includes the content of the second scaled image.
It should be noted that, after the output image is obtained, the output image needs to be re-encoded and converted into an output code stream in a video code stream data format, further, the output code stream may be input to the splicing processor and may be decoded by a decoding module of the splicing processor, at this time, since the output image always maintains a preset output resolution, correspondingly, the resolution of the output code stream is also always unchanged, and the decoding module of the splicing processor is not restarted; the splicing processor outputs the decoded data to a splicing wall for displaying, specifically, the data should be displayed in a display window set by a splicing wall operator.
In the first embodiment, an original image is obtained by decoding a video, the original image is scaled according to a first aspect ratio of the original image, and the original image is scaled to a width and a height corresponding to the maximum display of the original image in a display window, so as to obtain a first scaled image; secondly, zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio is equal to the first height ratio of the first zoomed image to the display window; and placing the second zooming image in a space corresponding to a preset output resolution, and obtaining an output image according to the space.
When the output image is displayed in the display window, since the output image will automatically be scaled to the size of the display window, since the second scaling of the first scaled image to the second scaled image maintains the ratio of the width to the height of the image as it fits in the display window before the second scaling, the automatic scaling of the output image to the size of the display window is thus equivalent to automatically inverse scaling the above-mentioned quadratic scaling, so that the portion of the second scaled image in the output image is changed back to the first scaled image, which is scaled with the original image maintaining its own aspect ratio, and its width and height are just the width and height that can maximize the display in the display window, therefore, the effect of displaying the output image in the display window is that the original image maintains the effect of maximum display of the real aspect ratio in the display window; and because the resolution of the output image received by the decoder is always the preset output resolution, the decoder is not restarted, thereby solving the problem that the video image can not be normally displayed when the resolution of the video image output by the signal source is changed.
Referring to fig. 2, fig. 2 is a schematic flowchart illustrating a video image processing method based on a mosaic wall according to a second embodiment of the present disclosure. The second embodiment comprises the following steps:
step 201: and decoding the video code stream to obtain an original image.
This step is the same as step 101 in the first embodiment, and the detailed description is given above and will not be repeated herein.
Step 202: if the first aspect ratio of the original image is smaller than the second aspect ratio of the display window, zooming the original image according to the first aspect ratio until the height of the original image is equal to the height of the display window to obtain a first zoomed image; otherwise, scaling the original image according to the first aspect ratio until the width of the original image is equal to the width of the display window to obtain a first scaled image.
The method comprises the steps that the width-to-height ratio of an original image depends on a signal source, operators of a spliced wall often do not know the resolution of the signal source, so that an opened display window may be different from the width-to-height ratio of the original image, the original image is zoomed in to a state that blank parts are often left in the display window when the display window is displayed in a maximized mode, and the blank parts are left.
On the basis of scaling the original image with the real first aspect ratio, for the first case, the original image is scaled to have the height equal to the height of the display window, so that the original image can be adapted to the maximum display of the display window, and for the second case, the original image is scaled to have the width equal to the width of the display window, so that the original image can be adapted to the maximum display of the display window.
Step 203: adjusting the width of the first zoom image to be equal to the product of the first width ratio and the width of the preset output resolution; and adjusting the height of the first zooming image to be equal to the product of the first height ratio and the height of the preset output resolution to obtain a second zooming image.
Specifically, the width of the second zoomed image obtained after adjustment is equal to the product of the first width ratio and the width of the preset output resolution, and the height of the second zoomed image is equal to the product of the first height ratio and the height of the preset output resolution.
Step 204: and storing the pixel data of the second zooming image into a memory space distributed according to the width and the height of the preset output resolution, and obtaining an output image according to the memory space so as to display the output image in the display window.
In order to make the resolution of the finally output image be the preset output resolution, a corresponding memory space may be allocated according to the width and height of the preset resolution to store the pixel data of the preset output resolution, and the pixel data of the second scaled image is stored in the memory space, and there are various specific ways of storing the pixel data of the second scaled image in the memory space, such as sending, copying, replacing, and the like, and then the output image is generated according to the memory space in which the pixel data of the second scaled image is stored.
In the second embodiment, an original image is obtained by decoding a video, and in order to scale the original image to be adapted to the maximum display of a display window without distortion, a portion of the image where a blank is left in the display window when the display window is maximally displayed is determined by comparing the aspect ratio of the original image with the aspect ratio of the display window, and then the original image is scaled until one of the width or the height of the original image is the same as that of the display window, so as to obtain a first scaled image; respectively adjusting the width and the height of the first zooming image to obtain a second zooming image, wherein the width of the adjusted second zooming image is equal to the product of the first width ratio and the width of the preset output resolution, and the height of the second zooming image is equal to the product of the first height ratio and the height of the preset output resolution; and storing the pixel data of the second zooming image into a memory space corresponding to a preset output resolution, and obtaining an output image according to the memory space.
When the output image is displayed in the display window, since the output image will automatically be scaled to the size of the display window, because the width ratio and the height ratio of the image before adjustment when the image is adapted to the display window are kept when the first zoom image is adjusted to obtain the second zoom image, the automatic scaling of the output image to the size of the display window is thus equivalent to automatically restoring the above-mentioned adjustment to the first scaled image, so that the portion of the second scaled image in the output image is changed back to the first scaled image, which is scaled with the original image maintaining its own aspect ratio, and its width and height are just the width and height that can maximize the display in the display window, therefore, the effect of displaying the output image in the display window is the effect of maximally displaying the original image in the display window with the real aspect ratio; and because the resolution of the output image received by the decoder is always the preset output resolution, the decoder is not restarted, thereby solving the problem that the video image can not be normally displayed when the resolution of the video image output by the signal source is changed.
The foregoing is a detailed description of a second embodiment of a video image processing method based on a mosaic wall provided by the present application.
Referring to fig. 3, fig. 3 is a schematic flowchart illustrating a video image processing method based on a mosaic wall according to a third embodiment of the present disclosure. The third embodiment comprises the following steps:
step 301: and decoding the video code stream to obtain an original image.
This step is the same as step 101 in the first embodiment, and details thereof are as described above and will not be described herein.
Step 302: the width and height of the display window are updated in response to changes in the width or height of the display window.
The width-height ratio of the original image depends on a signal source, and an operator of the tiled wall often does not know the resolution of the signal source, so that the opened display window may be different from the width-height ratio of the original image, thereby affecting the display effect.
It is understood that this step may also be performed before step 301, as long as it is performed before the original image is scaled for the first time, and the method provided by the embodiment of the present application can be applied.
Step 303: if the first aspect ratio of the original image is smaller than the second aspect ratio of the display window, zooming the original image according to the first aspect ratio until the height of the original image is equal to the height of the display window to obtain a first zoomed image; otherwise, scaling the original image according to the first aspect ratio until the width of the original image is equal to the width of the display window to obtain a first scaled image.
This step is the same as step 202 in the second embodiment, and the detailed description is given above and will not be repeated here.
Step 304: adjusting the width of the first zoom image to be equal to the product of the first width ratio and the width of the preset output resolution; and adjusting the height of the first zooming image to be equal to the product of the first height ratio and the height of the preset output resolution to obtain a second zooming image.
This step is the same as step 203 in the second embodiment, and the detailed description is given above and will not be repeated here.
Step 305: storing the pixel data of the second zoomed image into a preset space of a memory space, and obtaining an output image according to the memory space so as to display the output image in a display window; the initial abscissa of the preset space relative to the memory space corresponds to half of the difference between the width of the preset output resolution and the width of the second zoomed image, and the initial ordinate corresponds to half of the difference between the height of the preset output resolution and the height of the second zoomed image; the preset space stores pixel data having a width of the second scaled image and a height of the second scaled image.
The memory space may be used for storing pixel data of an image, it is understood that a space may be preset in the memory space, the preset space should be used for storing pixel data of a second scaled image, so that the width and height of the pixel data stored in the preset space correspond to the second scaled image, the preset space has a starting point relative to the memory space, a coordinate system may be established with the upper left corner of the memory space as an origin and the width direction as an X-axis, a starting abscissa of the starting point in the coordinate system may correspond to half of a difference between a width of a preset output resolution and a width of an original image, a starting ordinate corresponds to half of a difference between a height of the preset output resolution and a height of the original image, the preset space should be centered relative to the memory space, it is understood that the second scaled image is also centered relative to the output image, therefore, the content of the second zoom image can be displayed in the middle when displayed, and therefore, the better display effect is achieved; the rest of the step can be referred to as step 204 in the second embodiment of the present application, and is not described herein again.
The above is a detailed description of a third embodiment of the video image processing method based on the mosaic wall provided by the present application.
Referring to fig. 4, fig. 4 is a schematic structural diagram of an embodiment of a video image processing apparatus based on a mosaic wall according to the present application, corresponding to the method shown in fig. 1, where the apparatus 400 includes:
an original image obtaining module 401, configured to decode the video code stream to obtain an original image;
a first scaling module 402, configured to scale the original image to a width and a height corresponding to maximum display of the original image in the display window according to a first aspect ratio of the original image, to obtain a first scaled image;
a second scaling module 403, configured to scale the first scaled image to obtain a second scaled image, where a second width ratio of the second scaled image to the preset output resolution is equal to a first width ratio of the first scaled image to the display window, and a second height ratio of the second scaled image to the preset output resolution is equal to a first height ratio of the first scaled image to the display window;
and an output image generating module 404, configured to place the second scaled image in a space corresponding to a preset output resolution, and obtain an output image according to the space, so that the output image is displayed in the display window.
Optionally, the first scaling module 402 is specifically configured to
If the first aspect ratio of the original image is smaller than the second aspect ratio of the display window, zooming the original image according to the first aspect ratio until the height of the original image is equal to the height of the display window to obtain a first zoomed image; otherwise, scaling the original image according to the first aspect ratio until the width of the original image is equal to the width of the display window to obtain a first scaled image.
Optionally, the second scaling module 403 is specifically configured to
Adjusting the width of the first zoom image to be equal to the product of the first width ratio and the width of the preset output resolution; and adjusting the height of the first zooming image to be equal to the product of the first height ratio and the height of the preset output resolution to obtain a second zooming image.
Optionally, the output image generation module 404 is specifically configured to
And storing the pixel data of the second zooming image into a memory space distributed according to the width and the height of a preset output resolution, and obtaining an output image according to the memory space so as to display the output image in the display window.
Optionally, the output image generation module 404 may also be used for
Storing the pixel data of the second zoom image into a preset space of a memory space, and obtaining an output image according to the memory space so as to display the output image in the display window; the initial abscissa of the preset space relative to the memory space corresponds to half of the difference between the width of the preset output resolution and the width of the second zoomed image, and the initial ordinate corresponds to half of the difference between the height of the preset output resolution and the height of the second zoomed image; the preset space stores pixel data having a width of the second scaled image and a height of the second scaled image.
Optionally, the apparatus 400 further includes:
a window information updating module 405, configured to update the width and the height of the display window in response to a change in the width or the height of the display window.
In the video image processing apparatus based on the mosaic wall provided by the embodiment of the application, an original image obtaining module 401 obtains an original image by decoding a video, a first scaling module 402 scales the original image according to a first aspect ratio of the original image, and scales the original image to a width and a height corresponding to maximum display of the original image in a display window, so as to obtain a first scaled image; the second scaling module 403 performs secondary scaling on the first scaled image to obtain a second scaled image, where a second width ratio of the second scaled image to the preset output resolution is equal to a first width ratio of the first scaled image to the display window, and a second height ratio is equal to a first height ratio of the first scaled image to the display window; the output image generation module 404 places the second scaled image in a space corresponding to a preset output resolution, and obtains an output image according to the space.
When the output image is displayed in the display window, since the output image will automatically be scaled to the size of the display window, since the second scaling of the first scaled image to the second scaled image maintains the ratio of the width to the height of the image as it fits in the display window before the second scaling, the automatic scaling of the output image to the size of the display window is thus equivalent to automatically inverse scaling the above-mentioned quadratic scaling, so that the portion of the second scaled image in the output image is changed back to the first scaled image, which is scaled with the original image maintaining its own aspect ratio, and its width and height are just the width and height that can maximize the display in the display window, therefore, the effect of displaying the output image in the display window is that the original image maintains the effect of maximum display of the real aspect ratio in the display window; and because the resolution of the output image received by the decoder is always the preset output resolution, the decoder is not restarted, thereby solving the problem that the video image can not be normally displayed when the resolution of the video image output by the signal source is changed.
Referring to fig. 5, fig. 5 is an architecture diagram of an embodiment of a video image processing system based on a mosaic wall according to the present application, the system including:
a signal source 501, a video image processing device 502 based on a splicing wall, a splicing processor 503 and a splicing wall 504;
the video image processing device 502 based on the mosaic wall processes the video image sent by the signal source 501 to obtain an output image, and sends the output image to the mosaic processor 503, and the mosaic processor displays the output image on the mosaic wall 504.
In the video image processing system based on the splicing wall provided by the embodiment of the application, the video image processing device based on the splicing wall decodes the video to obtain an original image, scales the original image according to the first aspect ratio of the original image, and scales the original image to the width and height of the original image corresponding to the maximum display in the display window to obtain a first scaled image; secondly, zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio is equal to the first height ratio of the first zoomed image to the display window; and placing the second zooming image in a space corresponding to a preset output resolution, and obtaining an output image according to the space.
When the output image is displayed in the display window, since the output image will automatically be scaled to the size of the display window, since the second scaling of the first scaled image to the second scaled image maintains the ratio of the width to the height of the image as it fits in the display window before the second scaling, the automatic scaling of the output image to the size of the display window is thus equivalent to automatically inverse scaling the above-mentioned quadratic scaling, so that the portion of the second scaled image in the output image is changed back to the first scaled image, which is scaled with the original image maintaining its own aspect ratio, and its width and height are just the width and height that can maximize the display in the display window, therefore, the effect of displaying the output image in the display window is that the original image maintains the effect of maximum display of the real aspect ratio in the display window; and because the resolution of the output image received by the decoder is always the preset output resolution, the decoder is not restarted, thereby solving the problem that the video image can not be normally displayed when the resolution of the video image output by the signal source is changed.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an embodiment of a video image processing apparatus based on a mosaic wall according to the present application, where the apparatus 600 includes:
processor 601 and memory 602:
the memory 602 is used for storing program codes and transmitting the program codes to the processor;
the processor 601 is configured to execute the method for processing video images based on a mosaic wall according to any one of the first, second, or third embodiments provided herein according to instructions in the program code.
In the video image processing device based on the splicing wall provided by the embodiment of the application, a processor decodes a video to obtain an original image, scales the original image according to a first aspect ratio of the original image, and scales the original image to a width and a height which correspond to the maximum display of the original image in a display window to obtain a first scaled image; secondly, zooming the first zoomed image to obtain a second zoomed image, wherein the second width ratio of the second zoomed image to the preset output resolution is equal to the first width ratio of the first zoomed image to the display window, and the second height ratio is equal to the first height ratio of the first zoomed image to the display window; and placing the second zooming image in a space corresponding to a preset output resolution, and obtaining an output image according to the space.
When the output image is displayed in the display window, since the output image will automatically be scaled to the size of the display window, since the second scaling of the first scaled image to the second scaled image maintains the ratio of the width to the height of the image as it fits in the display window before the second scaling, the automatic scaling of the output image to the size of the display window is thus equivalent to automatically inverse scaling the above-mentioned quadratic scaling, so that the portion of the second scaled image in the output image is changed back to the first scaled image, which is scaled with the original image maintaining its own aspect ratio, and its width and height are just the width and height that can maximize the display in the display window, therefore, the effect of displaying the output image in the display window is that the original image maintains the effect of maximum display of the real aspect ratio in the display window; and because the resolution of the output image received by the decoder is always the preset output resolution, the decoder is not restarted, thereby solving the problem that the video image can not be normally displayed when the resolution of the video image output by the signal source is changed.
It is understood that, in the process of processing the image, the first scaling and the second scaling in the present application may adopt a way of pre-calculating the result and then scaling to a position in an actual operation, and a specific example is described below.
The width and the width of the display window are respectively represented by W0 and H0, the width and the height of the preset output resolution are respectively represented by W1 and H1, and the width and the height of the original image are respectively represented by W2 and H2, in the first scaling, firstly, the blank condition of the display window is judged, W2/H2 is compared with W0/H0, if W2/H2< W0/H0, the left and right sides of the display window are left blank, at this time, the width of the first scaled image obtained according to the first scaling is W2H 0/H2, the height is H2, the width of the second scaled image obtained after the second scaling is (W2H 0/H2) (W1/W0), and the height is H1; obviously, in an actual operation, after the determination of the blank of the display window, the display window may be once calculated by a formula, for example, the final zoomed width may be set as W3, and the height may be set as H3, then the calculated result W3 is (W2 × H0/H2) (W1/W0), and the height H3 is H1, and according to the calculated result, the original image may be directly zoomed into the size corresponding to W3 and H3, and the two times of zooming may be changed into the once zoomed position, so as to reduce the consumption of CPU resources and reduce the time delay of the image.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The terms "first," "second," "third," "fourth," and the like in the description of the application and the above-described figures, if any, 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 application described herein are, for example, capable of operation in sequences other than those illustrated or otherwise 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.
It should be understood that in the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" for describing an association relationship of associated objects, indicating that there may be three relationships, e.g., "a and/or B" may indicate: only A, only B and both A and B are present, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of single item(s) or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", wherein a, b, c may be single or plural.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or 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, devices or units, and may be in an electrical, mechanical 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 application 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 integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (9)

1. A video image processing method based on a splicing wall is characterized by comprising the following steps:
decoding the video code stream to obtain an original image;
zooming the original image to a width and a height which correspond to the maximum display of the original image in a display window according to the first aspect ratio of the original image to obtain a first zoomed image;
zooming the first zoomed image to obtain a second zoomed image, wherein a second width ratio of the width of the second zoomed image to the width of a preset output resolution is equal to a first width ratio of the width of the first zoomed image to the width of the display window, and a second height ratio of the height of the second zoomed image to the height of the preset output resolution is equal to a first height ratio of the height of the first zoomed image to the height of the display window;
placing the second zoomed image in a space corresponding to the preset output resolution, and obtaining an output image according to the space, so that the output image is displayed in the display window, specifically comprising:
and storing the pixel data of the second zoomed image into a memory space distributed according to the width and the height of the preset output resolution, and obtaining an output image according to the memory space so as to be displayed in the display window.
2. The method according to claim 1, wherein the scaling the original image to a width and a height corresponding to the maximum display of the original image in a display window according to the first aspect ratio of the original image, and the obtaining the first scaled image specifically includes:
if the first aspect ratio of the original image is smaller than the second aspect ratio of the display window, zooming the original image according to the first aspect ratio until the height of the original image is equal to the height of the display window to obtain a first zoomed image;
otherwise, the original image is zoomed according to the first aspect ratio until the width of the original image is equal to the width of the display window, and a first zoomed image is obtained.
3. The method according to claim 1, wherein the scaling the first scaled image to obtain a second scaled image, a second width ratio of a width of the second scaled image to a width of a preset output resolution being equal to a first width ratio of the width of the first scaled image to a width of the display window, and a second height ratio of a height of the second scaled image to a height of the preset output resolution being equal to a first height ratio of the height of the first scaled image to the height of the display window specifically comprises:
adjusting the width of the first scaled image to be equal to the product of the first width ratio and the width of the preset output resolution;
and adjusting the height of the first zooming image to be equal to the product of the first height ratio and the height of the preset output resolution to obtain a second zooming image.
4. The method of claim 1, wherein the storing the pixel data of the second scaled image into the memory space allocated according to the width and height of the preset output resolution comprises:
storing the pixel data of the second zoomed image into a preset space of the memory space;
an initial abscissa of the preset space relative to the memory space corresponds to half of a difference between the width of the preset output resolution and the width of the second zoom image, and an initial ordinate corresponds to half of a difference between the height of the preset output resolution and the height of the second zoom image;
the preset space stores pixel data with a width of the second zoom image and a height of the second zoom image.
5. The method of claim 1, wherein scaling the original image to a width and a height within a display window corresponding to the original image in accordance with the first aspect ratio of the original image further comprises:
updating the width and height of the display window in response to a change in the width or height of the display window.
6. A video image processing apparatus based on a mosaic wall, comprising:
the original image acquisition module is used for decoding the video code stream to obtain an original image;
the first scaling module is used for scaling the original image to the width and the height which correspond to the maximum display of the original image in a display window according to the first aspect ratio of the original image to obtain a first scaled image;
a second scaling module, configured to scale the first scaled image to obtain a second scaled image, where a second width ratio of a width of the second scaled image to a width of a preset output resolution is equal to a first width ratio of the width of the first scaled image to a width of the display window, and a second height ratio of a height of the second scaled image to a height of the preset output resolution is equal to a first height ratio of the height of the first scaled image to the height of the display window;
the output image generation module is used for placing the second zooming image in a space corresponding to the preset output resolution, and obtaining an output image according to the space so as to be convenient for the output image to be displayed in the display window;
the output image generation module is specifically configured to store the pixel data of the second scaled image into a memory space allocated according to the width and height of the preset output resolution, and obtain an output image according to the memory space, so that the output image is displayed in the display window.
7. The apparatus of claim 6, further comprising:
and the window information updating module is used for responding to the change of the width or the height of the display window and updating the width and the height of the display window.
8. A video image processing system based on a mosaic wall, comprising:
a signal source, a video image processing apparatus based on a mosaic wall, a mosaic processor and a mosaic wall according to any one of claims 6 to 7;
the video image processing device based on the splicing wall processes the video image sent by the signal source to obtain an output image, the output image is sent to the splicing processor, and the splicing processor displays the output image on the splicing wall.
9. A video image processing apparatus based on a tiled wall, the apparatus comprising a processor and a memory:
the memory is used for storing program codes and transmitting the program codes to the processor;
the processor is configured to execute the method for processing video images based on a mosaic wall according to any one of claims 1-5 according to instructions in the program code.
CN201810797751.9A 2018-07-19 2018-07-19 Video image processing method, device and system based on splicing wall Active CN108881743B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810797751.9A CN108881743B (en) 2018-07-19 2018-07-19 Video image processing method, device and system based on splicing wall

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810797751.9A CN108881743B (en) 2018-07-19 2018-07-19 Video image processing method, device and system based on splicing wall

Publications (2)

Publication Number Publication Date
CN108881743A CN108881743A (en) 2018-11-23
CN108881743B true CN108881743B (en) 2020-10-09

Family

ID=64303379

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810797751.9A Active CN108881743B (en) 2018-07-19 2018-07-19 Video image processing method, device and system based on splicing wall

Country Status (1)

Country Link
CN (1) CN108881743B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110275687A (en) * 2019-06-05 2019-09-24 合肥市传秀科技有限公司 A kind of image display method and system for splicing large-size screen monitors
CN110969580B (en) * 2019-12-10 2024-02-20 北京猎豹移动科技有限公司 Image display method and device
CN110989958B (en) * 2019-12-13 2021-05-14 威创集团股份有限公司 Method and related device for opening polygonal window on splicing wall
WO2021128243A1 (en) * 2019-12-27 2021-07-01 威创集团股份有限公司 Target pattern lookup method and computer-readable storage medium
CN112558909B (en) * 2020-12-22 2023-09-15 深圳创维数字技术有限公司 Method and system for adjusting spliced wall window and readable storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100589173C (en) * 2008-05-26 2010-02-10 杭州华三通信技术有限公司 Multi-picture splicing method and device
CN102377960B (en) * 2010-08-24 2014-11-05 腾讯科技(深圳)有限公司 Video picture displaying method and device
CN101937325B (en) * 2010-08-26 2012-07-11 广东威创视讯科技股份有限公司 Control method of splicing wall and control system of splicing wall
CN104461295A (en) * 2014-12-03 2015-03-25 广东威创视讯科技股份有限公司 Method and system for regulating video display window of jointing wall
CN106814933B (en) * 2016-12-15 2019-08-13 广州视源电子科技股份有限公司 Window shade display methods and device

Also Published As

Publication number Publication date
CN108881743A (en) 2018-11-23

Similar Documents

Publication Publication Date Title
CN108881743B (en) Video image processing method, device and system based on splicing wall
US8462989B2 (en) Scaling an image based on a motion vector
US9661298B2 (en) Depth image enhancement for hardware generated depth images
US11829405B2 (en) Image display device and image display system
JP7359521B2 (en) Image processing method and device
JP5522174B2 (en) Video encoding device
US7646929B2 (en) Signal-transmitting system, data-transmitting apparatus and data-receiving apparatus
JP2006246153A (en) Screen transfer apparatus, screen transfer system, and method and program for transferring screen
WO2023160617A9 (en) Video frame interpolation processing method, video frame interpolation processing device, and readable storage medium
CN110928509B (en) Display control method, display control device, storage medium, and communication terminal
JP2019149785A (en) Video conversion device and program
CN112650460A (en) Media display method and media display device
CN108924624B (en) Information processing method and device
US20240098270A1 (en) Method, apparatus, and device for processing video data and computer storage medium
US9275468B2 (en) Fallback detection in motion estimation
GB2616188A (en) Method and apparatus for creating panoramic picture on basis of large screen, and intelligent terminal and medium
CN113992951A (en) Screen projection method, projector and terminal equipment
CN107256137B (en) Picture processing method and device
EP3242476A1 (en) Histogram segmentation based local adaptive filter for video encoding and decoding
CN112073801B (en) Image processing method, electronic equipment and connector
JPH07284095A (en) View point adaptive-type image transmitting method and image transmitting device
CN113076043B (en) Readable storage medium, image transmission system, display device, and image processing method
CN115299033B (en) Imaging device and imaging processing method
CN113055615B (en) Conference all-in-one machine, screen segmentation display method and storage device
CN111699672B (en) Video control device and video control method

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