Continuous adaptive conversion display method of screen and related device

The method and device for continuous adaptive transformation display address the issue of delayed content changes by synchronizing screen content with device rotation, ensuring consistent and intuitive display through real-time angle adjustments.

CN119179454APending Publication Date: 2024-12-24ENSUREBIT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411375965.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-29
Publication Date
2024-12-24

AI Technical Summary

Technical Problem

Existing in-vehicle central control systems and mobile devices fail to synchronize screen content display with device rotation in real time, leading to delayed and inconsistent content changes during device angle adjustments.

Method used

A method and device for continuous adaptive transformation display that calculates and adjusts screen content in real time based on device rotation angles (alpha, beta, gamma) using sensor data, ensuring consistent display direction and handling UI controls during rotation.

Benefits of technology

Enables real-time adjustment of screen content to match device rotation angles, improving clarity and user experience by maintaining horizontal display and correct orientation during device rotation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119179454A_ABST
    Figure CN119179454A_ABST
Patent Text Reader

Abstract

The invention discloses a continuous adaptive conversion display method of a screen and a related device, and relates to the technical field of vehicle-mounted central control platforms, and the method comprises the steps: obtaining initial rotation angle related data of equipment in a space and rotation angle related data of a plurality of adjacent moments; respectively calculating the angle difference between the rotation angle related data at each moment and the initial rotation angle related data to obtain angle difference values at a plurality of moments; determining the rotation direction of the equipment according to the angle difference value at the current moment and the angle difference value at the previous moment; determining a display angle of screen content according to the rotation direction and amplitude of the equipment; the amplitude is a variable quantity of a rotation angle according to two adjacent moments; and adjusting the screen content according to the display angle. The display angle of the screen content can be calculated in real time and dynamically adjusted, it is ensured that rotation of the content and rotation of equipment are continuously synchronized, and the correct display direction is always kept.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle-mounted central control platforms, and in particular to a method for continuously adaptively changing a display of a screen and a related device. Background Art

[0002] Currently, most in-vehicle central control products, mobile devices, and tablet devices will only switch the content angle when the device is rotated to a fixed angle. This method may cause delays in displaying content in some scenarios and fail to respond to device rotation changes in real time.

[0003] Therefore, how to design a technical solution that can synchronize the adaptive angle change of the device and the screen content display in real time has become a technical problem that urgently needs to be solved in this field. Summary of the invention

[0004] The purpose of the present invention is to provide a method and related device for continuous adaptive transformation display of a screen, which can ensure that during the device angle switching process, the screen content can continuously change with the angle of the device and be adjusted in real time.

[0005] To achieve the above object, the present invention provides the following solutions:

[0006] In a first aspect, the present invention provides a method for continuously adaptively transforming and displaying a screen, the method comprising:

[0007] Obtain the initial rotation angle data of the device in space and the rotation angle data of several adjacent moments; the rotation angle data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis.

[0008] The angle difference between the rotation angle related data at each moment and the initial rotation angle related data is calculated respectively to obtain angle difference values ​​at several moments.

[0009] The rotation direction of the device is determined based on the angle difference value at the current moment and the angle difference value at the previous moment.

[0010] The display angle of the screen content is determined according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments.

[0011] The screen content is adjusted according to the display angle.

[0012] Optionally, the screen continuous adaptive transformation display method further includes:

[0013] When the screen includes a UI control, it is determined whether the UI control rotates along with the screen content.

[0014] If not, the fixed position remains unchanged.

[0015] If so, the coordinates of the four corner points of the rotated UI control are determined by a geometric calculation method.

[0016] According to the coordinates of the four corner points of the UI control, a new position and boundary of the UI control are calculated.

[0017] The UI control is adjusted according to the new position and the bounds.

[0018] Optionally, the screen continuous adaptive transformation display method further includes:

[0019] Exception handling mechanism to ensure that the display of screen content and UI controls is always in a controllable state.

[0020] Optionally, the angle difference between the rotation angle related data at each moment and the initial rotation angle related data is calculated respectively to obtain angle difference values ​​at several moments, specifically including:

[0021] Calculate the difference between the alpha value at each moment and the initial alpha value to get the alpha difference value.

[0022] Adjust the alpha difference value to between -180 degrees and 180 degrees.

[0023] Calculate the difference between the beta value at each moment and the initial beta value to get the beta difference value.

[0024] The beta difference value is adjusted to between -180 degrees and 180 degrees.

[0025] Calculate the difference between the gamma value at each moment and the initial gamma value to get the gamma difference value.

[0026] The gamma difference value is adjusted to between -90 degrees and 90 degrees.

[0027] Optionally, determining the rotation direction of the device according to the angle difference value at the current moment and the angle difference value at the previous moment specifically includes:

[0028] When the alpha difference value at the current moment is greater than the alpha difference value at the previous moment, the device is rotating clockwise and the rotation direction is marked as positive.

[0029] When the alpha difference value at the current moment is less than the alpha difference value at the previous moment, the device rotates counterclockwise and the rotation direction is marked as negative.

[0030] Optionally, determining the display angle of the screen content according to the rotation direction and amplitude of the device specifically includes:

[0031] Adjust the rotation angle to between -360 degrees and 360 degrees to obtain the adjusted rotation angle.

[0032] According to the rotation direction, the adjusted rotation angle is smoothed to obtain a smoothed angle.

[0033] The angle after smoothing is used as the display angle of the screen content.

[0034] In a second aspect, the present invention provides a continuous adaptive display device for a screen, the continuous adaptive display device for a screen comprising:

[0035] The rotation angle related data acquisition module is used to obtain the initial rotation angle related data of the device in space and the rotation angle related data of several adjacent moments; the rotation angle related data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis.

[0036] The angle difference calculation module is used to calculate the angle difference between the rotation angle related data at each moment and the initial rotation angle related data, and obtain the angle difference values ​​at several moments.

[0037] The rotation direction determination module is used to determine the rotation direction of the device according to the angle difference value at the current moment and the angle difference value at the previous moment.

[0038] The display angle determination module is used to determine the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments.

[0039] The screen content adjustment module is used to adjust the screen content according to the display angle.

[0040] In a third aspect, the present invention provides a computer device comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement any of the above-described continuous adaptive display methods for a screen.

[0041] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the continuous adaptive display method for a screen as described in any one of the above.

[0042] In a fifth aspect, the present invention provides a computer program product, comprising a computer program, which, when executed by a processor, implements any of the above-mentioned methods for continuous adaptive transformation and display of a screen.

[0043] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:

[0044] The present invention provides a method and a related device for continuous adaptive transformation display of a screen. First, the initial rotation angle related data of the device in space and the rotation angle related data of several adjacent moments are obtained; the rotation angle related data include: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis, so as to ensure that the system can respond in time; secondly, the angle difference between the rotation angle related data at each moment and the initial rotation angle related data is calculated respectively, and the angle difference values ​​at several moments are obtained to prepare for the determination of the subsequent rotation direction; then, the rotation direction of the device is determined according to the angle difference value at the current moment and the angle difference value at the previous moment; finally, the display angle of the screen content is determined according to the rotation direction and amplitude of the device; the amplitude is the change amount of the rotation angle according to two adjacent moments; according to the display angle, the screen content is adjusted. Traditional technology often switches content only when the device reaches a specific angle, which may cause delayed changes in the displayed content. Compared with traditional technology, the present invention can adjust the screen content in real time at any rotation angle of the device, so that it always keeps horizontal display or conforms to the rotation direction of the device. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0046] Figure 1 This is a diagram of an application environment of a method for continuously adaptively changing a display of a screen in one embodiment of the present invention.

[0047] Figure 2 A schematic flow chart of a method for continuous adaptive display transformation of a screen provided by an embodiment of the present invention.

[0048] Figure 3 A schematic diagram of an embodiment of the present invention without performing any angle adjustment on the content.

[0049] Figure 4This is a schematic diagram of a device provided by an embodiment of the present invention being rotated 32 degrees to the right and the content being adjusted 32 degrees to the left.

[0050] Figure 5 This is a schematic diagram of a UI control maintained in a fixed position according to an embodiment of the present invention.

[0051] Figure 6 A schematic diagram of a dynamically adjusted UI control provided by an embodiment of the present invention.

[0052] Figure 7 This is a schematic diagram showing that the device provided in an embodiment of the present invention is rotated right and UI controls are blocked by other contents.

[0053] Figure 8 Another schematic diagram of a device provided by an embodiment of the present invention being rotated right and UI controls being blocked by other contents.

[0054] Fig. 9 This is a schematic diagram of the state of the device initialized to 0 degrees according to an embodiment of the present invention.

[0055] Fig.10 This is a schematic diagram of a device provided by an embodiment of the present invention being rotated 45 degrees to the right.

[0056] Fig.11 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 90 degrees to the left or 270 degrees to the right.

[0057] Fig.12 This is a schematic diagram of a device provided by an embodiment of the present invention rotated 180 degrees.

[0058] Fig.13 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 45 degrees to the left or 225 degrees to the right.

[0059] Fig.14 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 45 degrees to the right and a UI control being rotated 45 degrees to the left.

[0060] Fig.15 This is a schematic diagram of a device provided in an embodiment of the present invention rotating 180 degrees and a UI control rotating 180 degrees.

[0061] Fig.16 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 90 degrees to the right and a UI control being rotated 90 degrees to the left.

[0062] Fig.17 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 45 degrees to the left or 315 degrees to the right.

[0063] Fig.18This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 45 degrees to the left and the UI control area being adjusted.

[0064] Fig.19 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 90 degrees to the left and the UI control area being adjusted.

[0065] Fig. 20 This is a schematic diagram of a device provided in an embodiment of the present invention being rotated 200 degrees to the left and the UI control area being adjusted.

[0066] Fig.21 A schematic diagram showing that a device provided in an embodiment of the present invention is rotated 200 degrees to the left, and a UI control is fixed at a certain point and an angle is modified according to screen rotation.

[0067] Fig. 22 A schematic diagram of functional modules of a device for continuously adaptively changing a screen display provided by an embodiment of the present invention.

[0068] Fig.23 A schematic diagram of the structure of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0069] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0070] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0071] The present invention solves the limitation of the prior art that it is limited to fixed-angle switching, and proposes a technical solution that can synchronize the adaptive angle change of the device with the display of the screen content in real time. Through the present invention, the device can switch angles at any angle, and the system can calculate and adjust the display angle of the content in real time based on the data of the device sensor (including but not limited to DeviceOrientation events), thereby ensuring that the content is consistent with the rotation of the device and always presents the correct display direction. This method avoids the delay or inconsistent display problems caused by traditional fixed-angle rotation, effectively improves the clarity and consistency of the screen content during driving, and thus significantly enhances the user experience.

[0072] The continuous adaptive display method of the screen provided by the embodiment of the present invention can be applied to Figure 1In the application environment shown, the terminal 102 communicates with the server 104 through a network. The data storage system can store data that the server 104 needs to process. The data storage system can be set up separately, integrated on the server 104, or placed on the cloud or other servers. The terminal 102 may send the acquired data related to the initial rotation angle of the device in space and the rotation angle data of several adjacent moments to the server 104, wherein the rotation angle data includes: alpha, beta and gamma, wherein alpha is the rotation angle of the device around the Z axis, beta is the rotation angle of the device around the X axis, and gamma is the rotation angle of the device around the Y axis; after receiving the data related to the initial rotation angle of the device in space and the rotation angle data of several adjacent moments, the server 104 calculates the angle difference between the rotation angle data of each moment and the initial rotation angle data for the initial rotation angle data of the device in space and the rotation angle data of several adjacent moments, and obtains the angle difference values ​​at several moments; determines the rotation direction of the device according to the angle difference value at the current moment and the angle difference value at the previous moment; determines the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change amount of the rotation angle between two adjacent moments; and adjusts the screen content according to the display angle. The server 104 may feed back the obtained display angle to the terminal 102. In addition, in some embodiments, the continuous adaptive transformation display method of the screen can also be implemented independently by the server 104 or the terminal 102. For example, the terminal 102 can directly perform continuous adaptive transformation display processing on the initial rotation angle related data of the device in the space and the rotation angle related data at several adjacent moments, or the server 104 can obtain the initial rotation angle related data of the device in the space and the rotation angle related data at several adjacent moments from the data storage system, and perform continuous adaptive transformation display processing on the initial rotation angle related data of the device in the space and the rotation angle related data at several adjacent moments.

[0073] The terminal 102 may be, but is not limited to, various desktop computers, laptop computers, smart phones, and tablet computers. The server 104 may be implemented as an independent server or a server cluster consisting of multiple servers, or may be a cloud server.

[0074] In an exemplary embodiment, Figure 2 As shown, a method for continuous adaptive transformation display of a screen is provided. The method is executed by a computer device, and can be executed by a computer device such as a terminal or a server alone, or by a terminal and a server together. In an embodiment of the present invention, the method is applied to Figure 1The server 104 in the example is used as an example to illustrate the method, which includes the following steps S1 to S5. Among them:

[0075] S1: Obtain the initial rotation angle data of the device in space and the rotation angle data at several adjacent moments; the rotation angle data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis.

[0076] S2: Calculate the angle difference between the rotation angle related data at each moment and the initial rotation angle related data respectively, and obtain angle difference values ​​at several moments.

[0077] S3: Determine the rotation direction of the device according to the angle difference value at the current moment and the angle difference value at the previous moment.

[0078] S4: Determine the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments.

[0079] S5: Adjusting screen content according to the display angle.

[0080] By implementing the above-mentioned steps S1 to S5, the present invention can ensure that during the device angle switching process, the screen content can continuously change with the angle of the device and adjust in real time, and always maintain a horizontal display. This technology is not only applicable to vehicle-mounted central control systems, but can also be applied to other devices with sensors, such as mobile devices, tablets, etc., which significantly improves the user experience. This method is particularly suitable for application scenarios with high requirements for display flexibility and real-time performance, such as vehicle-mounted central control systems, gaming devices, document viewing, etc. Through this technology, users can enjoy a smoother and more intuitive experience when using these devices, without having to worry about misalignment or inconsistency of display content caused by device rotation.

[0081] In an exemplary embodiment, in step S1, it specifically includes:

[0082] Use the device's orientation sensor to obtain data related to the device's rotation angle in space, where alpha is the device's rotation angle around the Z axis, indicating the device's direction relative to the geomagnetic North Pole, with a value range of 0 to 360 degrees; beta is the device's rotation angle around the X axis, indicating the degree of the device's forward and backward tilt, with a value range of -180 to 180 degrees; gamma is the device's rotation angle around the Y axis, indicating the degree of the device's left and right tilt, with a value range of -90 to 90 degrees.

[0083] When the device starts, the system records the initial state of the device, including the initial values ​​of alpha, beta, and gamma. These initial values ​​are used as a reference for subsequent rotation angle calculations. For example, when the device starts, if it is in a horizontal and stationary state, the system will record the alpha, beta, and gamma values ​​at this time and use them as the reference values ​​for subsequent rotation calculations.

[0084] By continuously monitoring the changes in the device's orientation sensor, the alpha, beta, and gamma values ​​of the current device are obtained in real time. Whenever the device's posture changes, these data will be updated to ensure that the system can respond in a timely manner.

[0085] In another exemplary embodiment of the present invention, in step S2, in order to calculate the angle difference between the current state and the initial state of the device, the present invention designs an angle difference calculation method, which includes the following steps:

[0086] Alpha difference calculation: The system first calculates the difference between the device's current alpha value and the initial alpha value. If the calculated difference exceeds 180 degrees, it means that the rotation angle may cross the 360-degree boundary. To avoid this discontinuity, the system adjusts the alpha difference value to between -180 and 180 degrees. Specifically:

[0087] If the difference value is greater than 180 degrees, the system subtracts 360 degrees from it to bring it back into the range of -180 to 180 degrees.

[0088] If the difference value is less than -180 degrees, the system adds 360 degrees to it to bring it back into the range of -180 to 180 degrees.

[0089] Beta difference calculation: The system detects the front-to-back tilt change of the device by calculating the difference between the current beta value of the device and the initial beta value. To avoid large angle jumps, the system normalizes the calculated beta difference value to ensure that it is between -180 degrees and 180 degrees.

[0090] First, calculate the difference between the current beta value and the initial beta value.

[0091] The system then adjusts the difference value to between -180 and 180 degrees to avoid large angle jumps.

[0092] Gamma difference calculation: The system calculates the difference between the current gamma value and the initial gamma value to detect the left and right tilt changes of the device. In order to maintain the continuity of the rotation angle, the system normalizes the gamma difference value to between -90 degrees and 90 degrees.

[0093] If the calculated difference exceeds 90 degrees, the system adjusts it back to between -90 and 90 degrees.

[0094] It should be noted that the current moment represents several moments, that is, the current moment represents the moment when the posture of each device changes. By comparing the absolute values ​​of gamma and beta, the system determines the direction of the device (such as left, right, up, down) based on the larger value.

[0095] In another exemplary embodiment of the present invention, in step S3, the following steps are specifically included:

[0096] S31: When the alpha difference value at the current moment is greater than the alpha difference value at the previous moment, the system determines that the device is rotating clockwise and marks the rotation direction as positive (ie, “+”).

[0097] S32: When the alpha difference value at the current moment is less than the alpha difference value at the previous moment, the system determines that the device is rotating counterclockwise and marks the rotation direction as negative (ie, “-”).

[0098] In another exemplary embodiment of the present invention, in step S4, specifically including:

[0099] S41: adjusting the rotation angle to between -360 degrees and 360 degrees to obtain an adjusted rotation angle.

[0100] S42: Smoothing the adjusted rotation angle according to the rotation direction to obtain a smoothed angle.

[0101] S43: Using the angle after the smoothing process as the display angle of the screen content.

[0102] The system gradually adjusts the display angle of the screen content according to the rotation direction and amplitude of the device (amplitude: refers to the angular change of the device rotation, that is, the angular difference generated by each rotation. For example, when the device rotates from a stationary state to a certain angle, the angular change generated in this process is the amplitude. During the continuous rotation process, the difference between the sensor data read each time can be regarded as a "amplitude". This amplitude plays a key role in calculating the rotation direction and adjusting the display content) to ensure that the content always maintains the correct display direction. The specific adjustment process includes:

[0103] When the device's rotation angle exceeds 360 degrees, the system normalizes the angle value so that it loops between -360 and 360 degrees to maintain the continuity of content rotation. For example, when the angle exceeds 360 degrees, the system subtracts 360 degrees from it to ensure that the value is within a reasonable range.

[0104] Angle smoothing: To prevent jitter or instability when the content is rotated, the system will smooth the angle changes to ensure the smoothness of the rotation process.

[0105] The present invention aims to solve the problem in current vehicle-mounted central control systems, mobile devices and tablet devices that the displayed content cannot be continuously adjusted with the angle when the device is rotated. Traditional technology often only switches content when the device reaches a certain angle, which may cause delayed changes in the displayed content. The present invention proposes a technical solution that can adjust the screen content in real time at any rotation angle of the device so that it always remains horizontally displayed or conforms to the rotation direction of the device. This solution is compatible with the rotation mechanism of existing devices and is suitable for vehicle-mounted central control systems and other devices equipped with sensors, which significantly improves the user experience and ensures the real-time and consistency of the content.

[0106] In another exemplary embodiment of the present invention, in step S5, whenever the rotation angle of the device changes, the system adjusts the display direction of the screen content in real time according to the calculated rotation angle. By updating the display angle of the content, it is ensured that the screen content always remains horizontal during the rotation of the device.

[0107] Figure 3 The display direction of the content rotated for normal device rotation. Figure 4 The device is rotated 32 degrees to the right and the content is adjusted 32 degrees to the left, so that the content remains horizontal. This is the final display result.

[0108] In another exemplary embodiment of the present invention, the method for continuously adaptively changing the display of the screen further includes:

[0109] S6: When the screen includes a UI control, determine whether the UI control rotates along with the screen content.

[0110] S7: If not, keep the fixed position unchanged.

[0111] S8: If so, determine the coordinates of the four corner points of the rotated UI control by a geometric calculation method.

[0112] S9: Calculate the new position and boundary of the UI control according to the coordinates of the four corner points of the UI control.

[0113] S10: Adjusting the UI control according to the new position and the boundary.

[0114] The present invention also considers the display effect of other UI controls on the screen during the rotation process. In order to ensure that the controls remain visible and operable after the device is rotated, the system adjusts the display of the controls accordingly according to the position and rotation angle of the controls.

[0115] Specifically, the system uses geometric calculation methods to determine the coordinates of the four corner points of the rotated control, and calculates the new position and boundaries of the control based on this to ensure that the control is displayed correctly after rotation.

[0116] After determining the coordinates of the four corner points, although the position and boundaries of the control can be determined directly, the display area of ​​the control needs to be properly processed according to the coordinates after the device is rotated. Although the display area of ​​the control can be determined by calculating the coordinates of the four corner points, the following details need to be considered in actual applications:

[0117] Center Display: Ensure that the control is centered in the new position after rotation or maintains its relative layout position.

[0118] Screen boundary handling: Ensure that controls do not extend beyond the screen boundaries, or are cropped or resized if they do.

[0119] During the rotation of the device, the UI controls on the screen (such as buttons, input boxes, icons, etc.) will change with the angle of the device. The present invention not only focuses on the continuous rotation synchronization of the displayed content, but also takes into account the display effects of other UI controls on the device screen to ensure that the controls can maintain visibility and operability during the rotation process, and will not cause the controls to be misplaced, blocked or inconvenient to operate due to the rotation of the device.

[0120] Reason and purpose:

[0121] When the device is rotated, the screen content will be adjusted in real time according to the rotation angle of the device. If the control does not adjust accordingly with the device rotation position, the following problems may occur:

[0122] Control display position offset: After rotation, the position of the control may be offset relative to the original display content, causing the user to be unable to see the control normally or even unable to operate it.

[0123] Controls are blocked or displayed incorrectly: During the rotation process, if the boundaries of controls are not recalculated, controls may be blocked by other displayed content, affecting the user experience (such as Figure 7 shown).

[0124] Reduced control operability: Controls may be moved to a position that is difficult for users to reach due to device rotation, resulting in inconvenience in operation (such as Figure 8 shown).

[0125] In order to address these problems, the present invention proposes a control position adjustment method based on a geometric algorithm, which ensures that the display effect and operability of the control remain consistent after the screen is rotated by calculating the coordinates of the corner points of the control before and after rotation.

[0126] Implementation principle:

[0127] A control is usually defined by the coordinates of four corner points, which define its display boundaries on the screen. For example, for a rectangular button, its boundaries are determined by four corner points (upper left, upper right, lower left, and lower right).

[0128] When the device is rotated, the system uses the angle of the content calculated above to calculate the new coordinates of the control after rotation. The specific method is to transform the four corner points of the control through geometric transformation (such as rotation matrix) and calculate the new position after rotation.

[0129] Suppose there is a point (x, y) on a two-dimensional plane. If you want to rotate an angle θ around the origin, use the following rotation matrix formula:

[0130] [x']=[cos(θ)-sin(θ)]*[x];

[0131] [y']=[sin(θ)-cos(θ)]*[y];

[0132] Where (x', y') are the new coordinates of the rotated point, (x, y) are the coordinates of the original point, and θ is the rotation angle (in radians).

[0133] The specific calculation steps are as follows:

[0134] Angle conversion: First, make sure that θ is expressed in radians. If the given angle is expressed in degrees, use the formula to convert it.

[0135] Apply the rotation matrix: Calculate the new coordinates (x', y') according to the rotation matrix formula.

[0136] Suppose there is a rectangular control whose four initial corner point coordinates are:

[0137] Upper left corner: (x1, y1); upper right corner: (x2, y2); lower left corner: (x3, y3); lower right corner: (x4, y4).

[0138] After the device is rotated, the rotation matrix formula is used to calculate the new coordinates of each corner point after rotation:

[0139] Upper left corner: (x1', y1'); upper right corner: (x2', y2'); lower left corner: (x3', y3'); lower right corner: (x4', y4').

[0140] By calculating the coordinates of the four corner points after rotation, the system checks whether these corner points are beyond the visible range of the screen. For example, when the screen width is screenWidth and the height is screenHeight, the following conditions need to be checked:

[0141] 0≤x1',x2',x3',x4'≤screenWidth;

[0142] 0≤y1',y2',y3',y4'≤screenHeight;

[0143] If a corner of a control exceeds the boundary of the screen, it needs to be adjusted according to the distance of the excess. The purpose of the adjustment is to put the corner that exceeds the boundary back into the screen. The specific adjustment steps are as follows:

[0144] Horizontal translation: If the x coordinate of a corner point of the control exceeds the left or right boundary, the overall position of the control is translated to the left or right so that the x coordinate falls within the screen width.

[0145] For example, if the upper right corner of the control is beyond the right edge of the screen, translate the control to the left:

[0146] newLeft=left-(x2'-screenWidth);

[0147] Vertical translation: If the y coordinate of a corner point of the control exceeds the upper or lower boundary, the overall position of the control is translated up or down so that the y coordinate falls within the screen height range.

[0148] For example, if the lower left corner of the control extends beyond the bottom edge of the screen, translate the control upward:

[0149] newTop=top-(y3'-screenHeight);

[0150] Example: Assume there is a rectangular control, the coordinates of the initial four corner points are:

[0151] Upper left corner: (0, 0); upper right corner: (100, 0); lower left corner: (0, 50); lower right corner: (100, 50).

[0152] The device is rotated 45 degrees, and the rotation matrix is ​​used to calculate the new coordinates of each corner point. Assume the screen is 200px wide and 200px high.

[0153] The new coordinates calculated by the rotation matrix formula may be:

[0154] Upper left corner: (-20, 30); upper right corner: (80, -30); lower left corner: (10, 60); lower right corner: (110, 90).

[0155] Since the y coordinate of the upper right corner is -30, which exceeds the upper boundary of the screen, the entire control is translated downward by 30px so that the upper right corner is within the screen boundary. After adjustment, the control will be completely within the screen and maintain normal display.

[0156] That is, UI controls can choose to rotate with the screen content, or remain in a fixed position (such as Figure 5 The system dynamically adjusts the display mode of the control according to the actual needs of the user (such as Figure 6 to ensure the best user experience.

[0157] In another exemplary embodiment of the present invention, the method for continuously adaptively changing the display of the screen further includes:

[0158] S11: Exception handling mechanism to ensure that the display of screen content and UI controls is always in a controllable state.

[0159] In extreme cases (such as rapid or continuous device rotation), the system uses a built-in exception handling mechanism to ensure that the display of screen content and controls is always in a controllable state to avoid content misalignment or invisible controls.

[0160] The present invention aims to solve the limitation of the prior art that screen rotation is limited to fixed angle switching. Through the present invention, when the device is rotated at any angle, the system can calculate and dynamically adjust the display angle of the screen content in real time, ensuring that the content is continuously synchronized with the rotation of the device and always maintaining the correct display direction. This technology is not only applicable to vehicle-mounted central control systems, but can also be widely used in other devices with sensors.

[0161] The present invention also provides an application scenario, which applies the above-mentioned continuous adaptive transformation display method of the screen. Specifically: the continuous adaptive transformation display method of the screen provided in this embodiment can be applied in the rotation scenario of the vehicle-mounted central control platform. The rotation of the vehicle-mounted central control platform includes a data acquisition link, an angle difference value calculation link, a rotation direction determination link and a display angle determination link; in the data acquisition link, the initial rotation angle related data of the device in space and the rotation angle related data of several adjacent moments are obtained; the rotation angle related data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis; then the angle difference between the rotation angle related data at each moment and the initial rotation angle related data is calculated respectively to obtain the angle difference values ​​at several moments; then the rotation direction of the device is determined according to the angle difference value at the current moment and the angle difference value at the previous moment; according to the rotation direction and amplitude of the device, the display angle of the screen content is determined; the amplitude is the change amount of the rotation angle between two adjacent moments; according to the display angle, the screen content can be adjusted.

[0162] like Figure 9-13As shown, the content has not been adjusted. By default, the orientation of the content is determined by the device orientation. For example, if the device is rotated 180 degrees, the content is visually displayed upside down. Or if the device is rotated 45 degrees, when viewing the content, you will also be accustomed to viewing the content as the device tilts.

[0163] like Figure 14-17 As shown, the angle of the content is adjusted. No matter how the device changes, the content always remains in an upward direction. However, if the component is also adjusted with the content, occlusion will occur. At this time, it is necessary to combine the angle of content adjustment and the visual position offset caused by the partial rotation of the control, and use the matrix algorithm to set the desired position of the component according to the needs.

[0164] like Figure 18-Figure 20 As shown, there are two groups of controls on the device, displayed in different forms. The controls in group P will change with the direction of the device, always remain on the upper left side of the user's vision, and the content will always be displayed vertically upward. The controls in group T are fixed in one position and will change the angle of the controls according to the direction of the device. Similarly, the content will always be displayed vertically upward.

[0165] like Fig.21 As shown, the settings are the same as those of the T group controls above. No matter what the controls on the page are or how the device orientation changes, the visible content is always displayed upwards.

[0166] Based on the same inventive concept, an embodiment of the present invention further provides a device for continuously adaptively transforming and displaying a screen for implementing the above-mentioned method for continuously adaptively transforming and displaying a screen. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above-mentioned method, so the specific limitations in the embodiments of the device for continuously adaptively transforming and displaying a screen provided below can refer to the limitations of the method for continuously adaptively transforming and displaying a screen in the above text, and will not be repeated here.

[0167] In an exemplary embodiment, Fig. 22 As shown, a continuous adaptive transformation display device of a screen is provided, and the continuous adaptive transformation display device of the screen comprises:

[0168] The rotation angle related data acquisition module M1 is used to obtain the initial rotation angle related data of the device in space and the rotation angle related data of several adjacent moments; the rotation angle related data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis.

[0169] The angle difference calculation module M2 is used to calculate the angle difference between the rotation angle related data at each moment and the initial rotation angle related data, and obtain the angle difference values ​​at several moments.

[0170] The rotation direction determination module M3 is used to determine the rotation direction of the device according to the angle difference value at the current moment and the angle difference value at the previous moment.

[0171] The display angle determination module M4 is used to determine the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments.

[0172] The screen content adjustment module M5 is used to adjust the screen content according to the display angle.

[0173] In an exemplary embodiment, a computer device is provided. The computer device may be a server or a terminal. The internal structure diagram thereof may be as follows: Fig.23 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data related to the initial rotation angle of the device in space and data related to the rotation angle of several adjacent moments. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a continuous adaptive transformation display method of a screen is implemented.

[0174] Those skilled in the art will understand that Fig.23 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present invention, and does not constitute a limitation on the computer device to which the solution of the present invention is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0175] In an exemplary embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the above-mentioned method embodiments are implemented when the processor executes the computer program.

[0176] In an exemplary embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the above-mentioned method embodiments are implemented.

[0177] In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the above-mentioned method embodiments are implemented.

[0178] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in the present invention are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0179] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided by the present invention can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM may be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0180] The database involved in each embodiment provided by the present invention may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided by the present invention may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.

[0181] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0182] The principles and implementation methods of the present invention are described in this article using specific examples. The description of the above embodiments is only used to help understand the method and core idea of ​​the present invention. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present invention.

Claims

1. A method for continuous adaptive transformation display of a screen, characterized in that: The continuous adaptive transformation display method of the screen includes: Acquire the initial rotation angle data of the device in space and the rotation angle data of several adjacent moments; the rotation angle data includes: alpha, beta and gamma, wherein alpha is the rotation angle of the device around the Z axis, beta is the rotation angle of the device around the X axis, and gamma is the rotation angle of the device around the Y axis; Calculating the angle difference between the rotation angle related data at each moment and the initial rotation angle related data respectively, and obtaining angle difference values ​​at several moments; Determine the rotation direction of the device based on the angle difference value at the current moment and the angle difference value at the previous moment; Determine the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments; The screen content is adjusted according to the display angle.

2. The method for continuous adaptive display transformation of a screen according to claim 1, characterized in that: The continuous adaptive display transformation method of the screen also includes: When the screen includes a UI control, determining whether the UI control rotates with the screen content; If not, keep the fixed position unchanged; If yes, the coordinates of the four corner points of the rotated UI control are determined by a geometric calculation method; Calculate the new position and boundary of the UI control according to the coordinates of the four corner points of the UI control; The UI control is adjusted according to the new position and the bounds.

3. The method for continuous adaptive display transformation of a screen according to claim 2, characterized in that: The continuous adaptive display transformation method of the screen also includes: Exception handling mechanism to ensure that the display of screen content and UI controls is always in a controllable state.

4. The method for continuous adaptive display transformation of a screen according to claim 1, characterized in that: The angle difference between the rotation angle related data at each moment and the initial rotation angle related data is calculated respectively to obtain angle difference values ​​at several moments, specifically including: Calculate the difference between the alpha value at each moment and the initial alpha value to get the alpha difference value; Adjust the alpha difference value to between -180 degrees and 180 degrees; Calculate the difference between the beta value at each moment and the initial beta value to obtain the beta difference value; Adjust the beta difference value to between -180 degrees and 180 degrees; Calculate the difference between the gamma value at each moment and the initial gamma value to obtain the gamma difference value; The gamma difference value is adjusted to between -90 degrees and 90 degrees.

5. The method for continuous adaptive display transformation of a screen according to claim 1, characterized in that: Determine the rotation direction of the device based on the angle difference value at the current moment and the angle difference value at the previous moment, including: When the alpha difference value at the current moment is greater than the alpha difference value at the previous moment, the device rotates clockwise and marks the rotation direction as positive; When the alpha difference value at the current moment is less than the alpha difference value at the previous moment, the device rotates counterclockwise and the rotation direction is marked as negative.

6. The method for continuous adaptive display transformation of a screen according to claim 1, characterized in that: Determine the display angle of the screen content according to the rotation direction and amplitude of the device, specifically including: Adjust the rotation angle to between -360 degrees and 360 degrees to obtain the adjusted rotation angle; According to the rotation direction, smoothing the adjusted rotation angle to obtain a smoothed angle; The angle after smoothing is used as the display angle of the screen content.

7. A display device for continuously adaptively changing a screen, characterized in that: The continuous adaptive transformation display device of the screen comprises: A rotation angle related data acquisition module, used to acquire the initial rotation angle related data of the device in space and the rotation angle related data of several adjacent moments; the rotation angle related data includes: alpha, beta and gamma, the alpha is the rotation angle of the device around the Z axis, the beta is the rotation angle of the device around the X axis, and the gamma is the rotation angle of the device around the Y axis; An angle difference calculation module, used to calculate the angle difference between the rotation angle related data at each moment and the initial rotation angle related data, and obtain angle difference values ​​at several moments; A rotation direction determination module, used to determine the rotation direction of the device based on the angle difference value at the current moment and the angle difference value at the previous moment; A display angle determination module, used to determine the display angle of the screen content according to the rotation direction and amplitude of the device; the amplitude is the change in the rotation angle between two adjacent moments; The screen content adjustment module is used to adjust the screen content according to the display angle.

8. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method for continuous adaptive transformation and display of a screen as described in any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for continuously adaptively transforming and displaying a screen as described in any one of claims 1 to 6 is implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method for continuously adaptively transforming and displaying a screen as described in any one of claims 1 to 6 is implemented.