Image processing method, control method of vehicle-mounted lighting device and electronic equipment
By decomposing the total matrix of the projection transformation into multiple submatrices and processing the image in step-by-step transformation, the problem of image mutation and jagging in perspective transformation is solved, especially in dynamic scenes, it is suitable for systems with limited resources and meets real-time requirements.
Patent Information
- Application Number
- CN202510377883.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-26
- Publication Date
- 2025-08-08
AI Technical Summary
In the prior art, images are prone to mutation and serration effects after one-time perspective transformation, especially in dynamic scenarios. In addition, existing methods require high computing resources when dealing with complex edges and dynamic changes, and cannot meet the real-time requirements.
The total projection transformation matrix is decomposed into multiple projection transformation submatrices. By gradually transforming the initial transformation image, multiple projection transformation submatrices are used to gradually adjust the image to avoid mutations and jagged phenomena caused by one-time perspective transformation, especially in dynamic scenes.
It realizes effective suppression of jagging in dynamic and rapidly changing scenarios, reduces the demand for computing resources, is suitable for embedded systems with resource-constrained resources, and meets the real-time requirements of dynamic projection scenarios.
Smart Images

Figure CN120455635A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle technology, and in particular to an image processing method, a control method for a vehicle-mounted lighting device, and an electronic device. Background Art
[0002] In the related art, the image is adjusted and then projected through a one-time large-scale projection transformation matrix. This method can project the image quickly. However, the projected image is prone to abrupt changes in edges and details, resulting in a jagged effect, which is particularly severe in dynamic scenes. Summary of the Invention
[0003] The present invention aims to solve at least one of the technical problems existing in the prior art. To this end, one object of the present invention is to provide an image processing method that can gradually transform an initially transformed image using multiple projection transformation sub-matrices, thereby avoiding the sudden changes and aliasing that would occur in the initially transformed image after a single perspective transformation. The method is also more effective in suppressing aliasing in dynamic and rapidly changing scenes.
[0004] A second object of the present invention is to provide a control method for a vehicle-mounted lighting device.
[0005] A third object of the present invention is to provide an electronic device.
[0006] A fourth object of the present invention is to provide a computer-readable storage medium.
[0007] A fifth object of the present invention is to provide a vehicle.
[0008] In order to solve the above problems, an embodiment of the first aspect of the present invention provides an image processing method, including: obtaining a target projection image, wherein the target projection image is obtained by transforming an initial transformation image based on multiple projection transformation sub-matrices; wherein the projection transformation sub-matrix is obtained based on the decomposition of the projection transformation total matrix, and the projection transformation total matrix is obtained based on the initial transformation image.
[0009] According to the image processing method of an embodiment of the present invention, the total projection transformation matrix is decomposed into multiple projection transformation sub-matrices, so that the initial transformation image is transformed by the multiple projection transformation sub-matrices to obtain the target projection image. Thus, compared with the prior art method of adjusting the image by a one-time large-scale projection transformation matrix before projection, the present application transforms the initial transformation image by multiple projection transformation sub-matrices before projection, rather than adjusting the image by a one-time large-scale projection transformation matrix. This avoids the sudden change and aliasing phenomenon caused by a single perspective transformation of the initial transformation image, and the aliasing phenomenon is more significantly suppressed in dynamic and rapidly changing scenes.
[0010] In some embodiments, the product of a plurality of said projection transformation sub-matrices is said projection transformation total matrix.
[0011] In some embodiments, the target projection image is obtained by transforming the (n-1)th intermediate transformation image by the nth projection transformation submatrix among the multiple projection change submatrices, and the (n-1)th intermediate transformation image is obtained by transforming the (n-2)th intermediate transformation image by the (n-1)th projection transformation submatrix, wherein the first intermediate transformation image is obtained by transforming the initial transformation image by the first projection transformation submatrix, and n is the total number of the multiple projection transformation submatrices, and n≥2.
[0012] In some embodiments, the total projection transformation matrix is obtained based on the coordinates of the boundary points of the initial transformation image and the physical coordinates of the boundary points of the initial transformation image in the area to be projected.
[0013] In some embodiments, each of the projection transformation sub-matrices is obtained based on the exponential power of the corresponding logarithmic matrix, and the logarithmic matrix of each of the projection transformation sub-matrices is obtained based on the matrix logarithm of the projection transformation total matrix and the number of the projection transformation sub-matrices.
[0014] In some embodiments, the initial transformed image is obtained by sequentially performing magnification processing, interpolation processing, and reduction processing on the initial image.
[0015] In some embodiments, the interpolation processing includes performing interpolation processing on the enlarged image based on a target interpolation method, and the accuracy of the target interpolation method is greater than the accuracy of the bidirectional interpolation method.
[0016] In some embodiments, the target interpolation method includes a bicubic interpolation method.
[0017] In some embodiments, the initial image includes at least one of vehicle information generated in real time based on advanced driver assistance system information and user-defined projection content.
[0018] In some embodiments, the magnification of the magnification process is the same as the reduction factor of the reduction process.
[0019] A second aspect of the present invention provides a method for controlling a vehicle-mounted lighting device, comprising: obtaining a target projection image according to the image processing method described in the above embodiment; and performing projection based on the target projection image.
[0020] According to the control method of the vehicle lighting device according to the embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the sudden change and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0021] In a third aspect, an embodiment of the present invention provides an electronic device, comprising: at least one processor; a memory communicatively connected to the at least one processor; the memory storing a computer program executable by the at least one processor, wherein when the at least one processor executes the computer program, the image processing method described in the above embodiment or the control method of the vehicle lighting device described in the above embodiment is implemented.
[0022] According to the electronic device of an embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the mutation and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0023] A fourth aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed, the image processing method described in the above embodiment is implemented or the control method of the vehicle-mounted lighting device described in the above embodiment is executed.
[0024] A fifth aspect of the present invention provides a vehicle, which includes the electronic device described in the above embodiment; or, the vehicle includes an image processing device and an image output device, the image processing device is connected to the image output device, the image processing device is used to obtain a target projection image according to the image processing method described in the above embodiment, and the image output device is used to output based on the target projection image.
[0025] According to the vehicle of the embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the mutation and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0026] In some embodiments, the image output device includes a vehicle-mounted lighting device.
[0027] In some embodiments, the vehicle-mounted lighting device includes a vehicle-mounted pixel headlight.
[0028] Additional aspects and advantages of the present invention will be set forth in part in the description which follows and, in part, will be obvious from the description which follows, or may be learned by practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments with reference to the following drawings, in which: Figure 1 is a flowchart of an image processing method according to an embodiment of the present invention; FIG2( a ) is a schematic diagram of an initial transformed image according to an embodiment of the present invention; FIG2( b ) is a schematic diagram of a first intermediate transformed image according to an embodiment of the present invention; FIG2( c ) is a schematic diagram of a second intermediate transformed image according to an embodiment of the present invention; FIG2( d ) is a schematic diagram of a third intermediate transformed image according to an embodiment of the present invention; FIG2( e ) is a schematic diagram of a target projection image according to one embodiment of the present invention; Figure 3 is a flowchart of an image processing method according to another embodiment of the present invention; Figure 4 is a flow chart of a method for controlling a vehicle lighting device according to an embodiment of the present invention; Figure 5 is a structural block diagram of an electronic device according to an embodiment of the present invention; Figure 6 is a structural block diagram of a vehicle according to one embodiment of the present invention; Figure 7 is a structural block diagram of a vehicle according to another embodiment of the present invention.
[0030] Reference numerals: Vehicle 100; electronic device 10; Processor 1; memory 2; image processing device 3; image output device 4. DETAILED DESCRIPTION
[0031] The embodiments of the present invention will be described in detail below. The embodiments described with reference to the accompanying drawings are exemplary. The embodiments of the present invention will be described in detail below.
[0032] Related technologies perform edge detection on the projected image, then filter out line segments with aliasing distortion. These segments are then filtered and the resulting image is replaced with the original image. However, this method only works for long straight lines with sparse aliasing, making it a narrow application area. It is also limited in its effectiveness in addressing aliasing issues with complex edges or dynamic images. Edge processing still requires significant computing resources, limiting its efficiency and making it unsuitable for real-time dynamic projection scenarios.
[0033] Alternatively, techniques such as the Sobel operator, interpolation, and Gaussian filtering can be used to anti-alias non-straight edges. However, this method requires parallel computing using graphics processors, increasing hardware complexity and deployment costs. It also fails to address the real-time response issues associated with dynamic projections. Anti-aliasing effectiveness is limited for complex textures and dynamic changes, especially in areas of high-frequency variation.
[0034] Alternatively, anti-aliasing optimization can be achieved through Gaussian texture downsampling and matching multi-resolution 3D rendering models. However, the training and matching process for rendering models is complex and unsuitable for real-time adjustments. Anti-aliasing effectiveness degrades at lower resolutions or when the camera is far from the target, and this approach requires high computing resources, making it unsuitable for resource-constrained embedded systems.
[0035] The above methods are mainly targeted at static or pre-processed images or specific scenes, and cannot effectively cope with the rapid changes and real-time requirements in dynamic scenes. They also require high hardware resource performance, which limits the wide range of practical applications.
[0036] In order to solve the above problems, an embodiment of the first aspect of the present invention provides an image processing method, which can gradually transform the initial transformed image through multiple projection transformation sub-matrices, thereby avoiding the mutation and aliasing phenomenon caused by the one-time perspective transformation of the initial transformed image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0037] Reference below Figure 1 The image processing method according to the embodiment of the present invention is described as follows. Figure 1 As shown, it includes: step S1-step S3.
[0038] Step S1: obtaining a total projection transformation matrix based on an initial transformation image.
[0039] The initial transformed image is the image that has undergone the initial image transformation before the image to be projected is projected. The total projection transformation matrix is the transformation relationship between the initial transformed image and the target projection image.
[0040] Specifically, the initial transformed image is input into a matrix solving algorithm to obtain the total projection transformation matrix.
[0041] Step S2: Decomposing the total projection transformation matrix to obtain a plurality of projection transformation sub-matrices.
[0042] Among them, the projection transformation submatrix is the intermediate transformation relationship between the initial transformation image and the target projection image.
[0043] Exemplarily, the total projection transformation matrix is decomposed into multiple projection transformation sub-matrices by singular value decomposition.
[0044] Step S3: transforming the initial transformation image based on multiple projection transformation sub-matrices to obtain a target projection image.
[0045] Specifically, the initial transformation image is transformed based on multiple projection transformation sub-matrices, that is, the initial transformation image is gradually transformed through multiple projection transformation sub-matrices to decompose the large-scale perspective transformation into multiple small-scale perspective transformations to obtain the target projection image. Each transformation of the initial transformation image by the decomposed multiple projection transformation sub-matrices can gradually approach the projection transformation of the initial transformation image by the total projection transformation matrix. Therefore, the present application decomposes the total projection transformation matrix into multiple projection transformation sub-matrices to transform the initial transformation image through multiple projection transformation sub-matrices, thereby decomposing the large-scale perspective transformation into multiple small-scale perspective transformations to gradually adjust the angle and position of the initial transformation image, and in each projection transformation sub-matrix. The array only makes small adjustments when performing perspective transformation on the initial transformed image, avoiding the sudden change and aliasing phenomenon caused by the one-time perspective transformation of the initial transformed image, achieving a smoother and more natural transition and a more delicate projection effect. It can also gradually optimize each detail area of the target projection image, greatly reducing or eliminating the aliasing phenomenon in the target projection image. The aliasing phenomenon is especially suppressed in dynamic and rapidly changing projection scenes. In addition, the computing resource requirements are low, making it suitable for resource-constrained embedded systems. In addition, since the processing speed of multiple small-scale perspective transformations is higher than that of deep learning algorithms, it can meet the rapid changes and real-time requirements in dynamic projection scenes.
[0046] In addition, it should be noted that the greater the number of projection transformation sub-matrices, the better the anti-aliasing effect of the target projection image.
[0047] According to the image processing method of an embodiment of the present invention, the total projection transformation matrix is decomposed into multiple projection transformation sub-matrices, so that the initial transformation image is transformed by the multiple projection transformation sub-matrices to obtain the target projection image. Thus, compared with the prior art method of adjusting the image by a one-time large-scale projection transformation matrix before projection, the present application transforms the initial transformation image by multiple projection transformation sub-matrices before projection, rather than adjusting the image by a one-time large-scale projection transformation matrix. This avoids the sudden change and aliasing phenomenon caused by a single perspective transformation of the initial transformation image, and the aliasing phenomenon is more significantly suppressed in dynamic and rapidly changing scenes.
[0048] In some embodiments, the product of multiple projection transformation sub-matrices is the total projection transformation matrix. That is, the total projection transformation matrix is P, and multiple projection transformation sub-matrices are obtained based on the decomposition of the total projection transformation matrix P. The multiple projection transformation sub-matrices include P1, P2, P3, P4, ..., P n , where P = P1 × P2 × P3 × P4…Pn , that is, the target projection image obtained by transforming the initial transformation image through multiple projection transformation sub-matrices is equivalent to the target projection image obtained by transforming the initial transformation image through the projection transformation total matrix P.
[0049] In some embodiments, the target projection image is obtained by transforming the (n-1)th intermediate transformation image by the nth projection transformation submatrix in multiple projection change submatrices, and the (n-1)th intermediate transformation image is obtained by transforming the (n-2)th intermediate transformation image by the (n-1)th projection transformation submatrix, wherein the first intermediate transformation image is obtained by transforming the initial transformation image by the first projection transformation submatrix, and n is the total number of multiple projection transformation submatrices, n≥2, and n can be 2, 3, 4 or 5, without limitation.
[0050] Specifically, the initial transformation image is transformed by the first projection transformation sub-matrix to obtain the first intermediate transformation image, and then the first intermediate transformation image is transformed by the nth projection transformation sub-matrix to obtain the second intermediate transformation image, and so on, the (n-1)th intermediate transformation image is transformed by the nth projection transformation sub-matrix to obtain the target projection image. Therefore, the present application decomposes the total projection transformation matrix into multiple projection transformation sub-matrices, so as to transform the initial transformation image step by step through multiple projection transformation sub-matrices, thereby decomposing the large-scale perspective transformation into multiple small-scale perspective transformations, so as to gradually adjust the angle and position of the initial transformation image, thereby avoiding the sudden change and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image.
[0051] Exemplarily, the total projection transformation matrix is P, and the projection transformation sub-matrix is decomposed based on the total projection transformation matrix P to obtain the projection transformation sub-matrix, which includes P1, P2, P3, P4 and P5, where P1 is the first projection transformation sub-matrix, ..., P5 is the fifth projection transformation sub-matrix. Based on this, the initial transformation image is first projected transformed by the first projection transformation sub-matrix P1, and the initial transformation image is shown in Figure 2 (a) to obtain the first intermediate transformation image, as shown in Figure 2 (b). Then, the first intermediate transformation image is projected transformed by the second projection transformation sub-matrix P2 to obtain the second intermediate transformation image, as shown in Figure 2 (c). Then, the second intermediate transformation image is projected transformed by the third projection transformation sub-matrix P3 to obtain the third intermediate transformation image, as shown in Figure 2 (d). Finally, the third intermediate transformation image is projected transformed by the fourth projection transformation sub-matrix P4 to obtain the target projection image, as shown in Figure 2 (e).
[0052] In some embodiments, the total projection transformation matrix is obtained based on the coordinates of the boundary points of the initial transformation image and the physical coordinates of the boundary points of the initial transformation image in the area to be projected. The specific steps are as follows.
[0053] First, obtain the coordinates of the boundary points of the initial transformation image. Assuming that the boundary points of the initial transformation image are (xi, yi) in the image coordinate system, the boundary of the initial transformation image can be expressed as: P image = (x1, y1), (x2, y2), …, (xn, yn), where n is the total number of boundary points.
[0054] Then, the physical coordinates of the boundary points of the initial transformed image in the area to be projected are obtained. Assume that the physical coordinates of each boundary point in the area to be projected can be expressed as (X i , Y i ), then the boundary points of the initial transformed image at the boundary of the area to be projected can be expressed as: P world = (X1, Y1), (X2, Y2), …, (Xn, Yn), where the physical coordinates (X i , Y i ) corresponds to the boundary points (xi, yi) of the initial transformation image. The physical coordinates are usually in a global coordinate system or physical space. The physical coordinates are obtained by mapping the boundary points (xi, yi) of the initial transformation image through a projection model (such as perspective transformation).
[0055] Finally, the image coordinates (xi, yi) of the boundary points of the initial transformation image and the physical coordinates (X i , Y i ) determines the total projection transformation matrix M, wherein the total projection transformation matrix M is used to map the image coordinates (xi, yi) of the boundary points of the initial transformation image to the physical coordinates (X i , Y i ). The total projection transformation matrix is the perspective transformation relationship between the two coordinates. The total projection transformation matrix is usually described by a (3×3) matrix. The total projection transformation matrix can be expressed by the following formula: (X i Y i 1) = M (xiyi1) It should be noted that the coordinates of at least four boundary points of the initially transformed image and the physical coordinates of the boundary points of the initially transformed image in the area to be projected are required to determine the eight elements of the total projection transformation matrix using the least squares method or other solution method. The area to be projected can be located on the ground. The physical coordinates of the boundary points of the initially transformed image in the area to be projected are determined by the relative position of the projection device and the projection plane, i.e., the ground.
[0056] Based on this, after obtaining the total projection transformation matrix, the initial transformation image can be projected transformed through the total projection transformation matrix. That is, by decomposing the total projection transformation matrix, multiple projection transformation sub-matrices are obtained, and then the initial transformation image is transformed through the first projection transformation sub-matrix to obtain the first intermediate transformation image. Similarly, the (n-1)th intermediate transformation image is transformed through the nth projection transformation sub-matrix to obtain the target projection image.
[0057] In some embodiments, each projection transformation submatrix is obtained based on the exponential power of the corresponding logarithmic matrix, and the logarithmic matrix of each projection transformation submatrix is obtained based on the matrix logarithm of the total projection transformation matrix and the number of projection transformation submatrices. That is, first, the matrix logarithm of the total projection transformation matrix T is calculated, and the matrix logarithm can be expressed as log(T). Then, the logarithmic matrix of each projection transformation submatrix is calculated based on the matrix logarithm of the total projection transformation matrix and the number of projection transformation submatrices N. The logarithmic matrix of each projection transformation submatrix can be expressed as: log(T) / N, where N is the number of projection transformation submatrices set artificially. Finally, the logarithmic matrix of each projection transformation submatrix is exponentially powered to obtain each projection transformation submatrix Ti.
[0058] In an embodiment, each projection transformation sub-matrix may be multiplied to determine whether the projection transformation total matrix T can be obtained. For example, if T1·T2·…·T N ≈T, then it is determined that the total projection transformation matrix can be obtained through each projection transformation sub-matrix.
[0059] In some embodiments, the initial transformed image is obtained by sequentially performing an enlargement process, an interpolation process, and a reduction process on the initial image. The initial transformed image is obtained through the following steps.
[0060] Specifically, prior art methods directly reduce the image to be projected when scaling it. This method can result in loss of detail in the projected image, particularly in the generation of jagged edges. To address this issue, the present invention first sequentially amplifies and interpolates the initial image, then reduces the interpolated initial image to obtain a preliminary transformed image, thereby avoiding the jagged edges of the preliminary transformed image. Specifically, the initial image is first amplified sequentially to refine its pixel information, providing more detail for subsequent interpolation. The amplified initial image is then interpolated to optimize and expand the initial image detail, smooth the initial image edge transitions, and improve the initial image resolution. Thus, interpolation enhances the initial image detail, providing more image data for subsequent processing steps. Finally, the interpolated initial image is reduced to restore the original projection resolution of the initial image, thereby obtaining the preliminary transformed image. Furthermore, during the reduction process, the initial image detail is preserved, the initial image edges are smoother, and the jagged edges of the initial image are reduced. Therefore, the method of first enlarging the initial image and then reducing it in the present application can retain more image details and clarity during the reduction process, improve the quality of the initial image, especially in the edge area, avoid the jagged effect caused by direct scaling, and supplement the initial image details through interpolation during the image enlargement stage, so that each pixel in the initial image can be more finely mapped to the reduced result, greatly improving the retention of image details and transition smoothness, ensuring that more detail information is retained when the initial image is reduced, and avoiding information loss during the direct reduction process.
[0061] In some embodiments, the interpolation process includes performing interpolation on the magnified image based on a target interpolation method, wherein the accuracy of the target interpolation method is greater than the accuracy of the bidirectional interpolation method.
[0062] Specifically, in the prior art, the interpolation methods used are relatively basic, such as the bilinear interpolation method. Although this method can provide a certain image smoothing effect, it has limited effect when processing complex image edges and high-frequency details, especially when scaling high-resolution images, which is prone to blurring. In order to solve this problem, the present application uses a high-precision target interpolation method to process images, wherein the accuracy of the target interpolation method is greater than the accuracy of the bidirectional interpolation method, so that the target interpolation method not only fills the blanks of the initial image at the edges and complex areas of the image, but also smoothes the edge transition areas, avoiding the jagged effect in the traditional interpolation method. As a result, the target interpolation algorithm can retain more information in the transition of the initial image details, especially in the edge areas, and can smooth the transition of details while avoiding blurring. Moreover, when processing high-resolution images, it can more accurately smooth the transition areas to ensure improved image quality, especially in dynamic environments, and can still maintain stable clarity.
[0063] In some embodiments, the target interpolation method includes a bicubic interpolation method.
[0064] Specifically, the present application uses the bicubic interpolation method to interpolate the initial image after the amplification process, which can more accurately calculate the transition between each pixel. Especially when processing complex image edges, it can greatly improve the restoration of details and reduce aliasing and blurring.
[0065] In some embodiments, the initial image includes at least one of vehicle information generated in real time based on advanced driver assistance system information and user-defined projection content. The vehicle information may include lane information, lane change reminders, warning symbols, etc.
[0066] In some embodiments, the magnification of the enlargement process is the same as the reduction factor of the reduction process, thereby obtaining the original initial image. For example, if the magnification of the enlargement process is 4 times, then the reduction factor of the reduction process is 4 times.
[0067] The image processing method according to an embodiment of the present invention is described below with reference to FIG2 , and the specific contents are as follows.
[0068] Step S4: input the initial image.
[0069] Step S5: enlarge the initial images in sequence.
[0070] Step S6: performing interpolation processing on the enlarged initial image.
[0071] Step S7: performing reduction processing on the interpolated initial image to obtain an initial transformed image.
[0072] Step S8: Perform multiple projection transformations on the initial transformation image using multiple projection transformation sub-matrices to obtain a target projection image.
[0073] Step S9: Projecting based on the target projection image.
[0074] A second embodiment of the present invention provides a method for controlling a vehicle lighting device, such as Figure 4 As shown, the control method at least includes: step S10-step S11.
[0075] Step S10 : obtaining a target projection image according to the image processing method of the above embodiment.
[0076] Step S11: Projecting based on the target projection image.
[0077] Specifically, the vehicle-mounted lighting device projects the target projection image.
[0078] According to the control method of the vehicle lighting device according to the embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the sudden change and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0079] A third embodiment of the present invention provides an electronic device 10, such as Figure 5 As shown, it includes: at least one processor 1 and a memory 2 communicatively connected to the at least one processor 1 .
[0080] The memory stores a computer program that can be executed by at least one processor, and when the at least one processor executes the computer program, it implements the image processing method of the above embodiment or the control method of the vehicle lighting device of the above embodiment.
[0081] According to the electronic device of an embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the mutation and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0082] A fourth aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed, the image processing method of the above embodiment is implemented or the control method of the vehicle lighting device of the above embodiment is executed.
[0083] A fifth embodiment of the present invention provides a vehicle 100, such as Figure 6 As shown, the vehicle 100 includes the electronic device 10 of the above embodiment; or Figure 7As shown, the vehicle 100 includes an image processing device 3 and an image output device 4 .
[0084] The image processing device is connected to the image output device. The image processing device is used to obtain the target projection image according to the image processing method of the above embodiment. The image output device is used to output based on the target projection image.
[0085] According to the vehicle of the embodiment of the present invention, the initial transformation image can be gradually transformed through multiple projection transformation sub-matrices, thereby avoiding the mutation and aliasing phenomenon caused by the one-time perspective transformation of the initial transformation image, and the effect of suppressing the aliasing phenomenon in dynamic and rapidly changing scenes is more obvious.
[0086] In some embodiments, the image output device includes an onboard lighting device.
[0087] In some embodiments, the vehicle-mounted lighting device includes a vehicle-mounted pixel headlight.
[0088] In the description of this specification, any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or more executable instructions for implementing the steps of a custom logical function or process, and the scope of the preferred embodiments of the present invention includes additional implementations in which functions may be performed in a different order than shown or discussed, including performing functions in a substantially simultaneous manner or in a reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.
[0089] The logic and / or steps represented in a flowchart or otherwise described herein, for example, can be considered a sequenced list of executable instructions for implementing the logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (e.g., a computer-based system, a system including a processor, or other system that can fetch and execute instructions from an instruction execution system, apparatus, or device). For purposes of this specification, a "computer-readable medium" is any device that can contain, store, communicate, propagate, or transport a program for use by, or in conjunction with, an instruction execution system, apparatus, or device. More specific examples (not exhaustive) of computer-readable media include: an electrical connection with one or more wires (electronic devices), a portable computer disk cartridge (magnetic device), random access memory (RAM), read-only memory (ROM), erasable and programmable read-only memory (EPROM or flash memory), fiber optic devices, and a portable compact disc read-only memory (CDROM). Furthermore, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing it in another suitable manner if necessary, and then storing it in a computer memory.
[0090] It should be understood that various components of the present invention may be implemented using hardware, software, firmware, or a combination thereof. In the aforementioned embodiments, multiple steps or methods may be implemented using software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented using hardware, as in another embodiment, any of the following technologies known in the art, or a combination thereof, may be used: a discrete logic circuit having logic gates for implementing logic functions on data signals, an application-specific integrated circuit having suitable combinational logic gates, a programmable gate array (PGA), a field-programmable gate array (FPGA), etc.
[0091] Those skilled in the art will understand that all or part of the steps in the method of the above embodiment can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium. When the program is executed, it includes one or a combination of the steps of the method embodiment.
[0092] In addition, the functional units in the various embodiments of the present invention may be integrated into a single processing module, or each unit may exist physically separately, or two or more units may be integrated into a single module. The aforementioned integrated modules may be implemented in the form of hardware or in the form of software functional modules. If the integrated modules are implemented in the form of software functional modules and sold or used as independent products, they may also be stored in a computer-readable storage medium.
[0093] The storage medium mentioned above may be a read-only memory, a magnetic disk, or an optical disk, etc. Although the embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and are not to be construed as limiting the present invention. Persons skilled in the art may make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present invention.
[0094] Throughout this specification, reference to terms such as "one embodiment," "some embodiments," "illustrative embodiments," "example," "specific example," or "some examples" means that a specific feature, structure, material, or characteristic described in conjunction with the embodiment or example is included in at least one embodiment or example of the present invention. In this specification, illustrative expressions of the above terms do not necessarily refer to the same embodiment or example.
[0095] While embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions, and variations may be made to the embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the claims and their equivalents.
Claims
1. An image processing method, characterized in that: include: Obtaining a target projection image, wherein the target projection image is obtained by transforming the initial transformation image based on a plurality of projection transformation sub-matrices; The projection transformation submatrix is obtained based on the decomposition of the projection transformation total matrix, and the projection transformation total matrix is obtained based on the initial transformation image.
2. The image processing method according to claim 1, wherein: The product of multiple projection transformation sub-matrices is the projection transformation total matrix.
3. The image processing method according to claim 1, wherein: The target projection image is obtained by transforming the (n-1)th intermediate transformation image using the nth projection transformation submatrix among the multiple projection change submatrices, and the (n-1)th intermediate transformation image is obtained by transforming the (n-2)th intermediate transformation image using the (n-1)th projection transformation submatrix. The first intermediate transformation image is obtained by transforming the initial transformation image using the first projection transformation submatrix. n is the total number of the multiple projection transformation submatrices, and n≥2.
4. The image processing method according to any one of claims 1 to 3, characterized in that: The total projection transformation matrix is obtained based on the coordinates of the boundary points of the initial transformation image and the physical coordinates of the boundary points of the initial transformation image in the area to be projected.
5. The image processing method according to any one of claims 1 to 3, characterized in that: Each of the projection transformation submatrices is obtained based on the exponential power of the corresponding logarithmic matrix, and the logarithmic matrix of each of the projection transformation submatrices is obtained based on the matrix logarithm of the projection transformation total matrix and the number of the projection transformation submatrices.
6. The image processing method according to any one of claims 1 to 3, characterized in that: The initial transformed image is obtained by sequentially performing magnification processing, interpolation processing and reduction processing on the initial image.
7. The image processing method according to claim 6, characterized in that: The interpolation process includes performing interpolation on the image after the magnification process based on a target interpolation method, and the accuracy of the target interpolation method is greater than the accuracy of the bidirectional interpolation method.
8. The image processing method according to claim 7, wherein: The target interpolation method includes a bicubic interpolation method.
9. The image processing method according to claim 6, wherein: The initial image includes at least one of vehicle information generated in real time based on advanced driver assistance system information and user-defined projection content.
10. The image processing method according to claim 6, wherein: The magnification of the magnification process is the same as the reduction magnification of the reduction process.
11. A method for controlling a vehicle-mounted lighting device, characterized in that: include: Obtaining a target projection image according to the image processing method according to any one of claims 1 to 10; Projection is performed based on the target projection image.
12. An electronic device, characterized in that: include: at least one processor; a memory communicatively coupled to the at least one processor; The memory stores a computer program that can be executed by the at least one processor, and when the at least one processor executes the computer program, it implements the image processing method according to any one of claims 1 to 10 or the control method of the vehicle lighting device according to claim 11.
13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed, the image processing method according to any one of claims 1 to 10 is implemented or the control method of the vehicle-mounted lighting device according to claim 11 is executed.
14. A vehicle, characterized in that: The vehicle includes the electronic device according to claim 12; Alternatively, the vehicle includes an image processing device and an image output device, the image processing device is connected to the image output device, the image processing device is used to obtain a target projection image according to the image processing method according to any one of claims 1-10, and the image output device is used to output based on the target projection image.
15. The vehicle according to claim 14, characterized in that The image output device includes a vehicle-mounted lighting device.
16. The vehicle according to claim 14, characterized in that The vehicle-mounted lighting device includes a vehicle-mounted pixel headlight.