Text display method and device, wearable equipment and storage medium
By adjusting the font size of the translated text on the wearable device to adapt to the original text box and adjusting it according to user needs, the reading difficulties caused by inflexible font adjustment in the prior art are solved, and a better text display effect is achieved.
Patent Information
- Application Number
- CN202311463175.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-03
- Publication Date
- 2025-05-06
AI Technical Summary
In the prior art, after text translation is realized through the optical character recognition function of the wearable device, it is usually impossible to flexibly adjust the font of the displayed translated text, resulting in dyslexia of the wearer.
By obtaining the text to be displayed, determine the way and display mode of its display position, including adjusting the font size to adapt to the original text box and adjusting it according to the user's vision, usage environment, and personal preferences.
It improves the display effect of the text to be displayed, allowing the wearer to accurately understand and apply the translated text, which is suitable for various usage situations and meets the needs of different users.
Smart Images

Figure CN119937770A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of wearable devices, and in particular to a text display method, a text display device, a wearable device, and a computer-readable storage medium. Background Art
[0002] Optical Character Recognition (OCR) refers to the process in which an electronic device (such as a scanner or digital camera) examines characters printed on paper, determines their shapes by detecting dark and light patterns, and then uses character recognition methods to translate the shapes into computer text. With the development of technology, optical character recognition functions can be implemented not only on mobile phones and tablets, but also on wearable devices such as smart glasses and smart helmets.
[0003] In the related art, the text recognition process of text translation can be realized through the optical character recognition function of the wearable device. Specifically, the wearable device can translate the text and then display the translated text for the wearer to understand and apply. However, in the related art, it is usually impossible to flexibly adjust the font of the displayed translated text. Therefore, the wearer may have difficulty reading due to the small font of the displayed translated text, and thus cannot accurately understand and apply the translated text. Summary of the invention
[0004] The present application provides a text display method, a text display device, a wearable device and a computer-readable storage medium, which aim to determine a display position determination method and a display mode of a text to be displayed, and then display the text to be displayed according to the display position determination method and the display mode, so as to improve the display effect of the text to be displayed.
[0005] To achieve the above object, the present application provides a text display method, which is applied to a wearable device, and the text display method includes:
[0006] Acquire text to be displayed, where the text to be displayed is obtained by recognizing text in a text image collected by the wearable device;
[0007] Performing an adjustment operation on the text to be displayed to obtain an adjusted text to be displayed;
[0008] Superimposing the adjusted text to be displayed on the text image and displaying it within the field of view of the wearable device;
[0009] Among them, the adjustment operation at least includes adjusting the font of the text to be displayed so that the font of the adjusted text to be displayed adapts to the original text box in the text image, scaling the text to be displayed according to the adjustment parameters, and adjusting the font of the text to be displayed so that the font of the adjusted text to be displayed can meet at least one of the user's eyesight, and / or usage environment, and / or personal preferences.
[0010] In addition, to achieve the above-mentioned purpose, the present application also provides a text display device, characterized in that the text display device comprises:
[0011] An acquisition module, used to acquire text to be displayed, wherein the text to be displayed is obtained by recognizing text in a text image collected by the wearable device;
[0012] A determination module, used to determine a display position determination method and a display mode of the text to be displayed, wherein the display position determination method includes a follow-up display method and an independent display method;
[0013] A display module is used to display the text to be displayed according to the display position determination method and the display mode.
[0014] In addition, to achieve the above-mentioned purpose, the present application also provides a wearable device, which includes a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program and implement the steps of any one of the text display methods provided in the embodiments of the present application when executing the computer program.
[0015] In addition, to achieve the above-mentioned purpose, the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the processor implements the steps of any one of the text display methods provided in the embodiments of the present application.
[0016] The text display method, text display device, wearable device and computer-readable storage medium disclosed in the embodiments of the present application can obtain the text to be displayed, which is obtained by identifying the text in the text image collected by the wearable device; further, the display position determination method and display mode of the text to be displayed can be determined, wherein the display position determination method includes a follow-up display mode and an independent display mode. Thus, the text to be displayed can be displayed according to the display position determination method and the display mode. The present application aims to determine the display position determination method and the display mode of the text to be displayed, and then display the text to be displayed according to the display position determination method and the display mode, so as to provide the user with a better text display experience, so that the wearer can accurately understand and apply the translated text. In addition, the text display method of the wearable device proposed in the present application is more suitable for various usage scenarios and meets the needs of different users. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0018] Figure 1 It is a flowchart of a text display method provided in an embodiment of the present application;
[0019] Figure 2 This is a schematic diagram of a first scenario of a text display method provided in an embodiment of the present application;
[0020] Figure 3 is a schematic diagram of a second scenario of a text display method provided in an embodiment of the present application;
[0021] Figure 4 is a schematic diagram of a third scenario of a text display method provided in an embodiment of the present application;
[0022] Figure 5 is a schematic diagram of a fourth scenario of a text display method provided in an embodiment of the present application;
[0023] Figure 6 is a schematic diagram of a fifth scenario of a text display method provided in an embodiment of the present application;
[0024] Figure 7 is a sixth scenario schematic diagram of a text display method provided in an embodiment of the present application;
[0025] Figure 8 is a seventh scenario schematic diagram of a text display method provided in an embodiment of the present application;
[0026] Fig. 9 This is a schematic diagram of an eighth scenario of a text display method provided in an embodiment of the present application;
[0027] Fig.10 is a schematic block diagram of a text display device provided in an embodiment of the present application;
[0028] Fig.11 It is a schematic block diagram of a wearable device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0029] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0030] The flowcharts shown in the accompanying drawings are only examples and do not necessarily include all the contents and operations / steps, nor do they have to be executed in the order described. For example, some operations / steps can also be decomposed, combined or partially merged, so the actual execution order may change according to actual conditions. In addition, although the functional modules are divided in the device schematic, in some cases, the module division can be different from that in the device schematic.
[0031] The term "and / or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0032] In conjunction with the accompanying drawings, some embodiments of the present application are described in detail below. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.
[0033] See also Figures 1 to 7 , Figure 1 It is a flowchart of a text display method provided in an embodiment of the present application; Figure 2 This is a schematic diagram of a first scenario of a text display method provided in an embodiment of the present application; Figure 3 is a schematic diagram of a second scenario of a text display method provided in an embodiment of the present application; Figure 4 is a schematic diagram of a third scenario of a text display method provided in an embodiment of the present application; Figure 5 is a schematic diagram of a fourth scenario of a text display method provided in an embodiment of the present application; Figure 6 is a schematic diagram of a fifth scenario of a text display method provided in an embodiment of the present application; Figure 7is a sixth scenario schematic diagram of a text display method provided in an embodiment of the present application; Figure 8 is a seventh scenario schematic diagram of a text display method provided in an embodiment of the present application; Fig. 9 8 is a schematic diagram of an eighth scenario of a text display method provided in an embodiment of the present application. Figure 1 As shown, the text display method includes steps S11 to S13.
[0034] Step S11: obtaining the text to be displayed, where the text to be displayed is obtained by recognizing the text in the text image collected by the wearable device.
[0035] Among them, the wearable device can be smart glasses, such as AR glasses, VR glasses, etc., which is not limited in this application.
[0036] Specifically, an image acquisition unit may be installed on the wearable device to acquire text images.
[0037] Among them, the image acquisition unit includes components such as a camera, a sensor, and a lens installed on the wearable device. These components work together to collect information such as images of the surrounding environment. This application and the type of camera are described as an RGB camera. An RGB camera is generally used to capture color images and can generate color images by simultaneously capturing information of the three color channels of red, green, and blue. Therefore, the RGB camera implements tasks such as collecting images or videos, image recognition, and processing in wearable devices.
[0038] Furthermore, after acquiring the text image, recognition tasks such as translation and analysis may be performed on the text in the text image to obtain the text to be displayed. This application is explained by taking the execution of the translation task as an example.
[0039] It should be noted that this application does not limit the way to translate text. For example, the wearable device can communicate with the cloud or other devices with translation functions (such as mobile phones, tablets or computers, etc.), and then the wearable device sends the text to the cloud or other devices with translation functions for text translation. Alternatively, optical character recognition technology and translation engines can be integrated on the wearable device to achieve instant local translation on the wearable device.
[0040] In an embodiment of the present application, a text image can be captured by an image capture unit of a wearable device, and then the text to be displayed obtained based on text recognition in the text image is obtained, so as to display the text to be displayed.
[0041] Step S12: Determine a display position determination method and a display mode of the text to be displayed, wherein the display position determination method includes a follow display method and an independent display method.
[0042] Step S13: Display the text to be displayed according to the display position determination method and the display mode.
[0043] It can be understood that the following display mode is that the text to be displayed is anchored on the text image, that is, no matter how the user moves, the text to be displayed and the text image are always displayed within the field of view of the wearable device, so that the user can always associate the text to be displayed with the text image, thereby facilitating the understanding and application of the text to be displayed.
[0044] The independent display mode is that the text to be displayed is not anchored on the text image, that is, no matter how the user moves, the text to be displayed is always displayed within the field of view of the wearable device, and the text image remains in the initial position. In this way, it can ensure that the user can see and apply the text to be displayed at any position.
[0045] Specifically, the display mode of the text to be displayed can be determined according to the layout type and application scenario of the text to be displayed, and the display position determination method of the text to be displayed can be determined according to the application scenario (this application will be described later). Thus, the text to be displayed can be displayed according to the display position determination method and the display mode to provide the user with a better text display experience, thereby enabling the wearer to accurately understand and apply the translated text.
[0046] It should be noted that the present application does not limit the display mode. For example, the display mode includes adjusting the font of the text to be displayed so that the adjusted font of the text to be displayed adapts to the original text box of the text in the text image, scaling the text to be displayed according to the adjustment parameters, and adjusting the font of the text to be displayed so that the adjusted font of the text to be displayed can meet the readability conditions, etc.
[0047] It should be noted that, for the font requirements of the above readability conditions, the font size can be set according to the user's own needs and is not limited here.
[0048] Furthermore, the original text box in the text image is a rectangle or a bounding box in the text image, which usually tightly surrounds the text in the text image.
[0049] It is understandable that in the related art, it is usually impossible to flexibly adjust the font of the text to be displayed, which may cause the wearer to have difficulty reading the text to be displayed because the font of the displayed translated text is small.
[0050] In view of this, the present application adjusts the font of the text to be displayed through a corresponding display mode to obtain the adjusted text to be displayed, and then the adjusted text to be displayed can be displayed according to the display position determination method.
[0051] For example, when the number of characters in the text to be displayed is less than the number of characters in the text image, the font of the text to be displayed can be directly enlarged and adjusted so that the adjusted text to be displayed can adapt to the original text box in the text image, that is, just surrounded by the original text box. Alternatively, the target text in the text to be displayed (which can be the text that the user needs to read) is determined and scaled as required. Alternatively, the font of the text to be displayed is directly adjusted so that the adjusted text to be displayed can meet the font requirements of the readability condition, that is, the adjusted text to be displayed is easy for the user to read and understand, thereby improving the user experience.
[0052] The detailed description of the above display modes can be found in the subsequent embodiments, and will not be described here to avoid repetition.
[0053] Optionally, the user can interact with the wearable device through gestures to adjust the font size and position of the text to be displayed. Alternatively, the wearable device can also track the target text corresponding to the focus point of the user's eyes in the text to be displayed through eye tracking technology, and then enlarge or reduce the target text according to the user's needs.
[0054] Optionally, the size of the original text box may also be adjusted according to user needs, which is not limited in this application.
[0055] Furthermore, after the adjusted text to be displayed is obtained, it can be displayed according to the display position determination method.
[0056] It should be noted that the text to be displayed can be partially or completely displayed within the field of view of the wearable device, and this application does not limit this. The field of view of the wearable device is the range or area of visual information that the user can see or perceive when wearing the wearable device, so that the user can read and apply the text to be displayed within the field of view.
[0057] Furthermore, when the text portion to be displayed is displayed within the field of view of the wearable device, the user can perform a page turning operation on the wearable device to read and apply the content of other text to be displayed.
[0058] In an embodiment of the present application, the display position determination method and display mode of the text to be displayed can be determined, and then the text to be displayed can be displayed according to the display position determination method and the display mode, so as to provide the user with a better text display experience, make the text display of the wearable device more suitable for various usage scenarios, and meet the needs of different users.
[0059] Optionally, the display position determination method is a follow display method, the display mode is a first display mode, and the text to be displayed is displayed according to the display position determination method and the display mode, including: obtaining the size of the original text box corresponding to the text in the text image; adjusting the font size of the text to be displayed according to the size, so that the adjusted text to be displayed adapts to the size of the original text box, and is anchored in the original text box for display.
[0060] Among them, the first display mode is to adjust the font of the text to be displayed so that the adjusted font of the text to be displayed adapts to the display mode of the original text box of the text in the text image; the following display mode is to anchor the text to be displayed on the text image.
[0061] like Figure 2 As shown, Figure 2 A scene in which the adjusted text to be displayed is adaptively adapted to the original text box in the text image and displayed. Specifically, the original text box of the text can be accurately located in the text image through text recognition or segmentation technology to determine the size of the original text box. Furthermore, the font size of the text to be displayed can be adjusted according to the size of the original text box to ensure that the adjusted text to be displayed matches the original text box, that is, the adjusted text to be displayed can fully adapt to the original text box. Finally, the adjusted text to be displayed can be anchored in the original text box for display, so that the user can associate the adjusted text to be displayed with the text image, and then accurately understand and apply the adjusted text to be displayed.
[0062] For example, for text images with a large layout area and relatively few words such as menus and flyers, the adjusted text to be displayed can be superimposed on the text image through the text display method of the original text box in the text image after the adjusted text to be displayed is adapted to provide users with a better text display experience.
[0063] Optionally, when the display mode is the second display mode, the text to be displayed is displayed according to the display position determination method and the display mode, including: obtaining the corresponding adjustment parameters in the second display mode, reducing or enlarging the text to be displayed according to the adjustment parameters, and obtaining the reduced or enlarged text to be displayed; and displaying the reduced or enlarged text to be displayed according to the display position determination method.
[0064] The second display mode is a display mode in which the text to be displayed is scaled according to the adjustment parameters.
[0065] Furthermore, the adjustment parameters are obtained by detecting the displacement of the wearable device or a physical device that is connected to the processor of the wearable device. For example, the user can move the head to cause the wearable device to displace, and then determine the adjustment parameters based on the correspondence between the displacement of the wearable device and the adjustment parameters. Alternatively, the adjustment parameters are directly determined by a physical device that is connected to the processor of the wearable device. The physical device includes a ring, a glasses leg, or a mobile phone, etc., which is not limited in this application.
[0066] Specifically, the physical device may be equipped with a sensor or a controller, which is then connected to the processor of the wearable device. The physical device can collect data through various sensors, and then transmit the data to the processor of the wearable device for analysis. As a result, the processor determines the adjustment parameters of the wearable device based on the data obtained by the sensor.
[0067] like Figures 3 to 5 As shown, Figure 3 The scenario of directly displaying the text to be displayed is shown; Figure 4 A scene in which the text to be displayed is reduced in size and displayed is shown; Figure 5 The scene of enlarging and displaying the text to be displayed is shown. Specifically, after the adjustment parameter is determined, the text to be displayed can be reduced or enlarged according to the adjustment parameter, and then the reduced or enlarged text to be displayed is displayed according to the display position determination method.
[0068] Among them, the display position determination method includes a follow-up display method and an independent display method, which is not limited in this application.
[0069] Optionally, a target text (e.g., a text that the user needs to read) in the text to be displayed can be determined. Then, the text to be displayed can be enlarged or reduced with the center of the field of view, so that the target text can be viewed within the field of view. For example, for texts to be displayed that have a single and regular layout and long paragraphs, such as books and papers, this method can be used to allow the user to read the paragraph of interest, that is, the target text, within the field of view, so as to provide the user with a better text display experience.
[0070] Optionally, for other content except the target text, the user can perform a page turning operation on the wearable device to read and apply the content of other text to be displayed.
[0071] Optionally, when the display mode is the third display mode, the text to be displayed is displayed according to the display position determination method and the display mode, including: obtaining the size of the original text box of the text in the text image; adjusting the font size of the text to be displayed according to the size, so that the adjusted size of the text to be displayed corresponds to the size of the original text box; determining whether to adjust the text to be displayed again according to the readability condition of the third display mode; if the adjusted text to be displayed does not meet the readability condition, adjusting the text to be displayed again so that the font size of the text to be displayed after the second adjustment meets the readability condition, and displaying the second adjusted text to be displayed according to the display position determination method.
[0072] The third display mode includes adjusting the font of the text to be displayed so that the adjusted font of the text to be displayed can meet the readability condition. Further, the readability condition includes the user's eyesight, and / or the use environment, and / or personal preference, etc., which are not limited in this application.
[0073] like Figure 6 as well as Figure 7 As shown, Figure 6 A scene showing that the adjusted size of the to-be-displayed text corresponds to the size of the original text box. Figure 7 A scenario in which the font size of the text to be displayed meets the font requirement of the readability condition, and the text to be displayed after the secondary adjustment is displayed.
[0074] Specifically, the original text box of the text can be accurately located in the text image through text recognition or segmentation technology to determine the size of the original text box. Further, the font size of the text to be displayed can be adjusted according to the size of the original text box to ensure that the text to be displayed matches the original text box, that is, the text to be displayed can completely fit into the original text box.
[0075] Furthermore, it can be determined whether the currently adjusted text to be displayed meets the user's vision, and / or usage environment, and / or personal preference (which can be set according to the specific needs of the user) based on the readability condition font requirements. If not, it is necessary to adjust the text to be displayed again so that the font size of the text to be displayed after the second adjustment meets the readability font requirements, and the second adjusted text to be displayed is displayed according to the display position determination method. Otherwise, no adjustment is required, and the text to be displayed after the first adjustment is directly displayed according to the display position determination method.
[0076] Among them, the display position determination method includes a follow-up display method and an independent display method, which is not limited in this application.
[0077] For example, the font size of the text on product packaging or business cards is relatively small, so the size of the corresponding original text box is also small. Therefore, the font of the text to be displayed can meet the font requirements of readability conditions such as the user's eyesight, and / or usage environment, and / or personal preferences, and the text to be displayed corresponding to the product packaging or business card can be matched with the original text box, and then the font size of the text to be displayed can be adjusted according to the needs so that it meets the font requirements, so as to provide users with a better text display experience.
[0078] On the basis of the above embodiment, determining whether to adjust the text to be displayed again is determined according to the readability condition of the third display mode, including: obtaining the first font size of the adjusted text to be displayed; comparing the first font size with the target font size of the readability condition, and deciding whether to adjust the text to be displayed again according to the comparison result.
[0079] Specifically, to determine whether the adjusted text to be displayed needs to be adjusted again, the font of the adjusted text to be displayed can be compared with the target font size of the readability condition. When the adjusted text to be displayed is larger than or equal to the target font size of the readability condition, it means that the adjusted text to be displayed is readable, that is, the text to be displayed does not need to be adjusted again. Otherwise, the text to be displayed needs to be adjusted again.
[0080] Optionally, determining the display position determination method and display mode of the text to be displayed includes: determining the layout type and application scenario corresponding to the text to be displayed, determining the display mode of the text to be displayed according to the layout type and application scenario, and determining the display position determination method of the text to be displayed according to the application scenario.
[0081] Among them, the layout type corresponding to the text to be displayed includes whether the layout area is larger or smaller, whether the text on the layout is larger or smaller, and whether the layout of the text in the text image is neat, etc. This application does not limit this.
[0082] Furthermore, the application scenarios include a scenario where the object corresponding to the to-be-displayed text is convenient to move, or a scenario where the object corresponding to the to-be-displayed text is inconvenient to move.
[0083] It should be noted that, for determining whether the area of the above-mentioned layout is larger or smaller, it can be compared with a preset threshold. That is, the preset threshold can be set to 5cm 2 , 10cm 2 etc., this application uses the preset threshold of 5cm 2 Take this as an example. If the area of the page corresponding to the text to be displayed is greater than or equal to 5cm 2 , it is determined that the area of the page corresponding to the text to be displayed is larger; if the area of the page occupied by the text is less than 5cm 2 , it is determined that the area of the layout corresponding to the text to be displayed is smaller.
[0084] Similarly, it is also possible to determine whether the text on the page corresponding to the text to be displayed is larger or smaller according to the above comparison method with the preset threshold. For example, if the font size of the text on the page corresponding to the text to be displayed is smaller than size 5, it can be determined that the text on the page corresponding to the text to be displayed is smaller; if the font size of the text on the page corresponding to the text to be displayed is greater than or equal to size 5, it can be determined that the text on the page corresponding to the text to be displayed is larger.
[0085] Specifically, the layout type and application scenario corresponding to the text to be displayed may be determined, and then the display mode of the text to be displayed may be determined according to the layout type and application scenario, and the display position determination method of the text to be displayed may be determined according to the application scenario.
[0086] Optionally, for the layout type of the text to be displayed with a large layout area, the display mode can be determined to be the first display mode, that is, the font size of the text to be displayed is adjusted according to the size of the original text box to ensure that the adjusted text to be displayed matches the original text box, that is, the adjusted text to be displayed can fully adapt to the original text box to provide users with a better text display experience.
[0087] For example, for menus, leaflets, etc., the corresponding layout type is a layout with a larger area. At this time, the display mode can be determined to be the first display mode to provide the user with a better text display experience.
[0088] Optionally, for the layout type of the text to be displayed where the text on the layout is small or the layout area is small, the display mode can be determined to be the third display mode, that is, the text to be displayed is matched with the original text box, and then the font size of the text to be displayed is adjusted according to demand so that it meets the font requirements of the readability condition, so as to provide users with a better text display experience.
[0089] For example, for the text on product packaging or business cards, the corresponding layout type is that the text on the layout is small and the layout area is small. Therefore, the display mode can be determined to be the third display mode, and the text to be displayed corresponding to the product packaging or business card is matched with the original text box, and then the font size of the text to be displayed is adjusted according to the demand so that it meets the font requirements of the readability condition, so as to provide users with a better text display experience.
[0090] Optionally, for the layout type of the text to be displayed that is, the text in the text image is neatly arranged, the display mode can be determined to be the second display mode, that is, the text to be displayed is reduced or enlarged according to the adjustment parameters to obtain the reduced or enlarged text to be displayed, and then the reduced or enlarged text to be displayed is displayed to provide the user with a better text display experience.
[0091] For example, for materials with neat layout and long paragraphs such as books and papers, the corresponding layout type is the neat layout of text in the text image, so the display mode can be determined to be the second display mode to provide users with a better text display experience.
[0092] Optionally, if the application scenario of the text to be displayed is a scenario where the object corresponding to the text to be displayed is inconvenient to move (for example, the object corresponding to the text to be displayed is a train timetable, a billboard, etc.), then the corresponding display position determination method can be determined as an independent display method. In this way, the independence and flexibility of the adjusted text to be displayed can be maintained, so that the user is not restricted to a specific viewing angle or position, and can more conveniently read and apply the adjusted text to be displayed.
[0093] Optionally, if the application scenario of the text to be displayed is a scenario where the object corresponding to the text to be displayed is easy to move (such as the object corresponding to the text to be displayed is a text material, or other irregular object that is easy to move), the corresponding display position determination method can be determined as a follow-up display method. Thus, no matter how the user moves, the text in the text image can always be associated with the adjusted text to be displayed, so as to understand and apply the text to be displayed.
[0094] In the embodiment of the present application, the layout type and application scenario corresponding to the text to be displayed can be determined, the display mode of the text to be displayed can be determined according to the layout type and application scenario, and the display position determination method of the text to be displayed can be determined according to the application scenario. Thus, the text display method proposed in the present application can be more suitable for various usage scenarios and meet the needs of different users.
[0095] The text display method disclosed in the embodiment of the present application can obtain the text to be displayed, and the text to be displayed is obtained by identifying the text in the text image collected by the wearable device; further, the display position determination method and display mode of the text to be displayed can be determined, wherein the display position determination method includes a follow-up display mode and an independent display mode. Thus, the text to be displayed can be displayed according to the display position determination method and the display mode. The present application aims to determine the display position determination method and the display mode of the text to be displayed, and then display the text to be displayed according to the display position determination method and the display mode, so as to provide the user with a better text display experience, so that the wearer can accurately understand and apply the translated text. In addition, the text display method for wearable devices proposed in the present application is more suitable for various usage scenarios and meets the needs of different users.
[0096] See also Fig.10 , Fig.10 1 is a schematic block diagram of a text display device provided in an embodiment of the present application. The text display device can be configured in a server to execute the aforementioned text display method.
[0097] like Fig.10 As shown, the text display device 200 includes: an acquisition module 201 , a determination module 202 , and a display module 203 .
[0098] An acquisition module 201 is used to acquire text to be displayed, where the text to be displayed is obtained by recognizing text in a text image collected by a wearable device;
[0099] A determination module 202, used to determine a display position determination method and a display mode of the text to be displayed, wherein the display position determination method includes a follow display method and an independent display method;
[0100] The display module 203 is used to display the text to be displayed according to the display position determination method and the display mode.
[0101] The display module 203 is also used to obtain the size of the original text box corresponding to the text in the text image; adjust the font size of the text to be displayed according to the size, so that the adjusted text to be displayed adapts to the size of the original text box and is anchored in the original text box for display.
[0102] The display module 203 is also used to obtain the corresponding adjustment parameters in the second display mode, reduce or enlarge the text to be displayed according to the adjustment parameters to obtain the reduced or enlarged text to be displayed; and display the reduced or enlarged text to be displayed according to the display position determination method.
[0103] The display module 203 is also used to obtain the size of the original text box of the text in the text image; adjust the font size of the text to be displayed according to the size, so that the adjusted size of the text to be displayed corresponds to the size of the original text box; determine whether to adjust the text to be displayed again according to the readability condition of the third display mode; if the adjusted text to be displayed does not meet the readability condition, adjust the text to be displayed again, so that the font size of the text to be displayed after the second adjustment meets the readability condition, and display the text to be displayed after the second adjustment according to the display position determination method.
[0104] The display module 203 is further used to obtain the adjusted first font size of the text to be displayed; compare the first font size with the target font size of the readability condition, and decide whether to adjust the text to be displayed again according to the comparison result.
[0105] The determination module 202 is further used to determine the layout type and application scenario corresponding to the text to be displayed, determine the display mode of the text to be displayed according to the layout type and application scenario, and determine the display position determination method of the text to be displayed according to the application scenario.
[0106] It should be noted that those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules and units can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0107] The method of the present application can be used in many general or special computing system environments or configurations, such as personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer terminal devices, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices.
[0108] Exemplarily, the above method and apparatus may be implemented in the form of a computer program. The computer program may be implemented in the form of a computer program. Fig.11 The wearable device shown is running on the
[0109] The wearable device 400 includes a processor 401, a memory 402, an image acquisition module 403 and a network interface connected via a system bus, wherein the memory 402 may include a volatile storage medium, a non-volatile storage medium and an internal memory.
[0111] The non-volatile storage medium can store an operating system and a computer program. The computer program includes program instructions, and when the program instructions are executed, the processor 401 can execute any text display method.
[0112] The processor 401 is used to provide computing and control capabilities to support the operation of the entire wearable device 400 .
[0113] The internal memory provides an environment for the operation of the computer program in the non-volatile storage medium. When the computer program is executed by the processor, the processor can execute any text display method.
[0114] The network interface is used for network communication, such as sending assigned tasks, etc. Those skilled in the art can understand that the structure of the wearable device is only a block diagram of a part of the structure related to the present application scheme, and does not constitute a limitation on the wearable device 400 to which the present application scheme is applied. The specific wearable device 400 may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0115] It should be understood that the processor 401 may be a central processing unit (CPU), and the processor 401 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0116] Among them, in some embodiments, the processor 401 is used to run a computer program stored in a memory to implement the following steps: obtain the text to be displayed, and the text to be displayed is obtained by identifying the text in the text image collected by the wearable device; determine the display position determination method and display mode of the text to be displayed, wherein the display position determination method includes a follow display mode and an independent display mode; display the text to be displayed according to the display position determination method and the display mode.
[0117] In some embodiments, the processor 401 is also used to obtain the size of the original text box corresponding to the text in the text image; adjust the font size of the text to be displayed according to the size, so that the adjusted text to be displayed adapts to the size of the original text box and is anchored in the original text box for display.
[0118] In some embodiments, the processor 401 is also used to obtain the corresponding adjustment parameters in the second display mode, reduce or enlarge the text to be displayed according to the adjustment parameters to obtain the reduced or enlarged text to be displayed; and display the reduced or enlarged text to be displayed according to the display position determination method.
[0119] In some embodiments, the processor 401 is also used to obtain the size of the original text box of the text in the text image; adjust the font size of the text to be displayed according to the size so that the adjusted size of the text to be displayed corresponds to the size of the original text box; determine whether to adjust the text to be displayed again according to the readability condition of the third display mode; if the adjusted text to be displayed does not meet the readability condition, adjust the text to be displayed again so that the font size of the text to be displayed after the second adjustment meets the readability condition, and display the text to be displayed after the second adjustment according to the display position determination method.
[0120] In some embodiments, the processor 401 is further used to obtain the adjusted first font size of the text to be displayed; compare the first font size with the target font size of the readability condition, and decide whether to adjust the text to be displayed again based on the comparison result.
[0121] In some embodiments, the processor 401 is also used to determine the layout type and application scenario corresponding to the text to be displayed, determine the display mode of the text to be displayed according to the layout type and application scenario, and determine the display position determination method of the text to be displayed according to the application scenario.
[0122] An embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. The computer program includes program instructions, and when the program instructions are executed, any one of the text display methods provided in the embodiments of the present application is implemented.
[0123] The computer-readable storage medium may be an internal storage unit of the wearable device described in the foregoing embodiment, such as a hard disk or memory of the wearable device. The computer-readable storage medium may also be an external storage device of the wearable device, such as a plug-in hard disk, a smart memory card (SmartMedia Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc., equipped on the wearable device.
[0124] Furthermore, the computer-readable storage medium may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function, and the like.
[0125] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A text display method, characterized in that: Applied to a wearable device, the text display method includes: Acquire text to be displayed, where the text to be displayed is obtained by recognizing text in a text image collected by the wearable device; Determine a display position determination method and a display mode of the text to be displayed, wherein the display position determination method includes a follow display method and an independent display method; The text to be displayed is displayed according to the display position determination method and the display mode.
2. The method according to claim 1, characterized in that When the display position determination method is a follow-up display method, and the display mode is a first display mode, the follow-up display method is that the text to be displayed is anchored on the text image for display, and the displaying of the text to be displayed according to the display position determination method and the display mode includes: Obtain the size of the original text box corresponding to the text in the text image; The font size of the text to be displayed is adjusted according to the size, so that the adjusted text to be displayed adapts to the size of the original text box and is anchored in the original text box for display.
3. The method according to claim 1, characterized in that When the display mode is the second display mode, displaying the to-be-displayed text according to the display position determination method and the display mode includes: Acquire an adjustment parameter corresponding to the second display mode, and reduce or enlarge the text to be displayed according to the adjustment parameter to obtain the reduced or enlarged text to be displayed; The reduced or enlarged text to be displayed is displayed according to the display position determination method.
4. The method according to claim 3, characterized in that The adjustment parameter is obtained by detecting the displacement of the wearable device or a physical device that is communicatively connected to a processor of the wearable device.
5. The method according to claim 1, characterized in that When the display mode is the third display mode, displaying the to-be-displayed text according to the display position determination method and the display mode includes: Obtaining the size of the original text box of the text in the text image; Adjusting the font size of the text to be displayed according to the size, so that the adjusted size of the text to be displayed corresponds to the size of the original text box; determining whether to adjust the to-be-displayed text again according to the readability condition of the third display mode; If the adjusted text to be displayed does not meet the readability condition, the text to be displayed is adjusted again so that the font size of the second-adjusted text to be displayed meets the readability condition, and the second-adjusted text to be displayed is displayed according to the display position determination method.
6. The method according to claim 5, characterized in that The determining whether to adjust the to-be-displayed text again according to the readability condition of the third display mode includes: Obtaining the adjusted first font size of the text to be displayed; The first font size is compared with the target font size of the readability condition, and it is determined whether to adjust the to-be-displayed text again according to the comparison result.
7. The method according to claim 1, characterized in that Determining a display position determination method and a display mode of the text to be displayed includes: Determine the layout type and application scenario corresponding to the text to be displayed, determine the display mode of the text to be displayed according to the layout type and application scenario, and determine the display position determination method of the text to be displayed according to the application scenario.
8. A text display device, characterized in that: The text display device comprises: An acquisition module, used to acquire text to be displayed, wherein the text to be displayed is obtained by recognizing text in a text image collected by the wearable device; A determination module, used to determine a display position determination method and a display mode of the text to be displayed, wherein the display position determination method includes a follow-up display method and an independent display method; A display module is used to display the text to be displayed according to the display position determination method and the display mode.
9. A wearable device, characterized in that: It comprises a memory and a processor; wherein the memory is connected to the processor and is used to store a program; the processor is used to implement the steps of the text display method as described in any one of claims 1 to 7 by running the program stored in the memory.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor implements the steps of the text display method according to any one of claims 1 to 7.