An anti-distortion method, device, electronic device and vehicle for images

By acquiring and processing the images of the A-pillar in real time, and using the elliptical coordinates and offset parameters for cropping and anti-distortion processing, the problem of unstable A-pillar image effect is solved, and the image clarity and driving safety are improved.

CN112488966BActive Publication Date: 2025-06-27合肥疆程技术有限公司
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202011539465.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-23
Publication Date
2025-06-27
Estimated Expiration
2040-12-23

AI Technical Summary

Technical Problem

In the prior art, the image effect presented by the A-pillar of the car is unstable, resulting in image distortion and affecting the driver's field of vision and safety.

Method used

By obtaining the original image collected by the camera and the driver's eye elliptical coordinates in real time, determining the offset parameters of each pixel point, and performing cropping and anti-distortion processing, generating the original image after the anti-distortion processing, and sending it to the display screen of the A-pillar for display.

Benefits of technology

It improves the presentation effect of A-pillar images, solves the problem of image distortion, ensures the driver's field of vision, and improves driving safety.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112488966B_ABST
    Figure CN112488966B_ABST
Patent Text Reader

Abstract

An embodiment of the present invention relates to the field of automotive electronics, and discloses an image undistortion method, apparatus, electronic device and vehicle. Among them, the image undistortion method is applied to a vehicle. The vehicle is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The image undistortion method determines the offset parameter of the pixel points in the original image by real-time acquiring the current eye ellipse coordinates of the driver and combining the position information of the display screen of the A-pillar, and performs undistortion processing by cropping the original image to obtain the original image after undistortion processing and perform image display. The embodiment of the present invention can solve the technical problem that the current image effect presented by the A-pillar is unstable, and improve the image presentation effect of the A-pillar.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of automotive electronics technology, and particularly to an anti-distortion method, device, electronic device and vehicle for images. Background Art

[0002] The A-pillar, whose English name is A-pillar, is the connecting pillar that connects the roof and the front cabin at the left and right front of the vehicle. It is between the engine compartment and the cockpit, above the left and right rearview mirrors. Since the A-pillar is between the engine compartment and the cockpit, above the left and right rearview mirrors, it will block a part of the driver's turning vision. Especially for a left turn, the blind spot of vision formed by the A-pillar blocking the driver's vision during driving is called the A-pillar blind spot.

[0003] Since too small a cross-sectional area of the A-pillar will lead to insufficient body strength, and too large a cross-sectional area will affect the driver's vision. To solve this problem, a camera is installed outside the A-pillar through augmented reality technology (AR), and a display screen is installed inside the A-pillar. By transmitting the camera image to the inside of the A-pillar, the transparency of the A-pillar part is finally achieved, and both the firmness of the traditional A-pillar is maintained, and the driver's line of sight can clearly penetrate it to see the road conditions.

[0004] To solve the problem of the blind spot of vision caused by the automotive A-pillar, the A-pillar needs to be made transparent. Since the hollowing method can ensure the transparency of the A-pillar, but the strength of the A-pillar will be greatly reduced, thus reducing safety. Therefore, the solution of installing a display screen on the A-pillar to make it transparent is more feasible. Almost all current display screens are plate-shaped flat screens similar to mobile phones and tablets. The problem with using such a screen on a transparent A-pillar is that it can meet the requirements at a specific angle. Once the viewing angle changes and the line of sight is no longer perpendicular to the screen, an angle will be generated between the screen and the line of sight, that is, looking at the screen from an inclined angle. At this time, the visible field of view of the screen will become smaller, thus affecting the transparency effect of the A-pillar, and at the same time, the image will also be deformed and misaligned due to the viewing angle. The columnar structure of the flexible screen can solve the above problems. Since the flexible screen is soft and deformable, it can be attached to the columnar structure to form a columnar structure. The size of the plane passing through the axis corresponding to the columnar structure at different angles will not change much. At the same time, when observing from the points on the cylindrical surface coaxial with the cylinder towards the cylinder axis, no matter what the rotation angle is, it can be considered that the distortion generated by the cylindrical surface is uniform. The display surface of this A-pillar will not generate more blind spots of vision when the viewing angle is changed.

[0005] Currently, the image presentation of the A-pillar will generate a certain distortion relative to the real scene, resulting in image distortion. How to perform anti-distortion on the video image presented by the A-pillar to make the image effect more stable is the problem to be solved by the present invention. Summary of the Invention

[0006] An embodiment of the present invention aims to provide a method for image distortion correction, a vehicle-mounted computer, and an automobile, which solve the technical problem of unstable image effects presented by the A-pillar at present and improve the image presentation effect of the A-pillar.

[0007] To solve the above technical problems, the embodiments of the present invention provide the following technical solutions:

[0008] In a first aspect, an embodiment of the present invention provides an inverse distortion method for an image, which is applied to an automobile. The automobile is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The method includes:

[0009] Obtain the original image collected by the camera in real time;

[0010] Obtain the current eye ellipse coordinates of the driver in real time, and determine the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the display screen;

[0011] Determine the cropping area in the original image, and map the original image to the cropping area to determine the cropped area image;

[0012] Perform inverse distortion processing on the cropped area image according to the offset parameter to determine the cropped area image after inverse distortion processing;

[0013] Enlarge the cropped area image after inverse distortion processing to the original image to generate the original image after inverse distortion processing;

[0014] Send the original image after inverse distortion processing to the display screen of the A-pillar so that the display screen displays the image.

[0015] In some embodiments, the determining the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the display screen includes:

[0016] Establish a spatial coordinate system and determine the eye ellipse coordinates as the origin of the spatial coordinates;

[0017] Determine the coordinate position information of each corner point of the display screen;

[0018] Determine the offset parameter of each pixel point according to the position information of the eye ellipse coordinates and the coordinate position information of each corner point, where the offset of the pixel point is the horizontal displacement pixel value.

[0019] In some embodiments, the determining the offset parameter of each pixel point according to the position information of the eye ellipse coordinates and the coordinate position information of each corner point includes:

[0020] Determine the included angle corresponding to the nearest point and the farthest point on the axis of the display screen;

[0021] Determine the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point of the axis;

[0022] Determine the offset parameter of each pixel point not on the axis according to the offset parameter of each pixel point on the axis.

[0023] In some embodiments, the display screen is a curved display screen. The determining the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point of the axis includes:

[0024] Assume that the origin of the spatial coordinates is point E, the upper corner point of the display screen is point U with the coordinate position U(x1, y1, z1), the lower corner point is point D with the coordinate position D(x2, y2, z2), the front corner point is point F with the coordinate position (x3, y3, z3), and the rear corner point is point B with the coordinate position (x4, y4, z4). The arc radius of the cylindrical surface formed by the curved display screen is r, the resolution is h*w, where h is the number of pixels corresponding to the length direction and w is the number of pixels corresponding to the width direction. The length and width of one pixel of the display screen are a and b respectively. Then the size of the display area of the curved display screen is ah*bw;

[0025] Then the included angle corresponding to the arc where the line segment DF or the line segment UB is located is 180*bw / πr. Assume that the midpoint of the DF line segment is The midpoint of the UB line segment is Assume that the midpoint on the arc DF is O and the midpoint on the arc UB is O'. Among them, the distance from point M to point O is equal to the distance from point M' to point O', that is, MO = M'O' = r(1 - 180*bw / 2πr), where the line segment MM' is the axis of the display screen;

[0026] Assume that the vector of the straight line passing through point M and point M' is (xm, ym, zm), where,

[0027] Among them, the distance d from point E to the straight line MM' is

[0028] Among them, the distance from point E to point M' is

[0029] Assume that the distance from point E to the straight line MM' is l, then

[0030] Assume that the included angle between the line segment EM' and the straight line MM' is θ, and the value range of θ is (0, 90), then

[0031] Among them, the included angle between the line segment EM and the straight line MM' is 90 - θ, and the displacement of the intersection point of the connection line from point E to point M on the surface in the length direction is r(1 - cos(180 * bw / 2πr)) * tan(90 - θ);

[0032] Then the offset parameter of each pixel point on the line segment OO' is determined as r(1 - cos(180 * bw / 2πr)) * tan(90 - θ) / a.

[0033] In some embodiments, determining the offset parameter of each pixel point off the axis according to the offset parameter of each pixel point on the axis includes:

[0034] Determining the offset parameter of each pixel point off the axis as:

[0035] r(1 - cos(180 * bw / 2πr)) * tan(90 - θ) / a * sin((180 / w) * n), where r is the arc radius of the cylindrical surface formed by the curved surface display screen, b is the width of one pixel of the display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between the line segment EM' and the straight line MM', and n is the number of pixels corresponding to a certain pixel point.

[0036] In some embodiments, before the step of obtaining the current eye ellipse coordinates of the driver in real time, the method further includes:

[0037] Performing pixel point acquisition on the original image to determine a plurality of acquisition points.

[0038] In some embodiments, the performing pixel point acquisition on the original image to determine acquisition points includes:

[0039] For each row and each column of pixel points of the original image, taking one pixel point as an acquisition point at every preset number of pixel points to determine a plurality of acquisition points.

[0040] In some embodiments, determining the cropping area in the original image, mapping the original image to the cropping area to determine the cropping area image includes:

[0041] Determining the cropping origin, cropping width, and cropping length of the cropping area to determine the cropping area in the original image;

[0042] Determining the mapping relationship between the cropping area and the original image according to the original width and original length of the original image and the cropping width and cropping length;

[0043] Traverse the mapped coordinates of each pixel point within the cropping region according to the mapping relationship.

[0044] In some embodiments, the method further includes:

[0045] Determine the offset parameter of each pixel point according to the mapped coordinates of each pixel point within the cropping region.

[0046] In some embodiments, the performing inverse distortion processing on the cropping region image according to the offset parameter to determine the cropping region image after inverse distortion processing includes:

[0047] Determine the moving displacement of the original image mapped to the cropping region and construct a deformation function;

[0048] Determine the horizontal displacement of each pixel point according to the offset parameter of each pixel point in combination with the deformation function;

[0049] Perform inverse distortion processing on the cropping region image according to the horizontal displacement to determine the cropping region image after inverse distortion processing.

[0050] In some embodiments, the performing inverse distortion processing on the cropping region image according to the horizontal displacement to determine the cropping region image after inverse distortion processing includes:

[0051] Determine the coordinate position information of the mapped coordinates of each pixel point in the cropping region image after inverse distortion processing;

[0052] Interpolate to determine the coordinate position information of other pixel points in the cropping region according to the coordinate position information of each mapped coordinate in the cropping region image after inverse distortion processing to determine the cropping region image after inverse distortion processing.

[0053] In a second aspect, an embodiment of the present invention provides an inverse distortion device for an image, which is applied to an automobile. The automobile is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The device includes:

[0054] An original image acquisition unit, configured to acquire the original image collected by the camera in real time;

[0055] An eye ellipse coordinate acquisition unit, configured to acquire the current eye ellipse coordinates of the driver in real time;

[0056] An offset parameter determination unit, configured to determine the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the display screen;

[0057] A cropping region determination unit, configured to determine the cropping region in the original image, map the original image to the cropping region to determine the cropping region image;

[0058] An anti-distortion processing unit, configured to perform anti-distortion processing on the cropped area image according to the offset parameter to determine the anti-distorted cropped area image;

[0059] An image magnification unit, configured to magnify the anti-distorted cropped area image to the original image to generate an anti-distorted original image;

[0060] An image display unit, configured to send the anti-distorted original image to the display screen of the A-pillar so that the display screen performs image display.

[0061] In some embodiments, determining the offset parameter of each pixel point of the original image according to the eye ellipse coordinates and the position information of the display screen includes:

[0062] Establish a spatial coordinate system and determine the eye ellipse coordinates as the origin of the spatial coordinates;

[0063] Determine the coordinate position information of each corner point of the display screen;

[0064] According to the eye ellipse coordinates and the coordinate position information of each corner point, determine the offset parameter of each pixel point, where the offset parameter of the pixel point includes the offset amount of the pixel point, and the offset amount of the pixel point is the horizontal displacement pixel value.

[0065] In some embodiments, before the step of obtaining the current eye ellipse coordinates of the driver in real time, the method further includes:

[0066] Perform pixel point acquisition on the original image to determine a plurality of acquisition points.

[0067] In some embodiments, performing pixel point acquisition on the original image to determine acquisition points includes:

[0068] For each row and each column of pixel points of the original image, take a pixel point as an acquisition point at every preset number of pixel points to determine a plurality of acquisition points.

[0069] In some embodiments, determining the cropped area in the original image, mapping the original image to the cropped area to determine the cropped area image includes:

[0070] Determine the cropping origin, cropping width, and cropping length of the cropped area to determine the cropped area in the original image;

[0071] According to the original width and original length of the original image and the cropping width and cropping length, determine the mapping relationship between the cropped area and the original image;

[0072] Traverse the mapped coordinates of each pixel point within the cropped area according to the mapping relationship.

[0073] In some embodiments, the method further includes:

[0074] Determine the offset parameter of each pixel point according to the mapped coordinates of each pixel point within the cropped area.

[0075] In some embodiments, the performing inverse distortion processing on the cropped area image according to the offset parameter to determine the cropped area image after inverse distortion processing includes:

[0076] Determine the moving displacement of the original image mapped to the cropped area and construct a deformation function;

[0077] Determine the horizontal displacement of each pixel point according to the offset parameter of each pixel point in combination with the deformation function;

[0078] Perform inverse distortion processing on the cropped area image according to the horizontal displacement to determine the cropped area image after inverse distortion processing.

[0079] In some embodiments, the performing inverse distortion processing on the cropped area image according to the horizontal displacement to determine the cropped area image after inverse distortion processing includes:

[0080] Determine the coordinate position information of the mapped coordinates of each pixel point in the cropped area image after inverse distortion processing;

[0081] Interpolate to determine the coordinate position information of other pixel points in the cropped area according to the coordinate position information of each mapped coordinate in the cropped area image after inverse distortion processing, so as to determine the cropped area image after inverse distortion processing.

[0082] In a third aspect, an embodiment of the present invention provides an electronic device, including:

[0083] At least one processor; and,

[0084] A memory communicatively connected to the at least one processor; wherein,

[0085] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the inverse distortion method of the image as described above.

[0086] In a fourth aspect, an embodiment of the present invention provides an automobile, including:

[0087] A camera for collecting an original image;

[0088] The electronic device as described above is used to receive the original image sent by the camera to generate the original image after anti-distortion processing;

[0089] The A-pillar is used to receive the original image after anti-distortion processing sent by the electronic device. The A-pillar is provided with a display screen for displaying the original image after anti-distortion processing.

[0090] In a fifth aspect, an embodiment of the present invention further provides a non-volatile computer-readable storage medium. The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable the electronic device to execute the anti-distortion method of the image as described above.

[0091] The beneficial effects of the embodiments of the present invention are as follows: Different from the prior art, an anti-distortion method of an image provided by the embodiments of the present invention is applied to an automobile. The automobile is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The method includes: obtaining the original image collected by the camera in real time; obtaining the current eye ellipse coordinates of the driver in real time, and determining the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the display screen; determining the cropping area in the original image, mapping the original image to the cropping area to determine the cropped area image; performing anti-distortion processing on the cropped area image according to the offset parameter to determine the cropped area image after anti-distortion processing; magnifying the cropped area image after anti-distortion processing to the original image to generate the original image after anti-distortion processing; sending the original image after anti-distortion processing to the display screen of the A-pillar so that the display screen displays the image. By obtaining the current eye ellipse coordinates of the driver in real time, combining with the position information of the display screen of the A-pillar, determining the offset parameter of the pixel points in the original image, and performing anti-distortion processing by cropping the original image to obtain the original image after anti-distortion processing and perform image display, the embodiments of the present invention can solve the technical problem that the image effect presented by the A-pillar is unstable at present and improve the image presentation effect of the A-pillar. Description of the Drawings

[0092] One or more embodiments are exemplarily illustrated by the pictures in the corresponding drawings. These exemplary illustrations do not limit the embodiments. Elements with the same reference numerals in the drawings represent similar elements, unless otherwise stated, and the drawings in the drawings do not constitute a proportional limitation.

[0093] Figure 1 It is a schematic diagram of the hardware architecture of an automobile provided by an embodiment of the present invention;

[0094] Figure 2 It is a schematic diagram of an original image provided by an embodiment of the present invention;

[0095] Figure 3 It is a schematic diagram of an original image with reverse bending provided by an embodiment of the present invention;

[0096] Figure 4 It is a schematic flowchart of an image undistortion method provided by an embodiment of the present invention;

[0097] Figure 5 is Figure 4 A refined flowchart of step S20 in

[0098] Figure 6 It is a schematic diagram of a curved display screen provided by an embodiment of the present invention;

[0099] Figure 7 It is a schematic diagram of another curved display screen provided by an embodiment of the present invention;

[0100] Figure 8a It is a schematic diagram of a transparent A-pillar provided by an embodiment of the present invention;

[0101] Figure 8b It is a schematic diagram of the display effect of a curved display screen provided by an embodiment of the present invention;

[0102] Figure 9 It is a schematic diagram of the display effect of an image provided by an embodiment of the present invention;

[0103] Figure 10 It is a schematic diagram of mapping an image to a cropping area provided by an embodiment of the present invention;

[0104] Figure 11 is Figure 4 A refined flowchart of step S30 in

[0105] Figure 12 is Figure 4 A refined flowchart of step S40 in

[0106] Figure 13 It is a schematic diagram of a sin image provided by an embodiment of the present invention;

[0107] Figure 14 It is a schematic diagram of an arctan image provided by an embodiment of the present invention;

[0108] Figure 15 is Figure 12 A refined flowchart of step S43 in

[0109] Figure 16a It is a schematic diagram before the original image is not squeezed provided by an embodiment of the present invention;

[0110] Figure 16bIt is a schematic diagram of an original image after being squeezed provided by an embodiment of the present invention;

[0111] Figure 17 It is a schematic diagram of another sin image provided by an embodiment of the present invention;

[0112] Figure 18 It is a schematic diagram of a cropped area image after inverse distortion processing provided by an embodiment of the present invention;

[0113] Figure 19 It is a schematic structural diagram of an inverse distortion device for an image provided by an embodiment of the present invention;

[0114] Figure 20 It is a schematic hardware structure diagram of an electronic device for each embodiment of the present invention. Detailed implementation manners

[0115] In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts fall within the protection scope of the present invention.

[0116] It should be noted that if there is no conflict, the various features in the embodiments of the present invention can be combined with each other, and all are within the protection scope of the present invention. In addition, although functional module division is performed in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order from the module division in the device or the flowchart. Furthermore, the terms "first", "second", "third", etc. adopted by the present invention do not limit the data and execution order, but are only used to distinguish the same items or similar items with basically the same functions and effects.

[0117] Before describing the present invention in detail, the nouns and terms involved in the embodiments of the present invention are described. The nouns and terms involved in the embodiments of the present invention are applicable to the following explanations.

[0118] (1) Eye ellipse coordinates refer to the position where the driver's eyeball is located, that is, the viewing point. Since people have different body sizes, different drivers sitting on the driver's seat in a normal driving posture will obviously have different eye positions. Using statistical viewpoints and methods to study the distribution law of the viewing points of driving G, it is found that the distribution graph of the viewing points of vehicle drivers is elliptical, so it is called the driver's eye ellipse.

[0119] (2) Driver Monitoring System (DMS). Through eye tracking, the driver monitoring system can provide real-time position coordinate data of the driver's eyeballs, that is, eye ellipse coordinates.

[0120] Currently, with the development of Augmented Reality (AR) technology, the A-pillar of the car has emerged. The purpose of the A-pillar is to enable the driver to better understand the driving environment outside the vehicle. However, the visual error of the displayed image of the existing A-pillar is often large, resulting in a certain difference between the driving environment seen by the driver at the A-pillar and the real environment, which is likely to affect the driver's judgment.

[0121] Since distortion increases rapidly with the increase of the field of view, although it does not affect the image clarity, the distortion of the optical system directly affects the geometric position accuracy of imaging. Due to the existence of distortion, a straight line in space becomes a curve in the image plane, resulting in image distortion. In an optical system with a relatively small field of view, the distortion is not significant, but for a large-field optical system, measures must be taken to eliminate the influence of distortion. The existence of distortion is not conducive to image recognition, analysis, and judgment. If the image distortion after the camera imaging is large, it will be a significant error after converting to the spatial distance, which is not allowed in high-precision three-dimensional stereometric measurement, visual inspection, and motion measurement. In order to improve the accuracy of quantitative analysis such as image detection and pattern matching, this type of distortion must be corrected, and the correction accuracy will directly affect the accuracy of quantitative analysis. Restoring a deformed image to its original appearance can greatly improve the image recognizability.

[0122] Based on this, the present invention proposes an image undistortion method to improve the image presentation effect of the A-pillar.

[0123] In an embodiment of the present invention, the image undistortion method is applied to an automobile, specifically, to an electronic device of the automobile. The execution subject of the image undistortion method is one or more processors of the electronic device of the automobile.

[0124] Please refer to Figure 1 , Figure 1 which is a schematic diagram of the hardware architecture of an automobile provided by an embodiment of the present invention;

[0125] As Figure 1 shown, the automobile 100 includes: a camera 10, an electronic device 20, and an A-pillar 30. Among them, the A-pillar 30 includes a display screen 31, and both the camera 10 and the A-pillar are communicatively connected to the electronic device 20.

[0126] Specifically, the camera 10 is disposed outside the vehicle 100 and communicatively connected to the electronic device 20, and is configured to collect original images outside the vehicle in real time and send the original images to the electronic device 20.

[0127] Specifically, the electronic device 20 is communicatively connected to the camera 10 and the A-pillar 30 respectively. For example, the electronic device 20 is communicatively connected to the camera 10 and the A-pillar 30 through cables or wirelessly, such as through 2G, 3G, 4G, 5G, local area network, Bluetooth and other means. It is configured to receive the original images collected by the camera 10, perform undistortion processing on the original images to obtain the undistorted original images, and send the undistorted original images to the display screen 31 of the A-pillar 30, so that the display screen 31 displays the undistorted original images. In the embodiments of the present invention, the electronic device 20 includes but is not limited to:

[0128] (1) Mobile communication devices: These devices are characterized by having mobile communication functions and mainly aim to provide voice and data communication. Such electronic devices include: smart phones (such as iPhone), multimedia phones, functional phones, and low-end phones, etc.

[0129] (2) Mobile personal computer devices: These devices belong to the category of personal computers, have computing and processing functions, and generally also have the characteristic of mobile Internet access. Such electronic devices include: PDA, MID, and UMPC devices, etc., such as iPad.

[0130] (3) Portable entertainment devices: These devices can display and play video content and generally also have the characteristic of mobile Internet access. Such devices include: video players, handheld game consoles, and smart toys and portable vehicle navigation devices.

[0131] (4) Other electronic devices with video playback functions and Internet access functions.

[0132] Specifically, a display screen 31 is installed inside the A-pillar 30. In the embodiments of the present invention, the display screen is a flexible display screen. By transmitting the original images obtained by the camera 10 to the flexible display screen inside the A-pillar, the transparency of the A-pillar part is realized.

[0133] Although the columnar transparent A-pillar maintains the firmness of the traditional A-pillar and enables the driver to clearly see through it to view the road conditions, since the display screen of the columnar display is in a curved state rather than a flat state, when displaying a planar graph in the columnar display, the planar graph that enters the field of view will be severely curved. That is to say, the straight line output to the screen will be seen as curved. To solve this problem, it is necessary to make a reverse curvature on the original image to ensure that the displayed result is a straight line.

[0134] Please refer to Figure 2 , Figure 2 which is a schematic diagram of an original image provided by an embodiment of the present invention;

[0135] As Figure 2 shown, the original image is a checkerboard image. Usually, the planar checkerboard is horizontal and vertical, and the straight lines of the pixel points on the original plane present a linear relationship.

[0136] Please refer to Figure 3 , Figure 3 which is a schematic diagram of an original image with reverse curvature provided by an embodiment of the present invention;

[0137] Since the display screen set on the A-pillar of the car is generally curved, after the display screen is curved, the distance from the pixel points on the screen to the human eye no longer conforms to a linear relationship. Therefore, the straight lines on the display screen are curved. Then, when the original image is input into the curved display screen, the planar graph that enters the field of view will be severely curved. That is to say, the straight line output to the display screen will be seen as curved. Therefore, to solve the problem of curvature, it is necessary to make a reverse curvature on the original image, that is, reverse curvature, to ensure that the displayed effect is a straight line. As Figure 3 shown, the image in it is the original image after reverse curvature.

[0138] In the embodiment of the present invention, the display screen set on the A-pillar is a columnar curved surface. The columnar curved surface here refers to the object on which the entire display screen is tiled, and can also be understood as the display screen is pasted on a columnar body. Here, it can also not be a columnar body, but can be a surface with one side being flat and the other side being arc-shaped or both sides being flat (in this case, it is a triangular body). If the surface is in other forms rather than a columnar body, then it is necessary to know the spatial position function of the surface. The cylindrical surface conforms to the sine and cosine functions, while the planar surface conforms to the linear function. By knowing the similarity function of the surface, the function of the pixel point positions on the surface can be obtained, and thus the spatial position can be calculated.

[0139] Next, taking the display screen of the A-pillar in the embodiment of the present invention as a curved surface as an example, an explanation will be given.

[0140] Please refer to Figure 4 , Figure 4It is a schematic flowchart of an image undistortion method provided by an embodiment of the present invention;

[0141] As Figure 4 shown, the image undistortion method is applied to an automobile. The automobile includes an electronic device for executing the image undistortion method in the present invention. The automobile is provided with an A-pillar and a camera. The A-pillar is provided with a display screen, and the display screen is arranged on the inner side of the A-pillar. The display screen is a flexible display screen. The A-pillar is a transparent A-pillar. The method includes:

[0142] Step S10: Real-time obtain the original image collected by the camera;

[0143] Specifically, the camera is an external camera of the vehicle, which is used to obtain the image of the environment corresponding to the position of the A-pillar, that is, to collect the original image in real time. The camera sends the original image collected in real time to the electronic device so that the electronic device can obtain the original image collected by the camera in real time.

[0144] Step S20: Real-time obtain the current eye ellipse coordinates of the driver, and determine the offset parameter of each pixel point of the original image according to the eye ellipse coordinates and the position information of the display screen;

[0145] In the embodiment of the present invention, before the step of real-time obtaining the current eye ellipse coordinates of the driver, the method further includes:

[0146] Performing pixel point acquisition on the original image to determine a plurality of acquisition points. Specifically, the performing pixel point acquisition on the original image to determine the acquisition points includes:

[0147] For each row and each column of pixel points of the original image, taking a pixel point as an acquisition point every preset number of pixel points to determine a plurality of acquisition points.

[0148] Specifically, since the undistortion effect processing performed in the present invention is used in conjunction with a Driver Monitoring System (DMS), it is necessary to detect the new eye position of each frame and draw a new graph, so the rate is a factor that needs to be considered. The method adopted here is to collect a point every 2^n power for calculation and movement, and then perform interpolation on the final result.

[0149] Specifically, for each row and each column of pixel points of the original image, taking a pixel point as an acquisition point every preset number of pixel points to determine a plurality of acquisition points. In the embodiment of the present invention, the preset number is 2^n power pixel points, where n is a positive integer.

[0150] In an embodiment of the present invention, to ensure that the original image is not lost, the method further includes: increasing the number of pixels in both the length and width directions of the original image by a preset number of pixels to meet the requirements of the acquisition points. For example, first increase both the length and width of the image by 2^n–1 pixels to obtain a matrix of (the number of pixels in the original width + 2^n–1) * (the number of pixels in the original height + 2^n–1), and the finally obtained number of acquisition points meets the requirements.

[0151] Specifically, the vehicle is provided with a Driver Monitoring System (DMS). Through eye tracking, the DMS can provide the position coordinate data of the driver's eyeballs in real time, that is, the eye ellipse coordinates. Through the DMS system, the current eye ellipse coordinates of the driver can be obtained in real time.

[0152] Please refer to Figure 5 , Figure 5 is Figure 4 a detailed flowchart of step S20 in

[0153] As Figure 5 shown, in step S20: according to the eye ellipse coordinates and the position information of the display screen, determine the offset parameters of each pixel point of the original image, including:

[0154] Step S21: Establish a space coordinate system and determine the eye ellipse coordinates as the origin of the space coordinates;

[0155] Specifically, determine the real-time obtained eye ellipse coordinates as the origin of the space coordinates and establish a space coordinate system, wherein the directions of the X-axis, Y-axis, and Z-axis of the space coordinate system are the same as those of the world coordinate system.

[0156] Step S22: Determine the coordinate position information of each corner point of the display screen;

[0157] Specifically, the display screen is a curved display screen, and the corner points refer to the positions where the four corners of the curved display screen are located. Please refer to Figure 6 , Figure 6 is a schematic diagram of a curved display screen provided by an embodiment of the present invention;

[0158] As Figure 6 shown, points U, F, B, and D are the corner points of the display screen. Among them, assuming the position where the driver's eyes are located, that is, the eye ellipse coordinates are the origin of the space coordinates, which is named E. The four corner points of the screen are respectively named the upper corner point (U), the lower corner point (D), the front corner point (F), and the rear corner point (B) for easy description. Among them, the four corner points of the display screen are all in the same plane.

[0159] Step S23: Determine the offset parameter of each pixel point according to the eye ellipse coordinates and the coordinate position information of each corner point, where the offset parameter of the pixel point includes the offset amount of the pixel point, and the offset amount of the pixel point is the horizontal displacement pixel value.

[0160] Specifically, assume the upper corner point U(x1, y1, z1), the lower corner point D(x2, y2, z2), the front corner point F(x3, y3, z3), the rear corner point B(x4, y4, z4), and the arc radius of the cylindrical surface formed by the display screen is r, the resolution of the display screen is h*w (both h and w are integers), and the side length of one pixel of the display screen is a (here it is assumed that the pixel cells are all squares. If the pixel unit is not a square, it is set as a, b, where b = Δa, and Δ is the proportional coefficient for converting b to a). Then the size of the display area is ah*bw.

[0161] Specifically, the determining the offset parameter of each pixel point according to the eye ellipse coordinates and the coordinate position information of each corner point includes:

[0162] Determine the included angle corresponding to the nearest point and the farthest point on the axis of the display screen;

[0163] Specifically, the line segment MM’ is the axis of the display screen, the nearest point on the axis is the M’ point, the farthest point on the axis is the M point. Assume the included angle corresponding to the farthest point on the axis is θ, that is, the included angle between the line segment EM and the straight line MM’ is θ, then the included angle corresponding to the nearest point on the axis is (90 - θ), that is, the included angle between the line segment EM’ and the straight line MM’ is (90 - θ).

[0164] Determine the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point on the axis;

[0165] Determine the offset parameter of each pixel point not on the axis according to the offset parameter of each pixel point on the axis.

[0166] Specifically, the determining the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point on the axis includes:

[0167] Assume that the origin of the spatial coordinates is point E, the upper corner point of the display screen is point U with the coordinate position U(x1, y1, z1), the lower corner point is point D with the coordinate position D(x2, y2, z2), the front corner point is point F with the coordinate position (x3, y3, z3), and the rear corner point is point B with the coordinate position (x4, y4, z4). The arc radius of the cylindrical surface formed by the curved display screen is r, and the resolution is h*w, where h is the number of pixels corresponding to the length direction and w is the number of pixels corresponding to the width direction. The length and width of one pixel of the display screen are a and b respectively. Then the size of the display area of the curved display screen is ah*bw;

[0168] Then the included angle corresponding to the arc where the line segment DF or the line segment UB is located is 180*bw / πr. Assume that the midpoint of the DF line segment is The midpoint of the UB line segment is Assume that the midpoint on the arc DF is O, and the midpoint on the arc UB is O'. Among them, the distance from point M to point O is equal to the distance from point M' to point O', that is, MO = M'O' = r(1 - 180*bw / 2πr), where the line segment MM' is the axis of the display screen;

[0169] Assume that the vector of the straight line passing through point M and point M' is (xm, ym, zm), where,

[0170] Among them, the distance d from point E to the straight line MM' is

[0171] Among them, the distance from point E to point M' is

[0172] Assume that the distance from point E to the straight line MM' is l, then

[0173] Assume that the included angle between the line segment EM' and the straight line MM' is θ, and the value range of θ is (0, 90), then

[0174] Among them, the included angle between the line segment EM and the straight line MM' is 90 - θ. Then the displacement of the intersection point of the connection line between point E and point M on the curved surface in the length direction is r(1 - cos(180*bw / 2πr))*tan(90 - θ);

[0175] Then the offset parameter of each pixel point on the line segment OO' is determined as r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a.

[0176] Among them, each pixel point on the line segment OO’ corresponds to an included angle, that is, the included angle θ between EM’ and the straight line MM’. Obviously, for the same screen, the number of pixels on the short side is constant, that is, the sine value corresponding to each row of pixels in the direction parallel to UF / DB is constant. Although the sine value is constant, θ is variable, that is to say, each row of pixels in the direction parallel to UF / DB is not a fixed value, but is determined by the included angle between E and the plane where DFUB is located (that is, 90 - θ). Therefore, by determining the offset corresponding to each pixel point on the line segment OO’ and combining with the sine value corresponding to each row of pixels in the direction parallel to UF / DB, the offset of each pixel point on the display screen can be determined.

[0177] Specifically, determining the offset parameter of each pixel point on the non-axis according to the offset parameter of each pixel point on the axis includes:

[0178] Determining the offset parameter of each pixel point on the non-axis as:

[0179] r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin((180 / w)*n), where r is the arc radius of the cylindrical surface formed by the curved display screen, b is the width of one pixel of the display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between the line segment EM’ and the straight line MM’, and n is the number of pixels corresponding to a certain pixel point.

[0180] It can be understood that since the distance between the axis and the non-axis shows a certain pattern, that is, the distance between the central row and the other rows shows a regular change, the offset parameters of the other rows can be determined by fitting. Among them, the fitting is a sine function, that is, according to the positional relationship between the pixel points on the non-axis and the pixel points on the axis, the offset parameter of each pixel point on the non-axis is determined, that is, determining the offset parameter of each pixel point on the non-axis as:

[0181] r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin((180 / w)*n), where r is the arc radius of the cylindrical surface formed by the curved display screen, b is the width of one pixel of the display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between the line segment EM’ and the straight line MM’, and n is the number of pixels corresponding to a certain pixel point.

[0182] Please refer to Figure 7 , Figure 7 which is a schematic diagram of another curved display screen provided by an embodiment of the present invention;

[0183] Assume that the long side is ah and the short side is bw. The long side does not bend, while the short side bends. The radius of the circle where the arc of the short side (bw) is located is r. Then the radian corresponding to the bent short side (that is, the included angle corresponding to the arc at this end on the circle where the arc of DF / UB is located) is 180*bw / πr.

[0184] Assume that the midpoint of the DF line segment is The midpoint of the UB line segment is Assume that the midpoint of the arc DF is O, and the midpoint of the UB arc is O’.

[0185] Among them, the distances from point M to point O and from point M’ to point O’ are equal, that is, MO = M’O’ = r(1 - 180*bw / 2πr).

[0186] Among them, the vector of the straight line passing through point M and point M’ can be expressed as Here, it is abbreviated as (xm, ym, zm).

[0187] Among them, the distance d from point E to the straight line MM’ is

[0188] Among them, the distance from point E to point M’ is

[0189] Among them, the distance from point E to the straight line MM’ is l, that is, draw a perpendicular line from E to the straight line MM’, and the intersection point is also the foot of the perpendicular L, then EL = l. According to the Pythagorean theorem of a right triangle, it can be obtained that:

[0190]

[0191] Among them, to calculate the included angle between the line connecting point E and point M’ and the straight line MM’, that is, the included angle between EM’ and the straight line MM’, it can be obtained through the arcsin function. Assume that the included angle between EM’ and the straight line MM’ is θ, then

[0192] Since the reference point moves along M - M’, that is to say, the maximum value of the included angle is at point M, and the minimum value is at point M’. Simulated by the sine function, it can be considered that the included angle between EM and the straight line MM’ is 90 - θ.

[0193] Among them, the displacement that occurs in the direction of the long side (with a distance of ah) at the intersection point of the line connecting point E and point M on the curved surface is r(1 - 180*bw / 2πr)*tan(90 - θ). Therefore, the displacement (mm) in the direction of the long side (with a distance of ah), and then converting this value into the number of pixels can obtain the specific result of the number of translation pixels as r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a.

[0194] It can be understood that since the maximum value of the included angle is at point M and the minimum value is at point M', r(1 - 180*bw / 2πr)*tan(90 - θ) / a is the farthest distance, and when fitted to a sine function, it is the highest bit 1. The results from the highest bit to UF and DB are symmetric, similar to the 0 value of the sine. From 1 to 0 conforms to the sine function. Therefore, the value from OO' to UF / DB can correspond to the sine value according to the number of pixels in its short side (bw). Specifically, determining the offset parameter of each pixel point on the non-axis according to the offset parameter of each pixel point on the axis includes:

[0195] Determining the offset parameter of each pixel point on the non-axis as:

[0196] r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin((180 / w)*n), where r is the arc radius of the cylindrical surface formed by the curved surface display screen, b is the width of one pixel of the display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between line segment EM' and line MM', n is the number of pixels corresponding to a certain pixel point. It can be understood that each pixel point corresponds to a number of pixels n, and the value range of n is (0, w). For example: Suppose there are w pixels in the width direction, that is, the bw direction. When sin90 at the highest point is exactly the nth pixel and n = m / 2 pixels, the conversion formula at this time is r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin90. By determining the number of pixels corresponding to each pixel point on the non-axis, the offset parameter of each pixel point on the non-axis is determined.

[0197] It can be understood that for the same display screen, the number of pixels on the short side is unchanged, that is, the sine value corresponding to each row of pixels in the direction parallel to UF / DB is unchanged. However, the included angle θ between EM' and line MM' is variable, that is, each row of pixels in the direction parallel to UF / DB is not a fixed value, but is determined by the included angle between point E and the plane where DFUB is located (that is, 90 - θ).

[0198] Step S30: Determine the cropping area in the original image, and map the original image to the cropping area to determine the cropped area image;

[0199] It can be understood that since the camera acquisition range is too large, for example: the size of the original image acquired by the camera is 1920*1080, so a certain part of the original image needs to be enlarged to the entire screen, and the anti-distortion algorithm is for the curved screen of the transparent A-pillar, so the anti-distortion algorithm only targets a certain part of the original image.

[0200] Please refer to Figure 8a and Figure 8b , Figure 8a which is a schematic diagram of a transparent A-pillar provided by an embodiment of the present invention, Figure 8b and

[0201] is Figure 8a a schematic diagram of the display effect of a curved display screen shown, Figure 8b as shown, the curved display screen at the transparent A-pillar shows that, as

[0202] shown, it can be seen that the grid wall presents an obvious distortion effect, including deformation, local magnification, and local extrusion, and the (0, 0) point of this image is located in the lower right. Figure 9 , Figure 9 which is a schematic diagram of the display effect of an image provided by an embodiment of the present invention;

[0203] If you want the picture to be displayed normally, you need to perform reverse distortion on the image, and the required effect is as Figure 9 shown, and the (0, 0) point is located in the upper left position.

[0204] Please refer to Figure 10 , Figure 10 which is a schematic diagram of mapping an image to a cropping area provided by an embodiment of the present invention;

[0205] Among them, as Figure 9 shown, the image needs to be first squeezed in the middle and then deformed to achieve the target effect. Also, since only a certain part in the middle needs to be cropped and enlarged to the entire screen, the anti-distortion processing performed on the entire screen needs to be mapped to this area so that when enlarged to the full screen, the anti-distortion processing can be performed on the screen, and the display effect is as Figure 10 shown.

[0206] Please refer to Figure 11 , Figure 11 which is Figure 4 a detailed flowchart of step S30 in

[0207] As Figure 11As shown in the figure, step S30: determining the cropping region in the original image, and mapping the original image to the cropping region to determine the cropped region image, includes:

[0208] Step S31: determining the cropping origin, cropping width, and cropping length of the cropping region to determine the cropping region in the original image;

[0209] Step S32: determining the mapping relationship between the cropping region and the original image according to the original width and original length of the original image and the cropping width and cropping length;

[0210] Specifically, according to the ratio of the image size of the original image to the image size of the cropping region, and combining the positional relationship between the original image and the cropping region, the mapping relationship between the cropping region and the original image is determined.

[0211] Step S33: traversing the mapped coordinates of each pixel point in the cropping region according to the mapping relationship.

[0212] Specifically, according to the mapping relationship, based on the coordinate position information of each pixel point in the cropping region, the mapped coordinates of each pixel point are determined.

[0213] In the embodiment of the present invention, the method further includes:

[0214] Determining the offset parameter of each pixel point according to the mapped coordinates of each pixel point in the cropping region.

[0215] It can be understood that the mapped coordinates correspond to the coordinates of the original image. By determining the offset parameter of the pixel point corresponding to the coordinate in the original image, the offset parameter of each mapped coordinate is determined, and thus the offset parameter of each pixel point is determined.

[0216] Step S40: performing an undistortion process on the cropped region image according to the offset parameter to determine the cropped region image after the undistortion process;

[0217] Specifically, please refer to Figure 12 , Figure 12 is Figure 4 the detailed flowchart of step S40 in

[0218] As Figure 12 shown, this step S40: performing an undistortion process on the cropped region image according to the offset parameter to determine the cropped region image after the undistortion process, includes:

[0219] Step S41: determining the movement displacement of the original image mapped to the cropping region and constructing a deformation function;

[0220] Specifically, when the original image is squeezed into the cropping area, the pixel points in the original image will have a certain displacement. Therefore, it is necessary to determine the displacement of the original image mapped to the cropping area.

[0221] Step S42: Determine the horizontal displacement of each pixel point according to the offset parameter of each pixel point and in combination with the deformation function.

[0222] Step S43: Perform an undistortion process on the cropping area image according to the horizontal displacement to determine the cropping area image after the undistortion process.

[0223] Please refer to Figure 15 , Figure 15 which Figure 12 is the detailed flowchart of step S43 in

[0224] As Figure 15 shown, this step S43: Perform an undistortion process on the cropping area image according to the horizontal displacement to determine the cropping area image after the undistortion process, including:

[0225] Step S431: Determine the coordinate position information of the mapped coordinate of each pixel point in the cropping area image after the undistortion process.

[0226] Step S432: Interpolate to determine the coordinate position information of other pixel points in the cropping area according to the coordinate position information of each mapped coordinate in the cropping area image after the undistortion process, so as to determine the cropping area image after the undistortion process.

[0227] Specifically, the following is an example to illustrate the specific process of undistortion:

[0228] (1) The size of the input image is ImgWidth * ImgHeight. Since it is necessary to collect the width and height of the image every 2^n power, we get horGridNum = ImgWidth / 2^n, verGridNum = ImgHeight / 2^n. To ensure that the original image is not lost, the length and width of the original image are first increased by 2^n - 1 pixel points, so as to obtain a matrix of (ImgWidth + 2^n - 1) * (ImgHeight + 2^n - 1), and the final number of collected points is horGridNum * verGridNum.

[0229] (2) The coordinates of the cropping origin obtained are (a1, a2), and the cropping range is cutWidth * cutHeight. This cropping area can be expressed as (a1, a2, cutWidth, cutHeight). Subtract (a1, a2) from the x and y coordinates of the coordinate points within the cropping area to make the upper left corner point of the image zero. Then, based on the ratio of the length and width of the original image ImgWidth, ImgHeight to the length and width of the cropped image cutWidth, cutHeight, the mapping relationship from the cropping area to the original image is obtained.

[0230] (3) Traverse the points horGridNum * verGridNum within this area, and the mapped coordinates of each point are:

[0231] remapX = ImgWidth / cutWidth * (x – a1);

[0232] remapY = ImgHeight / cutHeight * (y – a2);

[0233] That is, the mapped coordinates (remapX, remapY) of each point are obtained, and subsequent deformation calculations are performed through the said mapped coordinates.

[0234] (4) Obtain the offset parameter amplitude according to the DMS system;

[0235] (5) By calculating the displacement required to map the original image to the cropping area, construct a deformation function. Since the original image is moved by the y value to achieve the deformation effect, with the center position as the reference, from 0 to ImgHeight, the displacement of the y value (Center.y) from the center point of the original image is from negative to positive. Observing the image, it can be seen that if we want to have an enlarged effect on both sides, we need to collect pixels as many times as possible at this position in the original image. Similarly, the narrowing in the middle is because fewer pixels are collected, resulting in a shrinking effect. Therefore, the distance from 0 to ImgHeight to the y value of the center point can be represented by the sin function. Please refer to Figure 13 , Figure 13 which is a schematic diagram of a sin image provided by an embodiment of the present invention;

[0236] As Figure 13 shown, the distance from 0 to ImgHeight to the y value of the center point can be represented by the sin function, and its range is (-π / 2, π / 2):

[0237] It can be immediately seen that to make the distribution dense at both ends and sparse in the middle, the change function of x can adopt the arctan function. Please refer to Figure 14 , Figure 14It is a schematic diagram of an arctan image provided by an embodiment of the present invention;

[0238] As Figure 14 shown, the smaller or larger x is, the smaller the change in its y value:

[0239] In summary, the constructed deformation function is as follows:

[0240] theta = arctan(((remapY - Center.y) / ImgHeight));

[0241] srcY = Center.y + amgnitude * sin(theta);

[0242] where srcY is the y-axis coordinate of the pixel point after deformation, amplitude is the offset parameter, and theta is the included angle corresponding to the pixel point.

[0243] Please also refer to Figure 16a and Figure 16b , Figure 16a It is a schematic diagram of an original image before being squeezed provided by an embodiment of the present invention; Figure 16b It is a schematic diagram of an original image after being squeezed provided by an embodiment of the present invention;

[0244] As Figure 16a shown, before the original image is squeezed, the width and height of the pixel points are consistent, and as Figure 16b shown, after the original image is squeezed, the width and height of some pixel points are significantly inconsistent.

[0245] (6) Deform according to amplitude, and the image shows a sine or cosine function waveform in the y direction. Let the displacement in the x direction be delta = Asin(n2πT + φ) + b. Since the position to be taken is the part greater than or equal to 0 in the positive direction of the non-offset sine function;

[0246] Please refer to Figure 17 again, Figure 17 It is a schematic diagram of another sine image provided by an embodiment of the present invention;

[0247] As Figure 17 shown, it can be seen that φ, b = 0. Here, only half a period of the original image is taken. So the final formula is: delta = Asin(nπT). And according to dms, the deformation displacement amplitude is assigned to A as the amplitude value, that is, A = amplitude, T = 1, and the independent variable takes the ratio of the y value to ImgHeight.

[0248] delta = amplitude * sin((remapY / ImgHeight) * π), where delta is the horizontal displacement of the pixel point.

[0249] (7) After the acquired points mapped into the original image have undergone deformation displacement, the points within the region also correspondingly undergo displacement mapping. Then, an image interpolation algorithm is used to interpolate the coordinate position information of other pixel points in the cropped region.

[0250] Specifically, interpolate the coordinates of other pixel points in the cropped region. Specifically, through the image interpolation algorithm, interpolate the coordinates of other pixel points in the cropped region to determine the image of the cropped region after anti-distortion processing.

[0251] In the embodiments of the present invention, the image interpolation algorithm includes but is not limited to: nearest neighbor interpolation method, bilinear interpolation method, cubic convolution method. Preferably, the embodiments of the present invention perform interpolation through the bilinear interpolation method. Among them, the bilinear interpolation method is a commonly used interpolation algorithm in computer vision image processing. It takes into account both the requirements of interpolation accuracy and algorithm simplicity. Bilinear interpolation is a linear interpolation extension of an interpolation function with two variables. Its core idea is to perform linear interpolation in two directions respectively. Its principle is that the pixel value of the point to be interpolated is the linear interpolation in the horizontal and vertical directions of the pixel values of the 4 adjacent points in the original image, that is, determine the corresponding weights according to the distances between the point to be sampled and the surrounding 4 adjacent points, so as to calculate the pixel value of the point to be sampled. For example: the bilinear interpolation is: f(i + u, j + v) = (1 - u)(1 - v)f(i, j) + (1 - u)vf(i, j + 1) + u(1 - v)f(i + 1, j) + uvf(i + 1, j + 1).

[0252] Please refer to Figure 18 , Figure 18 which is a schematic diagram of an image of the cropped region after anti-distortion processing provided by the embodiments of the present invention.

[0253] As Figure 18 shown, the display effect of the image of the cropped region after anti-distortion processing.

[0254] Step S50: Enlarge the image of the cropped region after anti-distortion processing to the original image to generate the original image after anti-distortion processing;

[0255] Step S60: Send the original image after anti-distortion processing to the display screen of the A-pillar so that the display screen performs image display.

[0256] In an embodiment of the present invention, by providing an anti-distortion method for an image, which is applied to an automobile. The automobile is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The method includes: obtaining the original image collected by the camera in real time; obtaining the current eye ellipse coordinates of the driver in real time, and determining the offset parameter of each pixel point of the original image according to the eye ellipse coordinates and the position information of the display screen; determining the cropping area in the original image, mapping the original image to the cropping area to determine the cropped area image; performing anti-distortion processing on the cropped area image according to the offset parameter to determine the anti-distorted cropped area image; enlarging the anti-distorted cropped area image to the original image to generate the anti-distorted original image; and sending the anti-distorted original image to the display screen of the A-pillar so that the display screen displays the image. By obtaining the current eye ellipse coordinates of the driver in real time, combining with the position information of the display screen of the A-pillar, determining the offset parameter of the pixel points in the original image, and performing anti-distortion processing by cropping the original image, the anti-distorted original image is obtained and the image is displayed. The embodiment of the present invention can solve the technical problem that the image effect presented by the current A-pillar is unstable and improve the image presentation effect of the A-pillar.

[0257] Please refer to Figure 19 , Figure 19 which is a schematic structural diagram of an anti-distortion device for an image provided by an embodiment of the present invention. Among them, the anti-distortion device 190 for an image is applied to an automobile. The automobile is provided with an A-pillar and a camera, and the A-pillar is provided with a display screen. The device includes:

[0258] An original image acquisition unit 191, configured to obtain the original image collected by the camera in real time;

[0259] An eye ellipse coordinate acquisition unit 192, configured to obtain the current eye ellipse coordinates of the driver in real time;

[0260] An offset parameter determination unit 193, configured to determine the offset parameter of each pixel point of the original image according to the eye ellipse coordinates and the position information of the display screen;

[0261] A cropping area determination unit 194, configured to determine the cropping area in the original image, map the original image to the cropping area to determine the cropped area image;

[0262] An anti-distortion processing unit 195, configured to perform anti-distortion processing on the cropped area image according to the offset parameter to determine the anti-distorted cropped area image;

[0263] An image enlargement unit 196, configured to enlarge the anti-distorted cropped area image to the original image to generate the anti-distorted original image;

[0264] An image display unit 197 for sending the original image after anti - distortion processing to the display screen on the A - pillar so that the display screen performs image display.

[0265] In an embodiment of the present invention, the offset parameter determination unit 193 is specifically configured to:

[0266] Establish a space coordinate system and determine the eye - ellipse coordinates as the origin of the space coordinates;

[0267] Determine the coordinate position information of each corner point of the display screen;

[0268] Determine the offset parameter of each pixel point according to the eye - ellipse coordinates and the coordinate position information of each corner point, where the offset parameter of the pixel point includes the offset amount of the pixel point, and the offset amount of the pixel point is the horizontal displacement pixel value.

[0269] In an embodiment of the present invention, the determining the offset parameter of each pixel point according to the eye - ellipse coordinates and the coordinate position information of each corner point includes:

[0270] Determine the included angle corresponding to the nearest point and the farthest point on the axis of the display screen;

[0271] Determine the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point on the axis;

[0272] Determine the offset parameter of each pixel point not on the axis according to the offset parameter of each pixel point on the axis.

[0273] In an embodiment of the present invention, the display screen is a curved display screen, and the determining the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point on the axis includes:

[0274] Assume that the origin of the space coordinates is point E, the upper - corner point of the display screen is point U with coordinate position U(x1, y1, z1), the lower - corner point is point D with coordinate position D(x2, y2, z2), the front - corner point is point F with coordinate position (x3, y3, z3), and the rear - corner point is point B with coordinate position (x4, y4, z4). The arc radius of the cylindrical surface formed by the curved display screen is r, the resolution is h*w, where h is the number of pixels corresponding to the length direction, w is the number of pixels corresponding to the width direction, the length and width of one pixel of the display screen are a and b respectively. Then the size of the display area of the curved display screen is ah*bw;

[0275] Then the included angle corresponding to the arc where the line segment DF or the line segment UB is located is 180*bw / πr. Assume that the mid - point of the DF line segment is The midpoint of the UB line segment is Assume that the midpoint of arc DF is O, and the midpoint of arc UB is O'. Among them, the distances from point M to point O and from point M' to point O' are equal, that is, MO = M'O' = r(1 - 180*bw / 2πr), where the line segment MM' is the axis of the display screen;

[0276] Assume that the vector of the straight line passing through point M and point M' is (xm, ym, zm), where,

[0277] Among them, the distance d from point E to the straight line MM' is

[0278] Among them, the distance from point E to point M' is

[0279] Assume that the distance from point E to the straight line MM' is l, then

[0280] Assume that the included angle between the line segment EM' and the straight line MM' is θ, and the value range of θ is (0, 90), then

[0281] Among them, the included angle between the line segment EM and the straight line MM' is 90 - θ, then the displacement of the intersection point of the connection line between point E and point M on the curved surface in the length direction is r(1 - cos(180*bw / 2πr))*tan(90 - θ);

[0282] Then the offset parameter of each pixel point on the line segment OO' is determined as r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a.

[0283] In the embodiment of the present invention, the determining the offset parameter of each pixel point on the non-axis according to the offset parameter of each pixel point on the axis includes:

[0284] The offset parameter of each pixel point on the non-axis is determined as:

[0285] r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin((180 / w)*n), where r is the arc radius of the cylindrical surface formed by the curved surface display screen, b is the width of a pixel of the display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between the line segment EM' and the straight line MM', and n is the number of pixels corresponding to a certain pixel point.

[0286] In the embodiment of the present invention, before the step of obtaining the current eye ellipse coordinates of the driver in real time, the device further includes:

[0287] An acquisition point determination unit (not shown in the figure), configured to perform pixel point acquisition on the original image and determine a plurality of acquisition points.

[0288] In the embodiment of the present invention, the acquisition point determination unit is specifically configured to:

[0289] For each pixel point in each row and each column of the original image, take a pixel point as an acquisition point at every preset number of pixel points to determine a plurality of acquisition points.

[0290] In the embodiment of the present invention, determining the cropping area in the original image, mapping the original image to the cropping area to determine the cropped area image includes:

[0291] Determine the cropping origin, cropping width, and cropping length of the cropping area to determine the cropping area in the original image;

[0292] According to the original width and original length of the original image and the cropping width and cropping length, determine the mapping relationship between the cropping area and the original image;

[0293] According to the mapping relationship, traverse the mapping coordinates of each pixel point in the cropping area.

[0294] In the embodiment of the present invention, the device further includes:

[0295] A cropping area offset parameter unit (not shown in the figure), configured to determine the offset parameter of each pixel point according to the mapping coordinates of each pixel point in the cropping area.

[0296] In the embodiment of the present invention, according to the offset parameter, performing inverse distortion processing on the cropped area image to determine the inverse distortion processed cropped area image includes:

[0297] Determine the moving displacement of the original image mapped to the cropping area and construct a deformation function;

[0298] According to the offset parameter of each pixel point, combined with the deformation function, determine the horizontal displacement of each pixel point;

[0299] According to the horizontal displacement, perform inverse distortion processing on the cropped area image to determine the inverse distortion processed cropped area image.

[0300] In the embodiment of the present invention, according to the horizontal displacement, performing inverse distortion processing on the cropped area image to determine the inverse distortion processed cropped area image includes:

[0301] Determine the coordinate position information of the mapped coordinates of each pixel point in the cropped area image after anti-distortion processing according to the horizontal displacement;

[0302] Interpolate to determine the coordinate position information of other pixel points in the cropped area according to the coordinate position information of each mapped coordinate in the cropped area image after anti-distortion processing, so as to determine the cropped area image after anti-distortion processing.

[0303] In an embodiment of the present invention, a schematic structural diagram of an anti-distortion device for an image is provided; wherein, the anti-distortion device for the image is applied to an automobile, the automobile is provided with an A-pillar and a camera, the A-pillar is provided with a display screen, and the device includes: an original image acquisition unit for real-time acquiring the original image collected by the camera; an eye ellipse coordinate acquisition unit for real-time acquiring the current eye ellipse coordinates of the driver; an offset parameter determination unit for determining an offset parameter according to the eye ellipse coordinates and the position information of the display screen; a cropped area determination unit for determining the cropped area in the original image, mapping the original image to the cropped area to determine a cropped area image; an anti-distortion processing unit for performing anti-distortion processing on the cropped area image according to the offset parameter to determine the cropped area image after anti-distortion processing; an image magnification unit for magnifying the cropped area image after anti-distortion processing to the original image to generate the original image after anti-distortion processing; and an image display unit for sending the original image after anti-distortion processing to the display screen of the A-pillar so that the display screen performs image display. By real-time acquiring the current eye ellipse coordinates of the driver, combining the position information of the display screen of the A-pillar, determining the offset parameter of the pixel points in the original image, and performing anti-distortion processing by cropping the original image, so as to obtain the original image after anti-distortion processing and perform image display, the embodiment of the present invention can solve the technical problem that the image effect presented by the A-pillar is unstable at present and improve the image presentation effect of the A-pillar.

[0304] Please refer to Figure 20 , Figure 20 which is a schematic hardware structure diagram of an electronic device for each embodiment of the present invention;

[0305] As Figure 20 shown, the electronic device 200 includes but is not limited to: a radio frequency unit 201, a network module 202, an audio output unit 203, an input unit 204, a sensor 205, a display unit 206, a user input unit 207, an interface unit 208, a memory 209, a processor 2010, and a power supply 2011 and other components, and the electronic device 200 further includes a camera. Those skilled in the art can understand, Figure 20The structure of the electronic device shown does not limit the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements. In the embodiments of the present invention, the electronic device includes, but is not limited to, a television, a mobile phone, a tablet computer, a laptop computer, a handheld computer, a vehicle-mounted terminal, a wearable device, a pedometer, etc.

[0306] The processor 2010 is configured to: obtain the original image captured by the camera in real time; obtain the current eye ellipse coordinates of the driver in real time, and determine the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the display screen; determine the cropping area in the original image, map the original image to the cropping area to determine the cropped area image; perform an undistortion process on the cropped area image according to the offset parameter to determine the undistorted cropped area image; enlarge the undistorted cropped area image to the original image to generate the undistorted original image; and send the undistorted original image to the display screen of the A-pillar so that the display screen performs image display.

[0307] In the embodiments of the present invention, by obtaining the current eye ellipse coordinates of the driver in real time, combining the position information of the display screen of the A-pillar, determining the offset parameter of the pixel points in the original image, and performing an undistortion process by cropping the original image, the undistorted original image is obtained and image display is performed. The embodiments of the present invention can solve the technical problem of unstable image effects presented by the A-pillar at present and improve the image presentation effect of the A-pillar.

[0308] It should be understood that in the embodiments of the present invention, the radio frequency unit 201 can be used for receiving and sending signals during information reception and transmission or a call. Specifically, after receiving the downlink data from the base station, it is given to the processor 2010 for processing; in addition, the uplink data is sent to the base station. Generally, the radio frequency unit 201 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low-noise amplifier, a duplexer, etc. In addition, the radio frequency unit 201 can also communicate with the network and other devices through a wireless communication system.

[0309] The electronic device 200 provides users with wireless broadband Internet access through the network module 202, such as helping users send and receive emails, browse web pages, and access streaming media, etc.

[0310] The audio output unit 203 can convert the audio data received by the radio frequency unit 201 or the network module 202 or stored in the memory 209 into an audio signal and output it as sound. Moreover, the audio output unit 203 can also provide audio output related to specific functions performed by the electronic device 200 (e.g., call signal reception sound, message reception sound, etc.). The audio output unit 203 includes a speaker, a buzzer, a receiver, etc.

[0311] The input unit 204 is used to receive audio or video signals. The input unit 204 may include a Graphics Processing Unit (GPU) 2041 and a microphone 2042. The graphics processor 2041 processes the target image of a still picture or video obtained by an image capturing device (such as a camera) in a video capture mode or an image capture mode. The processed image frame can be displayed on the display unit 206. The processed image frame can be stored in the memory 209 (or other storage media) or transmitted via the radio frequency unit 201 or the network module 202. The microphone 2042 can receive sound and can process such sound into audio data. The processed audio data can be output in a format that can be transmitted to a mobile communication base station via the radio frequency unit 201 in the case of a phone call mode.

[0312] The electronic device 200 further includes at least one sensor 205, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor. Among them, the ambient light sensor can adjust the brightness of the display panel 2061 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 2061 and / or the backlight when the electronic device 200 is moved close to the ear. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary, and can be used to identify the posture of the electronic device (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as a pedometer, tapping), etc.; the sensor 205 can also include a fingerprint sensor, a pressure sensor, an iris sensor, a molecular sensor, a gyroscope, a barometer, a hygrometer, a thermometer, an infrared sensor, etc., which will not be elaborated here.

[0313] The display unit 206 is used to display the information input by the user or the information provided to the user. The display unit 206 may include a display panel 2061, and the display panel 2061 can be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), etc.

[0314] The user input unit 207 can be used to receive input numerical or character information and generate key signal inputs related to user settings and function control of the electronic device. Specifically, the user input unit 207 includes a touch panel 2071 and other input devices 2072. The touch panel 2071, also known as a touch screen, can collect touch operations of the user thereon or nearby (such as operations of the user using any suitable object or accessory such as a finger or a stylus on or near the touch panel 2071). The touch panel 2071 can include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the touch orientation of the user and detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the processor 2010, and receives and executes the command sent by the processor 2010. In addition, the touch panel 2071 can be implemented in multiple types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to the touch panel 2071, the user input unit 207 can also include other input devices 2072. Specifically, the other input devices 2072 can include but are not limited to a physical keyboard, function keys (such as volume control keys, power on / off keys, etc.), a trackball, a mouse, a joystick, which will not be elaborated here.

[0315] Furthermore, the touch panel 2071 can cover the display panel 2061. After the touch panel 2071 detects a touch operation thereon or nearby, it transmits the operation to the processor 2010 to determine the type of the touch event. Subsequently, the processor 2010 provides a corresponding visual output on the display panel 2061 according to the type of the touch event. Although in Figure 20 the touch panel 2071 and the display panel 2061 are implemented as two independent components to realize the input and output functions of the electronic device, in some embodiments, the touch panel 2071 and the display panel 2061 can be integrated to realize the input and output functions of the electronic device, and the specific implementation here is not limited.

[0316] The interface unit 208 is an interface for connecting an external device to the electronic device 200. For example, the external device can include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headset port, and so on. The interface unit 208 can be used to receive inputs from an external device (such as data information, power, etc.) and transmit the received inputs to one or more components within the electronic device 200 or can be used to transmit data between the electronic device 200 and the external device.

[0317] The memory 209 can be used to store software programs and various data. The memory 209 mainly includes a program storage area and a data storage area. Among them, the program storage area can store application programs 2091 required for at least one function (such as a sound playback function, an image playback function, etc.) and an operating system 2092, etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, phone book, etc.). In addition, the memory 209 may include high-speed random access memory and may also include non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0318] The processor 2010 is the control center of the electronic device, connecting various parts of the entire electronic device through various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 209, and calling data stored in the memory 209, it executes various functions of the electronic device and processes data, thereby monitoring the electronic device as a whole. The processor 2010 may include one or more processing units; preferably, the processor 2010 may integrate an application processor and a modem processor. Among them, the application processor mainly processes the operating system, user interface, and application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor may not be integrated into the processor 2010 either.

[0319] The electronic device 200 may also include a power supply 2011 (such as a battery) for powering each component. Preferably, the power supply 2011 can be logically connected to the processor 2010 through a power management system, so as to realize functions such as management of charging, discharging, and power consumption management through the power management system.

[0320] In addition, the electronic device 200 includes some functional modules not shown here, which will not be elaborated here.

[0321] Preferably, the embodiment of the present invention also provides an electronic device, including a processor 2010, a memory 209, and a computer program stored on the memory 209 and executable on the processor 2010. When the computer program is executed by the processor 2010, it implements each process of the above-mentioned embodiment of the image undistortion method and can achieve the same technical effects. To avoid repetition, it will not be elaborated here.

[0322] An embodiment of the present invention also provides a computer-readable storage medium. A computer program is stored on the computer-readable storage medium. When the computer program is executed by one or more processors, it implements each process of the above-described embodiment of the method for image undistortion and can achieve the same technical effect. To avoid repetition, it will not be elaborated here. Among them, the computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disc, etc.

[0323] It should be noted that in this article, the term "including", "comprising", or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article, or device including a series of elements not only includes those elements but also includes other elements not explicitly listed, or further includes elements inherent to such a process, method, article, or device. Without more limitations, an element defined by the statement "including one..." does not exclude the existence of another identical element in the process, method, article, or device including that element.

[0324] The above-described device or equipment embodiments are merely illustrative. The unit modules described as separate components may or may not be physically separated, and the components shown as module units may or may not be physical units, that is, they may be located in one place or distributed to multiple network module units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0325] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-described embodiment methods can be implemented by means of software plus a necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases, the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. The computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disc) and includes several instructions for causing a terminal (which can be a mobile terminal, a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments of the present invention.

[0326] Finally, it should be noted that: The embodiments described above in conjunction with the accompanying drawings are only used to illustrate the technical solutions of the present invention. The present invention is not limited to the above specific implementation manners. The above specific implementation manners are merely illustrative and not restrictive; under the concept of the present invention, the technical features in the above embodiments or different embodiments can also be combined, and the steps can be implemented in any order, and there are many other variations in different aspects of the present invention as described above. For the sake of brevity, they are not provided in detail; Although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. An inverse distortion method for images, applied to an automobile, characterized in that, The vehicle is provided with an A-pillar and a camera, and the A-pillar is provided with a curved display screen. The method includes: Obtaining the original image collected by the camera in real time; Obtaining the current eye ellipse coordinates of the driver in real time, and determining the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the curved display screen and the arc radius of the cylindrical surface formed by the curved display screen; Determining the cropping area in the original image, and mapping the original image to the cropping area to determine the cropped area image; Performing an undistortion process on the cropped area image according to the offset parameter to determine the undistorted cropped area image; Enlarging the undistorted cropped area image to the original image to generate the undistorted original image; Sending the undistorted original image to the curved display screen of the A-pillar so that the curved display screen performs image display; The performing an undistortion process on the cropped area image according to the offset parameter to determine the undistorted cropped area image includes: Determining the moving displacement of the original image mapped to the cropping area and constructing a deformation function; Determining the horizontal displacement of each pixel point according to the offset parameter of each pixel point and in combination with the deformation function; Performing an undistortion process on the cropped area image according to the horizontal displacement to determine the undistorted cropped area image.

2. The method according to claim 1, characterized in that, The determining the offset parameter of each pixel point of the original image according to the position information of the eye ellipse coordinates and the curved display screen and the arc radius of the cylindrical surface formed by the curved display screen includes: Establishing a space coordinate system and determining the eye ellipse coordinates as the origin of the space coordinates; Determining the coordinate position information of each corner point of the curved display screen; Determining the offset parameter of each pixel point according to the position information of the eye ellipse coordinates and each corner point and the arc radius of the cylindrical surface formed by the curved display screen, wherein the offset parameter of the pixel point includes the offset amount of the pixel point, and the offset amount of the pixel point is the horizontal displacement pixel value.

3. The method according to claim 2, wherein The determining the offset parameter of each pixel point according to the position information of the eye ellipse coordinates and each corner point and the arc radius of the cylindrical surface formed by the curved display screen includes: Determining the included angle corresponding to the nearest point and the farthest point of the axis of the curved display screen; Determining the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point of the axis and the arc radius of the cylindrical surface formed by the curved display screen; Determining the offset parameter of each pixel point not on the axis according to the offset parameter of each pixel point on the axis.

4. The method according to claim 3, characterized in that, The determining the offset parameter of each pixel point on the axis according to the included angle corresponding to the nearest point and the farthest point of the axis and the arc radius of the cylindrical surface formed by the curved display screen includes: Assume that the origin of the spatial coordinates is point E, the upper corner point of the curved surface display screen is point U with coordinate position U(x1, y1, z1), the lower corner point is point D with coordinate position D(x2, y2, z2), the front corner point is point F with coordinate position (x3, y3, z3), and the rear corner point is point B with coordinate position (x4, y4, z4). The arc radius of the cylindrical surface formed by the curved surface display screen is r, and the resolution is h*w, where h is the number of pixels corresponding to the length direction and w is the number of pixels corresponding to the width direction. The length and width of one pixel of the display screen are a and b respectively. Then the size of the display area of the curved surface display screen is ah*bw; Then the included angle corresponding to the arc where the line segment DF or the line segment UB is located is 180 * bw / πr. Assume that the midpoint of the line segment DF is The midpoint of the line segment UB is Assume that the midpoint on the arc DF is O, and the midpoint on the arc UB is O'. Among them, the distances from point M to point O and from point M' to point O' are equal, that is, MO = M'O' = r(1 - 180*bw / 2πr), where the line segment MM' is the axis of the display screen; Suppose the vector of the line passing through points M and M’ is (xm, ym, zm), where, Among them, the distance d from point E to the straight line MM’ is Among them, the distance from point E to point M' is Assume that the distance from point E to the straight line MM’ is l, then Assume that the included angle between the line segment EM’ and the straight line MM’ is θ, and the value range of θ is (0, 90), then Among them, the included angle between the line segment EM and the straight line MM’ is 90 - θ. Then the displacement of the intersection point of the connection line from point E to point M on the curved surface in the length direction is r(1 - cos(180*bw / 2πr))*tan(90 - θ); Then the offset parameter of each pixel point on the line segment OO’ is determined as r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a.

5. The method according to claim 4, characterized in that Determining the offset parameter of each pixel point on the non-axis according to the offset parameter of each pixel point on the axis includes: Determining the offset parameter of each pixel point on the non-axis as: r(1 - cos(180*bw / 2πr))*tan(90 - θ) / a*sin((180 / w)*n), where r is the arc radius of the cylindrical surface formed by the curved surface display screen, b is the width of one pixel of the curved surface display screen, w is the number of pixels corresponding to the width direction, θ is the included angle between the line segment EM’ and the straight line MM’, and n is the number of pixels corresponding to a certain pixel point.

6. The method according to claim 1, characterized in that Before the step of obtaining the current eye ellipse coordinates of the driver in real time, the method further includes: Performing pixel point acquisition on the original image to determine a plurality of acquisition points.

7. The method according to claim 6, wherein The performing pixel point acquisition on the original image to determine acquisition points includes: For each row and each column of pixel points of the original image, taking one pixel point as an acquisition point at every preset number of pixel points to determine a plurality of acquisition points.

8. The method according to claim 1, characterized in that Determining the cropping area in the original image and mapping the original image to the cropping area to determine the cropped area image includes: Determining the cropping origin, cropping width, and cropping length of the cropping area to determine the cropping area in the original image; According to the original width and original length of the original image and the cropping width and cropping length, determining the mapping relationship between the cropping area and the original image; According to the mapping relationship, traversing the mapping coordinates of each pixel point in the cropping area.

9. The method according to claim 8, wherein The method further includes: According to the mapping coordinates of each pixel point in the cropping area, determining the offset parameter of each pixel point.

10. The method according to claim 1, characterized in that, Performing inverse distortion processing on the cropped area image according to the horizontal displacement to determine the cropped area image after inverse distortion processing includes: Determine the coordinate position information of the mapped coordinates of each pixel point in the cropped area image after undistortion processing according to the horizontal displacement; Interpolate to determine the coordinate position information of other pixel points in the cropped area according to the coordinate position information of each mapped coordinate in the cropped area image after undistortion processing, so as to determine the cropped area image after undistortion processing.

11. An anti-distortion device for an image, applied to an automobile, characterized in that, The vehicle is provided with an A-pillar and a camera, and the A-pillar is provided with a curved display screen. The device includes: An original image acquisition unit, configured to acquire the original image collected by the camera in real time; An eye ellipse coordinate acquisition unit, configured to acquire the current eye ellipse coordinates of the driver in real time; An offset parameter determination unit, configured to determine the offset parameter of each pixel point of the original image according to the eye ellipse coordinates, the position information of the curved display screen, and the arc radius of the cylindrical surface formed by the curved display screen; A cropped area determination unit, configured to determine the cropped area in the original image, map the original image to the cropped area, so as to determine the cropped area image; An undistortion processing unit, configured to perform undistortion processing on the cropped area image according to the offset parameter to determine the cropped area image after undistortion processing; An image magnification unit, configured to magnify the cropped area image after undistortion processing to the original image to generate the original image after undistortion processing; An image display unit, configured to send the original image after undistortion processing to the curved display screen of the A-pillar, so that the curved display screen performs image display; Wherein, the undistortion processing unit is specifically configured to: Determine the moving displacement of the original image mapped to the cropped area and construct a deformation function; Determine the horizontal displacement of each pixel point according to the offset parameter of each pixel point in combination with the deformation function; Perform undistortion processing on the cropped area image according to the horizontal displacement to determine the cropped area image after undistortion processing.

12. An electronic device, characterized in that, Includes: At least one processor; And, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the undistortion method of the image according to any one of claims 1-10.

13. A vehicle, characterized in that, Includes: A camera, configured to collect an original image; The electronic device according to claim 12, configured to receive the original image sent by the camera to generate the original image after undistortion processing; A pillar, which is used to receive the original image after anti-distortion processing sent by an electronic device, where The A-pillar is provided with a curved display screen, configured to display the original image after undistortion processing.

Citation Information

Patent Citations

  • Image correction method and device, electronic equipment and readable storage medium

    CN110415196A

  • Image distortion correction method, vehicle machine and automobile

    CN110728638A