CROSS-REFERENCE TO RELATED APPLICATION

This application claims priority to Chinese Patent Application No. 201810168190.6, filed Feb. 28, 2018, the contents of which are incorporated by reference in the entirety.

TECHNICAL FIELD

The present invention relates to display technology, more particularly, to a method of processing video data, an apparatus for processing video data, a display apparatus, and a computer-program product.

BACKGROUND

Various different video formats have been available. Typically, different video formats correspond to different resolutions. For example, the resolution for Full High Definition (FHD) video format is 1920*1080, while the resolution for High Definition (HD) video format is 1280*720. Typically, a display apparatus such as a mobile phone has its own display resolution. When a video is played in the display apparatus, the discrepancy between the resolution of the video format and the display resolution often results in compromised display quality.

SUMMARY

In one aspect, the present invention provides a method of processing video data, comprising obtaining a frame of video comprising M numbers of first pixel groups along a first direction, each of the M numbers of first pixel groups comprising N numbers of pixels along a second direction, M and N being positive integers; determining Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of first pixel sets comprising a plurality of adjacent pixels in a respective one of the M numbers of first pixel groups, Q being a positive integer; assigning Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of pixel values being assigned based on pixel values of all pixels in a respective one of the Q numbers of first pixel sets; generating M numbers of second pixel groups respectively for the M numbers of first pixel groups, each of the M numbers of second pixel groups comprising Q numbers of pixels, pixel values of the Q numbers of pixels respectively equal to the Q numbers of pixels values respectively for the Q numbers of first pixel sets for a respective one of the M numbers of first pixel groups; and obtaining a processed frame of video comprising the M numbers of second pixel groups along the first direction.

Optionally, Q>N, and Q is a non-integer multiple of N.

Optionally, the processed frame of video comprises Q number of third pixel groups along the second direction, each of the Q numbers of third pixel groups comprising M numbers of pixels along the first direction; the method further comprising determining P numbers of second pixel sets for each respective one of the Q numbers of third pixel groups, each of the P numbers of second pixel sets comprising a plurality of adjacent pixels in a respective one of the Q numbers of third pixel groups, P being a positive integer, P>M, and P is a non-integer multiple of M; assigning P numbers of pixels values respectively to the P numbers of second pixel sets for each respective one of the Q numbers of third pixel groups, each of the P numbers of pixel values being assigned based on pixel values of all pixels in a respective one of the P numbers of second pixel sets; generating Q numbers of fourth pixel groups respectively for the Q numbers of third pixel groups, each of the Q numbers of fourth pixel groups comprising P numbers of pixels, pixel values of the P numbers of pixels respectively equal to the P numbers of pixels values respectively for the P numbers of second pixel sets for a respective one of the Q numbers of third pixel groups; and obtaining the processed frame of video comprising the Q numbers of fourth pixel groups along the second direction.

Optionally, determining the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups comprises determining N numbers of first target pixel sets and (Q−N) numbers of second target pixel sets for each respective one of the M numbers of first pixel groups, Q>N; wherein each of the M numbers of second pixel groups comprises N numbers of first pixels and (Q−N) numbers of second pixels, any two adjacent second pixels of the (Q−N) numbers of second pixels being spaced apart by a same total number of first pixels of the N numbers of first pixels; the N numbers of first target pixel sets respectively correspond to the N numbers of first pixels in a respective one of the M numbers of second pixel groups; and the (Q−N) numbers second target pixel sets respectively correspond to the (Q−N) numbers of second pixels in the respective one of the M numbers of second pixel groups.

Optionally, an i-th first target pixel set of the N numbers of first target pixel sets corresponds to an i-th first pixel of the N numbers of first pixels in the respective one of the M numbers of second pixel groups, 1≤i≤N; and a first pixel in the i-th first target pixel set of the N numbers of first target pixel sets is an i-th pixel in a respective one of the M numbers of first pixel groups.

Optionally, a j-th second target pixel set of the (Q−N) numbers of second target pixel sets corresponds to a j-th second pixel of the (Q−N) numbers of second pixels in the respective one of the M numbers of second pixel groups, 1≤j≤(Q−N); and a first pixel in the j-th second target pixel set of the (Q−N) numbers of second et pixel sets is a z-th pixel in a respective one of the M numbers of first pixel groups; wherein

z=j×qq-n-v-j-1,
v is a constant.

Optionally, determining the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups comprises adding A numbers of newly added pixel into each respective one of the M numbers of first pixel groups, A≥1; and determining the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups having the at least one newly added pixel; wherein a pixel value of each of the at least one newly added pixel is equal to a pixel value of a pixel in a respective one of the M numbers of first pixel groups; and A=B−1, B is a total number of pixels in each of the N numbers of first target pixel sets.

Optionally, assigning the Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups comprises determining correlation coefficients respectively for pixels in each of the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups; and assigning the Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups based on the correlation coefficients and the pixel values of all pixels in the respective one of the Q numbers of first pixel sets; wherein each of the correlation coefficients represents a degree of correlation between a respective pixel in the respective one of the Q numbers of first pixel sets and a respective one of the Q numbers of pixels in a respective one of the M numbers of second pixel groups.

Optionally, determining the correlation coefficients respectively for the pixels in each of the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups comprises determining relative distances respectively between the respective one of the Q numbers of pixels in the respective one of the M numbers of second pixel groups and pixels in the respective one of the Q numbers of first pixel sets; and determining the correlation coefficients respectively for the pixels in each of the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups based on the relative distances.

In another aspect, the present invention provides an apparatus for processing video data, comprising a memory; and one or more processors; wherein the memory and the one or more processors are connected with each other, and the memory stores computer-executable instructions for controlling the one or more processors to obtain a frame of video comprising M numbers of first pixel groups along a first direction, each of the M numbers of first pixel groups comprising N numbers of pixels along a second direction, M and N being positive integers; determine Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of first pixel sets comprising a plurality of adjacent pixels in a respective one of the M numbers of first pixel groups, Q being a positive integer assign Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of pixel values being assigned based on pixel values of all pixels in a respective one of the Q numbers of first pixel sets; generate M numbers of second pixel groups respectively for the M numbers of first pixel groups, each of the M numbers of second pixel groups comprising Q numbers of pixels, pixel values of the Q numbers of pixels respectively equal to the Q numbers of pixels values respectively for the Q numbers of first pixel sets for a respective one of the M numbers of first pixel groups; and obtain a processed frame of video comprising the M numbers of second pixel groups along the first direction.

Optionally, Q>N, and Q is a non-integer multiple of N.

Optionally, the processed frame of video comprises Q number of third pixel groups along the second direction, each of the Q numbers of third pixel groups comprising M numbers of pixels along the first direction; the memory further stores computer-executable instructions for controlling the one or more processors to determine P numbers of second pixel sets for each respective one of the Q numbers of third pixel groups, each of the P numbers of second pixel sets comprising a plurality of adjacent pixels in a respective one of the Q numbers of third pixel groups, P being a positive integer, P>M, and P is a non-integer multiple of M; assign P numbers of pixels values respectively to the P numbers of second pixel sets for each respective one of the Q numbers of third pixel groups, each of the P numbers of pixel values being assigned based on pixel values of all pixels in a respective one of the P numbers of second pixel sets; generate Q numbers of fourth pixel groups respectively for the Q numbers of third pixel groups, each of the Q numbers of fourth pixel groups comprising P numbers of pixels, pixel values of the P numbers of pixels respectively equal to the P numbers of pixels values respectively for the P numbers of second pixel sets for a respective one of the Q numbers of third pixel groups; and obtain the processed frame of video comprising the Q numbers of fourth pixel groups along the second direction.

Optionally, the memory further stores computer-executable instructions for controlling the one or more processors to determine N numbers of first target pixel sets and (Q−N) numbers of second target pixel sets for each respective one of the M numbers of first pixel groups, thereby determining the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, Q>N; wherein each of the M numbers of second pixel groups comprises N numbers of first pixels and (Q−N) numbers of second pixels, any two adjacent second pixels of the (Q−N) numbers of second pixels being spaced apart by a same total number of first pixels of the N numbers of first pixels; the N numbers of first target pixel sets respectively correspond to the N numbers of first pixels in a respective one of the M numbers of second pixel groups; and the (Q−N) numbers second target pixel sets respectively correspond to the (Q−N) numbers of second pixels in the respective one of the M numbers of second pixel groups.

Optionally, an i-th first target pixel set of the N numbers of first target pixel sets corresponds to an i-th first pixel of the N numbers of first pixels in the respective one of the M numbers of second pixel groups, 1≤i≤N; and a first pixel in the i-th first target pixel set of the N numbers of first target pixel sets is an i-th pixel in a respective one of the M numbers of first pixel groups.

Optionally, a j-th second target pixel set of the (Q−N) numbers of second target pixel sets corresponds to a j-th second pixel of the (Q−N) numbers of second pixels in the respective one of the M numbers of second pixel groups, 1≤j≤(Q−N); and a first pixel in the j-th second target pixel set of the (Q−N) numbers of second target pixel sets is a z-th pixel in a respective one of the M numbers of first pixel groups; wherein

z=j×qq-n-v-j-1,
v is a constant.

Optionally, the memory further stores computer-executable instructions for controlling the one or more processors to add A numbers of newly added pixel into each respective one of the M numbers of first pixel groups, A≥1; and determine the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups having the at least one newly added pixel; wherein a pixel value of each of the at least one newly added pixel is equal to a pixel value of a pixel in a respective one of the M numbers of first pixel groups; and A=B−1, B is a total number of pixels in each of the N numbers of first target pixel sets.

Optionally, the memory further stores computer-executable instructions for controlling the one or more processors to determine correlation coefficients respectively for pixels in each of the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups; and assign the Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups based on the correlation coefficients and the pixel values of all pixels in the respective one of the Q numbers of first pixel sets; wherein each of the correlation coefficients represents a degree of correlation between a respective pixel in the respective one of the Q numbers of first pixel sets and a respective one of the Q numbers of pixels in a respective one of the M numbers of second pixel groups.

Optionally, the memory further stores computer-executable instructions for controlling the one or more processors to determine relative distances respectively between the respective one of the Q numbers of pixels in the respective one of the M numbers of second pixel groups and pixels in the respective one of the Q numbers of first pixel sets; and determine the correlation coefficients respectively for the pixels in each of the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups based on the relative distances.

In another aspect, the present invention provides a display apparatus comprising the apparatus for processing video data described herein.

In another aspect, the present invention provides a computer-program product comprising a non-transitory tangible computer-readable medium having computer-readable instructions thereon, the computer-readable instructions being executable by a processor to cause the processor to perform obtaining a frame of video comprising M numbers of first pixel groups along a first direction, each of the M numbers of first pixel groups comprising N numbers of pixels along a second direction, M and N being positive integers; determining Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of first pixel sets comprising a plurality of adjacent pixels in a respective one of the M numbers of first pixel groups, Q being a positive integer; assigning Q numbers of pixels values respectively to the Q numbers of first pixel sets for each respective one of the M numbers of first pixel groups, each of the Q numbers of pixel values being assigned based on pixel values of all pixels in a respective one of the Q numbers of first pixel sets; generating M numbers of second pixel groups respectively for the M numbers of first pixel groups, each of the M numbers of second pixel groups comprising Q numbers of pixels, pixel values of the Q numbers of pixels respectively equal to the Q numbers of pixels values respectively for the Q numbers of first pixel sets for a respective one of the M numbers of first pixel groups; and obtaining a processed frame of video comprising the M numbers of second pixel groups along the first direction.

