WO2022111663A1 - 视力检测方法及电子设备 - Google Patents

视力检测方法及电子设备 Download PDF

Info

Publication number
WO2022111663A1
WO2022111663A1 PCT/CN2021/133754 CN2021133754W WO2022111663A1 WO 2022111663 A1 WO2022111663 A1 WO 2022111663A1 CN 2021133754 W CN2021133754 W CN 2021133754W WO 2022111663 A1 WO2022111663 A1 WO 2022111663A1
Authority
WO
WIPO (PCT)
Prior art keywords
electronic device
user
target user
image
height
Prior art date
Application number
PCT/CN2021/133754
Other languages
English (en)
French (fr)
Inventor
刘小蒙
陈霄汉
姜永航
马春晖
黄磊
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2022111663A1 publication Critical patent/WO2022111663A1/zh

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B3/00Apparatus for testing the eyes; Instruments for examining the eyes
    • A61B3/02Subjective types, i.e. testing apparatus requiring the active assistance of the patient
    • A61B3/028Subjective types, i.e. testing apparatus requiring the active assistance of the patient for testing visual acuity; for determination of refraction, e.g. phoropters
    • A61B3/032Devices for presenting test symbols or characters, e.g. test chart projectors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/20Movements or behaviour, e.g. gesture recognition
    • GPHYSICS
    • G08SIGNALLING
    • G08BSIGNALLING OR CALLING SYSTEMS; ORDER TELEGRAPHS; ALARM SYSTEMS
    • G08B21/00Alarms responsive to a single specified undesired or abnormal condition and not otherwise provided for
    • G08B21/18Status alarms
    • G08B21/24Reminder alarms, e.g. anti-loss alarms

Definitions

  • the present application relates to the technical field of vision detection, and in particular, to a vision detection method and an electronic device.
  • the current visual acuity detection method is mainly eye chart identification, which has high requirements on testing environments such as lighting, distance, and user posture. Users can make eye chart identification led by professionals in professional places such as hospitals and optician centers, but it is very inconvenient for users. Users can also identify the visual acuity chart by themselves through the vision testing device, but the current vision testing device does not fully consider the impact of the testing environment on the vision testing results, resulting in inaccurate vision testing results. Therefore, how to allow users to easily and conveniently obtain high-precision vision detection results is a problem being studied by those skilled in the art.
  • the embodiments of the present application disclose a vision detection method and an electronic device, which can allow a user to perform a vision detection process simply and conveniently, and obtain a vision detection result with high accuracy.
  • an embodiment of the present application provides a vision detection method, which is applied to an electronic device.
  • the method includes: displaying a first character; acquiring a first image, where the first image includes a target user; The posture of the target user and the identification result of the target user for the first character obtain a first detection result, and the first detection result represents the vision level of the target user.
  • the electronic device may determine the first detection result representing the vision level according to the posture of the target user, fully considering the influence of the user's posture on the vision detection process.
  • Target users can directly obtain high-precision vision detection results through electronic devices, without having to go to a specific place to cooperate with professionals for vision detection, which is more convenient and practical, and has a better user experience.
  • the method before obtaining the first image, further includes: obtaining a second image, where the second image includes the target user; determining the posture and preset posture of the target user in the second image different; output prompt information, the prompt information is used to prompt the target user to adjust the posture, and the posture of the target user in the first image is the preset posture; or, adjust the display mode of the first character, and the display mode includes the following One or more: Display position, size, color, thickness, tilt angle.
  • the electronic device may first determine the posture of the target user. When the gesture of the target user is not the preset gesture, the user is prompted to adjust, or the display mode of the first character is adjusted. Then, the electronic device reacquires the identification result of the first image and the first character, and obtains the first detection result, which further avoids the influence of incorrect user posture on the first detection result, and improves the accuracy of the first detection result.
  • the above-mentioned determining that the posture of the target user in the second image is different from the preset posture includes: determining that the position of the target user in the second image is different from the preset position; the prompt information Specifically, it is used to prompt the target user to adjust the position, and the position of the target user in the first image is the preset position.
  • the electronic device can adjust the display methods such as the size and position of the first character according to the real-time position of the target user. Even if the target user moves around, the same first character seen by the target user is relatively consistent, thereby avoiding The error caused by the user's walking improves the accuracy of the first detection result.
  • the above-mentioned determining that the posture of the target user in the second image is different from the preset posture includes: determining that the angle at which the head of the target user is distorted in the second image is greater than or equal to a preset angle;
  • the above prompt information is specifically used to prompt the target user to adjust the angle of the head distortion, and the angle of the head distortion of the target user in the first image is smaller than the preset angle.
  • the above-mentioned determining that the posture of the target user in the second image is different from the preset posture includes: determining that the width of the eyes of the target user in the second image is smaller than a preset width; the prompt information specifically It is used to prompt the target user to open their eyes, and the width of the target user's eyes in the first image is greater than or equal to the preset width.
  • the electronic device can determine whether the user's posture (such as the angle of the head distorted, the width of the eyes, etc.) meets the requirements according to the image information of the target user acquired in real time. If the user's posture does not meet the requirements, the electronic device can prompt the user to adjust, or adjust the display mode of the first character, thereby avoiding errors caused by incorrect user posture and improving the accuracy of the first detection result.
  • the user's posture such as the angle of the head distorted, the width of the eyes, etc.
  • determining that the posture of the target user in the second image is different from the preset posture includes: determining that the absolute value of the difference between the first height and the second height is greater than or equal to the preset height,
  • the above-mentioned first height is the height of the eyes of the above-mentioned target user from the ground in the above-mentioned second image
  • the above-mentioned second height is the height of the display position of the above-mentioned first character from the ground
  • the above-mentioned prompt information is specifically used to prompt the above-mentioned target user to adjust the location of the height, the absolute value of the difference between the second height and the third height is less than the preset height
  • the third height is the height of the target user's eyes from the ground in the first image.
  • the electronic device may prompt the user to adjust the user's height or adjust the display position of the first character, thereby avoiding the inconsistency of heights. error, and improve the accuracy of the first detection result.
  • the first detection result specifically represents the vision level of the second eye.
  • the electronic device can automatically identify the eyes actually blocked by the user, thereby automatically determining the user's eyes corresponding to the obtained first detection result, without the need for manual selection by the user, and it is more convenient to use.
  • the above-mentioned displaying the first character includes: displaying a preset number of detection areas, the above-mentioned first character is displayed in the above-mentioned detection area, the above-mentioned preset number is the number of the above-mentioned target users, and one of the above-mentioned detection areas
  • the area is used for vision detection of one of the above-mentioned target users, the above-mentioned first character in the first area and the above-mentioned first character in the second area are the same or different, and the above-mentioned first area and the above-mentioned second area are the above-mentioned preset number of detections Any two of the regions.
  • the electronic device can perform vision detection on multiple people at the same time, which improves the efficiency of vision detection and makes it more convenient for users to use.
  • an embodiment of the present application provides an electronic device, the electronic device includes at least one memory and at least one processor, the at least one memory is coupled to the at least one processor, and the at least one memory is used to store a computer program, The at least one processor is used to call the computer program, and the computer program includes instructions, and when the instructions are executed by the at least one processor, the electronic device executes: displays a first character; and acquires a first image, where the first image includes The target user; obtains a first detection result according to the posture of the target user in the first image and the identification result of the target user on the first character, and the first detection result represents the vision level of the target user.
  • the electronic device may determine the first detection result representing the vision level according to the posture of the target user, fully considering the influence of the user's posture on the vision detection process.
  • Target users can directly obtain high-precision vision detection results through electronic devices, without having to go to a specific place to cooperate with professionals for vision detection, which is more convenient and practical, and has a better user experience.
  • the electronic device before obtaining the first image, is further configured to: obtain a second image, where the second image includes the target user; determine the posture of the target user in the second image and The preset postures are different; prompt information is output, and the prompt information is used to prompt the target user to adjust the posture, and the posture of the target user in the first image is the preset posture; or, the display mode of the first character is adjusted, and the display
  • the method includes one or more of the following: display position, size, color, thickness, tilt angle.
  • the electronic device may first determine the posture of the target user. When the gesture of the target user is not the preset gesture, the user is prompted to adjust, or the display mode of the first character is adjusted. Then, the electronic device reacquires the identification result of the first image and the first character, and obtains the first detection result, which further avoids the influence of incorrect user posture on the first detection result, and improves the accuracy of the first detection result.
  • the electronic device when it is determined that the posture of the target user in the second image is different from the preset posture, the electronic device specifically performs: determining the position and the preset position of the target user in the second image
  • the prompt information is specifically used to prompt the target user to adjust the position, and the position of the target user in the first image is the preset position.
  • the electronic device can adjust the display methods such as the size and position of the first character according to the real-time position of the target user. Even if the target user moves around, the same first character seen by the target user is relatively consistent, thereby avoiding The error caused by the user's walking improves the accuracy of the first detection result.
  • the electronic device when it is determined that the posture of the target user in the second image is different from the preset posture, the electronic device specifically performs: determining that the angle of the head of the target user in the second image is distorted greater than or is equal to the preset angle; the prompt information is specifically used to prompt the target user to adjust the angle of the head distortion, and the angle of the head distortion of the target user in the first image is smaller than the preset angle.
  • the electronic device when it is determined that the posture of the target user in the second image is different from the preset posture, the electronic device specifically performs: determining that the width of the eyes of the target user in the second image is smaller than the preset width
  • the above-mentioned prompt information is specifically used to prompt the above-mentioned target user to open his eyes, and the width of the above-mentioned target user's eyes in the above-mentioned first image is greater than or equal to the above-mentioned preset width.
  • the electronic device can determine whether the user's posture (such as the angle of the head distorted, the width of the eyes, etc.) meets the requirements according to the image information of the target user acquired in real time. If the user's posture does not meet the requirements, the electronic device can prompt the user to adjust, or adjust the display mode of the first character, thereby avoiding errors caused by incorrect user posture and improving the accuracy of the first detection result.
  • the user's posture such as the angle of the head distorted, the width of the eyes, etc.
  • the electronic device when it is determined that the posture of the target user in the second image is different from the preset posture, the electronic device specifically performs: determining that the absolute value of the difference between the first height and the second height is greater than or is equal to the preset height, the first height is the height of the eyes of the target user from the ground in the second image, and the second height is the height of the display position of the first character from the ground; the prompt information is specifically used to prompt the above
  • the target user adjusts the height, the absolute value of the difference between the second height and the third height is less than the preset height, and the third height is the height of the target user's eyes from the ground in the first image.
  • the electronic device may prompt the user to adjust the user's height or adjust the display position of the first character, thereby avoiding the inconsistency of heights. error, and improve the accuracy of the first detection result.
  • the electronic device includes a display screen and a lifting device, and the display screen is used to display the first character; when adjusting the display mode of the first character, the electronic device specifically performs: through the lifting and lowering The device adjusts the height of the above-mentioned display screen from the ground.
  • the electronic device when the height of the target user's eyes is inconsistent with the height of the first character displayed by the electronic device, the electronic device can automatically adjust the height of the display screen through the lifting device, thereby adjusting the height of the target user's eyes.
  • the adjustable height is more flexible, and there is no need for users to adjust their own heights, which is more convenient for users to use and has a better experience.
  • the first detection result specifically represents the vision level of the second eye.
  • the electronic device can automatically identify the eyes actually blocked by the user, thereby automatically determining the user's eyes corresponding to the obtained first detection result, without the need for manual selection by the user, and it is more convenient to use.
  • the above-mentioned displaying the first character includes: displaying a preset number of detection areas, the above-mentioned first character is displayed in the above-mentioned detection area, the above-mentioned preset number is the number of the above-mentioned target users, and one of the above-mentioned detection areas
  • the area is used for vision detection of one of the above-mentioned target users, the above-mentioned first character in the first area and the above-mentioned first character in the second area are the same or different, and the above-mentioned first area and the above-mentioned second area are the above-mentioned preset number of detections Any two of the regions.
  • the electronic device can perform vision detection on multiple people at the same time, which improves the efficiency of vision detection and makes it more convenient for users to use.
  • the embodiments of the present application provide a computer storage medium, including computer instructions, when the computer instructions are executed on an electronic device, the electronic device is made to execute any one of the first aspect and the first aspect in the embodiments of the present application.
  • a vision detection method provided by an implementation.
  • the embodiments of the present application provide a computer program product that, when the computer program product runs on an electronic device, enables the electronic device to perform any one of the first aspect and the first aspect in the embodiments of the present application.
  • the method of vision detection provided by the method.
  • an embodiment of the present application provides a chip, where the chip includes at least one processor, an interface circuit, and a memory, the memory, the interface circuit, and the at least one processor are interconnected through a line, and a computer program is stored in the memory , when the above-mentioned computer program is executed by the above-mentioned at least one processor, the vision detection method provided by the first aspect and any one of the implementation manners of the first aspect in the embodiments of the present application is implemented.
  • the computer storage medium provided in the third aspect, the computer program product provided in the fourth aspect, and the chip provided in the fifth aspect are all used to perform the vision detection provided by the first aspect and any implementation manner of the first aspect. method. Therefore, for the beneficial effects that can be achieved, reference may be made to the beneficial effects in the vision detection method provided in the first aspect, and details are not repeated here.
  • FIGS. 1A-1B are schematic diagrams of some vision detection scenarios provided by embodiments of the present application.
  • FIG. 2 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of another electronic device provided by an embodiment of the present application.
  • FIG. 4A-FIG. 4F, FIG. 5A-FIG. 5F, FIG. 6A-FIG. 6C, FIG. 7A-FIG. 7C, FIG. 8A-FIG. 8D are schematic diagrams of embodiments of some vision detection scenarios provided by embodiments of the present application;
  • 9 to 14 are schematic flowcharts of some vision detection methods provided by embodiments of the present application.
  • FIG. 1A is a schematic diagram of a vision detection scene provided by an embodiment of the present application.
  • the user can perform eye chart identification through the electronic device 100 .
  • the electronic device 100 displays a user interface 110 , and the user interface 110 includes a plurality of eye chart symbols, wherein the eye chart symbols 111 are circled in the user interface 110 for instructing the user to judge the eye chart symbols 111 .
  • the electronic device 100 may acquire the user's judgment result, and determine the next circled eye chart symbol according to the judgment result. If the judgment result is correct, the next circled eye chart symbol may be the same size as the eye chart symbol 111 , or may be smaller than the eye chart symbol 111 . If the judgment result is an incorrect result, the next circled eye chart symbol may be the same size as the eye chart symbol 111 , or may be larger than the eye chart symbol 111 .
  • the electronic device 100 may acquire the user's gesture through the camera, and obtain the user's judgment result according to the user's gesture. For example, when the user's gesture is to make a fist and the index finger is upward, the electronic device 100 determines that the user judges that the eye chart symbol is pointing upward, and the user's judgment result is consistent with the direction of the eye chart symbol 111 in the user interface 110, so the user's judgment result is correct result.
  • the electronic device determines that the user judges that the eye chart symbol is pointing to the left, and the user's judgment result is inconsistent with the direction of the eye chart symbol 111 in the user interface 110, so the user's judgment result is an incorrect result. .
  • the electronic device 100 may also acquire the motion trajectory of the user's arm through the camera, and obtain the user's judgment result according to the motion trajectory of the user's arm. For example, when the movement trajectory of the user's arm is bottom-up, the electronic device 100 determines that the user judges that the eye chart symbol is pointing upward, and the user's judgment result is consistent with the direction of the eye chart symbol 111 in the user interface 110. Therefore, the user's judgment The result is the correct result. When the movement trajectory of the user's arm is from top to bottom, the electronic device 100 determines that the user judges that the eye chart symbol is pointing downward, and the user's judgment result is inconsistent with the direction of the eye chart symbol 111 in the user interface 110. Therefore, the user's judgment result is: wrong result.
  • the electronic device 100 may also acquire the user's voice information through a microphone, and obtain the user's judgment result according to the user's voice information. For example, when the user's voice information includes words such as "up”, “up,” and "upper side", the electronic device 100 determines that the user judges that the eye chart symbol is pointing upward, and the user's judgment result is the same as that of the eye chart symbol 111 in the user interface 110. The directions are consistent, so the user's judgment result is the correct result.
  • the electronic device 100 determines that the user judges that the direction of the eye chart symbol is to the right, and the user's judgment The result is inconsistent with the direction of the eye chart symbol 111 in the user interface 110, so the user's judgment result is an incorrect result.
  • the electronic device 100 may also play voice information, where the voice information is used to instruct the user to judge the eye chart symbol 111 .
  • the electronic device 100 may also display only one eye chart symbol and prompt information on the user interface 110, where the prompt information is used to prompt the user to judge the currently displayed eye chart symbol.
  • FIG. 1B see FIG. 1B .
  • the electronic device 100 may display a user interface 120 , and the user interface 120 includes an eye chart symbol 121 and prompt information 122 .
  • the prompt information 122 is used to instruct the user to make a judgment on the eye chart symbol 121 .
  • the electronic device 100 may acquire the user's judgment result, determine the next displayed eye chart symbol according to the judgment result, and replace the eye chart symbol 121 with the eye chart symbol.
  • the description of the next displayed eye chart symbols is the same as that shown in FIG. 1A , and will not be repeated.
  • the electronic device 100 continuously obtains the user's judgment results for different vision chart symbols in the above-mentioned manner.
  • the visual acuity test result of one eye of the user may prompt the user to test the other eye.
  • the process of the user testing the other eye is similar to the above-mentioned process of testing one eye.
  • the electronic device 100 may obtain the visual acuity test results of the user's two eyes.
  • the embodiments of the present application do not limit the user interface displayed by the electronic device 100 during the vision detection process, the manner in which the electronic device 100 prompts the user to judge the symbols on the vision chart, and the manner in which the electronic device 100 obtains the user's judgment result.
  • the electronic devices involved in the embodiments of the present application may be large-screen devices such as smart screens and smart TVs, or may be mobile phones, tablet computers, desktop, laptop, and notebook computers, and Ultra-mobile Personal Computers (Ultra-mobile Personal Computers).
  • UMPC Ultra-mobile Personal Computers
  • handheld computers netbooks
  • personal digital assistants Personal Digital Assistant, PDA
  • wearable electronic devices and other devices.
  • FIG. 2 shows a schematic structural diagram of an electronic device 100 .
  • the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2 , mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, buttons 190, motor 191, indicator 192, camera 193, display screen 194, and Subscriber identification module (subscriber identification module, SIM) card interface 195 and so on.
  • SIM Subscriber identification module
  • the sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.
  • the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the electronic device 100 .
  • the electronic device 100 may include more or less components than shown, or combine some components, or separate some components, or arrange different components.
  • the illustrated components may be implemented in hardware, software, or a combination of software and hardware.
  • the processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (neural-network processing unit, NPU), etc. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processor
  • ISP image signal processor
  • controller video codec
  • digital signal processor digital signal processor
  • baseband processor baseband processor
  • neural-network processing unit neural-network processing unit
  • the controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
  • a memory may also be provided in the processor 110 for storing instructions and data.
  • the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the above-mentioned memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby increasing the efficiency of the system.
  • the processor 110 may include one or more interfaces.
  • the interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver (universal asynchronous transmitter) receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface, and / or universal serial bus (universal serial bus, USB) interface, etc.
  • I2C integrated circuit
  • I2S integrated circuit built-in audio
  • PCM pulse code modulation
  • PCM pulse code modulation
  • UART universal asynchronous transceiver
  • MIPI mobile industry processor interface
  • GPIO general-purpose input/output
  • SIM subscriber identity module
  • USB universal serial bus
  • the I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL).
  • the processor 110 may contain multiple sets of I2C buses.
  • the processor 110 can be respectively coupled to the touch sensor 180K, the charger, the flash, the camera 193 and the like through different I2C bus interfaces.
  • the processor 110 may couple the touch sensor 180K through the I2C interface, so that the processor 110 and the touch sensor 180K communicate with each other through the I2C bus interface, so as to realize the touch function of the electronic device 100 .
  • the I2S interface can be used for audio communication.
  • the processor 110 may contain multiple sets of I2S buses.
  • the processor 110 may be coupled with the audio module 170 through an I2S bus to implement communication between the processor 110 and the audio module 170 .
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface, so as to realize the function of answering calls through a Bluetooth headset.
  • the PCM interface can also be used for audio communications, sampling, quantizing and encoding analog signals.
  • the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface.
  • the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the above-mentioned I2S interface and the above-mentioned PCM interface can be used for audio communication.
  • the UART interface is a universal serial data bus used for asynchronous communication.
  • the bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication.
  • a UART interface is typically used to connect the processor 110 with the wireless communication module 160 .
  • the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function.
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
  • the MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 .
  • MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc.
  • the processor 110 communicates with the camera 193 through a CSI interface, so as to realize the photographing function of the electronic device 100 .
  • the processor 110 communicates with the display screen 194 through the DSI interface to implement the display function of the electronic device 100 .
  • the GPIO interface can be configured by software.
  • the GPIO interface can be configured as a control signal or as a data signal.
  • the GPIO interface may be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like.
  • the GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
  • the USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones.
  • the interface can also be used to connect other electronic devices, such as AR devices.
  • the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration, and does not constitute a structural limitation of the electronic device 100 .
  • the electronic device 100 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
  • the charging management module 140 is used to receive charging input from the charger.
  • the charger may be a wireless charger or a wired charger.
  • the charging management module 140 may receive charging input from the wired charger through the USB interface 130 .
  • the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100 . While the charging management module 140 charges the battery 142 , it can also supply power to the electronic device through the power management module 141 .
  • the power management module 141 is used for connecting the battery 142 , the charging management module 140 and the processor 110 .
  • the power management module 141 receives input from the battery 142 and/or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the display screen 194, the camera 193, and the wireless communication module 160.
  • the power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle times, battery health status (leakage, impedance).
  • the power management module 141 may also be provided in the processor 110 .
  • the power management module 141 and the charging management module 140 may also be provided in the same device.
  • the wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization.
  • the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
  • the mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 .
  • the mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like.
  • the mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation.
  • the mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and then turn it into an electromagnetic wave for radiation through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
  • the modem processor may include a modulator and a demodulator.
  • the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal.
  • the demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. Then the demodulator transmits the demodulated low-frequency baseband signal to the baseband processor for processing.
  • the low frequency baseband signal is processed by the baseband processor and passed to the application processor.
  • the application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 .
  • the modem processor may be a stand-alone device.
  • the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
  • the wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites Wireless communication solutions such as global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared technology (IR).
  • WLAN wireless local area networks
  • BT Bluetooth
  • GNSS global navigation satellite system
  • FM frequency modulation
  • NFC near field communication
  • IR infrared technology
  • the wireless communication module 160 may be one or more devices integrating at least one communication processing module.
  • the wireless communication module 160 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 .
  • the wireless communication module 160 can also receive the signal to be sent from the processor 110 , perform frequency modulation on it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2 .
  • the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology.
  • wireless communication technology can include global system for mobile communications (GSM), general packet radio service (general packet radio service, GPRS), code division multiple access (code division multiple access, CDMA), wideband code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and/or IR technology, etc.
  • the above-mentioned GNSS may include global positioning system (global positioning system, GPS), global navigation satellite system (global navigation satellite system, GLONASS), Beidou navigation satellite system (beidou navigation satellite system, BDS), quasi-zenith satellite system (quasi- zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
  • global positioning system global positioning system, GPS
  • global navigation satellite system global navigation satellite system
  • GLONASS global navigation satellite system
  • Beidou navigation satellite system beidou navigation satellite system, BDS
  • quasi-zenith satellite system quasi-zenith satellite system
  • QZSS quasi-zenith satellite system
  • SBAS satellite based augmentation systems
  • the electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like.
  • the GPU is a microprocessor for image processing, and is connected to the display screen 194 and the application processor.
  • the GPU is used to perform mathematical and geometric calculations for graphics rendering.
  • Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
  • Display screen 194 is used to display images, videos, and the like.
  • Display screen 194 includes a display panel.
  • the display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (active-matrix organic light).
  • LED diode AMOLED
  • flexible light-emitting diode flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on.
  • the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one.
  • the electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
  • the ISP is used to process the data fed back by the camera 193 .
  • the shutter is opened, the light is transmitted to the photosensitive element of the camera through the lens, the light signal is converted into an electrical signal, and the photosensitive element of the camera transmits the above-mentioned electrical signal to the ISP for processing, and converts it into an image visible to the naked eye.
  • ISP can also perform algorithm optimization on image noise, brightness, and skin tone. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene.
  • the ISP may be provided in the camera 193 .
  • Camera 193 is used to capture still images or video.
  • the object is projected through the lens to generate an optical image onto the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other formats of image signals.
  • the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
  • a digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy and so on.
  • Video codecs are used to compress or decompress digital video.
  • the electronic device 100 may support one or more video codecs.
  • the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
  • MPEG Moving Picture Experts Group
  • MPEG2 moving picture experts group
  • MPEG3 MPEG4
  • MPEG4 Moving Picture Experts Group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • the external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 .
  • the external memory card communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
  • the internal memory 121 may be used to store computer executable program code, which includes instructions.
  • the internal memory 121 may include a storage program area and a storage data area.
  • the storage program area can store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
  • the storage data area may store data (such as audio data, phone book, etc.) created during the use of the electronic device 100 and the like.
  • the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
  • the processor 110 executes various functional applications and data processing of the electronic device 100 by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor.
  • the electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
  • the audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
  • Speaker 170A also referred to as a "speaker" is used to convert audio electrical signals into sound signals.
  • the electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
  • the receiver 170B also referred to as "earpiece" is used to convert audio electrical signals into sound signals.
  • the voice can be answered by placing the receiver 170B close to the human ear.
  • the microphone 170C also called “microphone” or “microphone” is used to convert sound signals into electrical signals.
  • the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C.
  • the electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
  • the earphone jack 170D is used to connect wired earphones.
  • the earphone interface 170D can be the USB interface 130, or can be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
  • OMTP open mobile terminal platform
  • CTIA cellular telecommunications industry association of the USA
  • the electronic device 100 may display a user interface for vision detection through the display screen 194, and the user interface may include at least one vision chart symbol, optionally, the vision chart symbol used for user detection in the user interface It can be marked out, for example, the user interface 110 shown in FIG. 1A , the user interface 120 shown in FIG. 1B .
  • the electronic device 100 can display prompt information on the above-mentioned user interface, or the electronic device 100 can play the voice prompt information through the speaker 170A or the receiver 170B, so that the user can judge the visual chart symbols in the above-mentioned user interface. Then, the electronic device 100 can acquire the user's image information through the camera 193, and then obtain the user's judgment result according to the user's image information.
  • the image information of the user may include the user's gesture or the motion trajectory of the user's arm, and the electronic device 100 may obtain the user's judgment result according to the user's gesture or the motion trajectory of the user's arm.
  • the electronic device 100 may also acquire the user's voice information through the microphone 170C, and then obtain the user's judgment result according to the user's voice information.
  • the above-mentioned user's voice signal includes words indicating directions such as "up”, “down”, “left”, and "right”, and the electronic device 100 can obtain the user's judgment result on the direction of the eye chart symbols according to these words in the direction .
  • the electronic device 100 can determine the next eye chart symbol for the user's judgment according to the user's judgment result, and display the eye chart symbol on the display screen 194, optionally, the vision chart symbol.
  • the chart symbols are marked on the user interface displayed on the display screen 194 so that the user can continue to judge the eye chart symbols.
  • the electronic device 100 can continuously obtain the user's judgment results for different eye chart symbols according to the above process. When the number of judgment results is greater than the preset number, the electronic device 100 can obtain the visual acuity detection result of one eye of the user according to the plurality of judgment results. Then, the electronic device 100 can display prompt information on the user interface, or the electronic device 100 can play the voice prompt information through the speaker 170A or the receiver 170B to prompt the user to test the other eye. The specific test process is similar to the above-mentioned process. Finally, The electronic device 100 can obtain the vision detection results of the user's two eyes. The electronic device 100 may display the visual acuity detection result of the user's two eyes through the display screen 194, or may play the visual acuity detection result of the user's two eyes through the speaker 170A or the receiver 170B.
  • the electronic device 100 may store the above-mentioned visual acuity detection results of both eyes of the user, for example, store the above-mentioned visual acuity detection results in the internal memory 121 or an external memory card connected to the external memory interface 120 .
  • the electronic device 100 can send the above-mentioned vision detection result to a connected cloud server, and then obtain it from the cloud server when it needs to be used, thereby reducing the storage pressure of the electronic device 100 .
  • the user can obtain historical vision detection results through the electronic device 100, so as to judge the change trend of vision. Users do not need to spend a lot of time and energy on a regular basis to go to hospitals, optical centers and other professional places to perform the vision detection process. This helps the user to track the vision condition for a long time. When the vision deteriorates, the eye habits can be adjusted or the glasses can be replaced in time, so as to avoid the further deterioration of the vision.
  • the pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals.
  • the pressure sensor 180A may be provided on the display screen 194 .
  • the capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes.
  • the electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A.
  • the electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A.
  • touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
  • the gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 .
  • the angular velocity of electronic device 100 about three axes ie, x, y, and z axes
  • the gyro sensor 180B can be used for image stabilization.
  • the gyro sensor 180B detects the shaking angle of the electronic device 100, calculates the distance that the lens module needs to compensate according to the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse motion to achieve anti-shake.
  • the gyro sensor 180B can also be used for navigation and somatosensory game scenarios.
  • the air pressure sensor 180C is used to measure air pressure.
  • the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist in positioning and navigation.
  • the magnetic sensor 180D includes a Hall sensor.
  • the electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D.
  • the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
  • the acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).
  • the magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
  • Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes.
  • the light emitting diodes may be infrared light emitting diodes.
  • the electronic device 100 emits infrared light to the outside through the light emitting diode.
  • Electronic device 100 uses photodiodes to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100 . When insufficient reflected light is detected, the electronic device 100 may determine that there is no object near the electronic device 100 .
  • the electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power.
  • Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlock and lock screen.
  • the ambient light sensor 180L is used to sense ambient light brightness.
  • the electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness.
  • the ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures.
  • the ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket, so as to prevent accidental touch.
  • the fingerprint sensor 180H is used to collect fingerprints.
  • the electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
  • the temperature sensor 180J is used to detect the temperature.
  • the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold value, the electronic device 100 reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection.
  • the electronic device 100 when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 caused by the low temperature.
  • the electronic device 100 boosts the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
  • Touch sensor 180K also called “touch device”.
  • the touch sensor 180K may be disposed on the display screen 194 , and the touch sensor 180K and the display screen 194 form a touch screen, also called a “touch screen”.
  • the touch sensor 180K is used to detect a touch operation on or near it.
  • the touch sensor can pass the detected touch operation to the application processor to determine the type of touch event.
  • Visual output related to touch operations may be provided through display screen 194 .
  • the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
  • the bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human voice. The bone conduction sensor 180M can also contact the pulse of the human body and receive the blood pressure beating signal. In some embodiments, the bone conduction sensor 180M can also be disposed in the earphone, combined with the bone conduction earphone.
  • the audio module 170 can analyze the voice signal based on the vibration signal of the vibrational bone mass of the vocal part obtained by the above-mentioned bone conduction sensor 180M, so as to realize the voice function.
  • the application processor can analyze the heart rate information based on the blood pressure beat signal obtained by the above-mentioned bone conduction sensor 180M, and realize the function of heart rate detection.
  • the keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key.
  • the electronic device 100 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 100 .
  • the electronic device 100 may detect a user operation (such as a click operation) performed by the user on the display screen 194 through the pressure sensor 180A and/or the touch sensor 180K, and in response to the user operation, the electronic device 100 may start to perform vision detection process.
  • the electronic device 100 may detect a user operation (eg, a pressing operation) of the user acting on the key 190 through the pressure sensor 180A and/or the touch sensor 180K, and in response to the user operation, the electronic device 100 may start to perform a vision detection process.
  • the electronic device 100 may acquire the user's voice information (eg, "vision test") through the microphone 170C, and in response to the voice information, the electronic device 100 may start to perform a vision detection process.
  • voice information eg, "vision test”
  • the electronic device 100 may also prompt the user to perform a corresponding operation, and determine whether the current user is the target user according to the user operation, and the electronic device 100 needs to perform vision detection on the target user.
  • the electronic device 100 may prompt the user to perform a specific gesture (such as an OK gesture), and acquire the user's image information through the camera 193.
  • a specific gesture such as an OK gesture
  • the electronic device 100 determines that the current user is the target user, And perform vision detection for the current user.
  • the electronic device 100 may also prompt the user to click on a specific control displayed on the display screen 194, the electronic device 100 may detect the user's operation on the specific control through the pressure sensor 180A and/or the touch sensor 180K, and in response to the user operation, the electronic The device 100 determines that the current user is the target user, and performs vision detection for the current user.
  • This embodiment of the present application does not limit the manner of how to determine the target user. This embodiment of the present application does not limit the manner of determining how to start the vision detection process.
  • the electronic device 100 may continuously acquire the image information of the user during the vision detection process, and when the user included in the image information changes, that is, when the current user is not the target user, the electronic device 100 may prompt the user currently performing vision detection. The user is inconsistent with the previous one, and the current vision detection process is suspended. Within a preset period of time, if the image information of the user acquired by the electronic device 100 includes the target user, the electronic device 100 may continue to perform the above-mentioned vision detection process.
  • the electronic device 100 may directly end the current vision detection process, or the electronic device 100 may keep suspending the current vision detection process until the target user The next time the vision detection process is triggered, the electronic device 100 will continue to perform the above-mentioned vision detection process.
  • the electronic device 100 may detect a user operation for instructing restarting the vision detection process (eg, voice message: "Restart vision detection"), and in response to the user operation, the electronic device 100 may directly end the current vision inspection process and start over with a new vision inspection process.
  • a user operation for instructing restarting the vision detection process eg, voice message: "Restart vision detection
  • Motor 191 can generate vibrating cues.
  • the motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback.
  • touch operations acting on different applications can correspond to different vibration feedback effects.
  • the motor 191 can also correspond to different vibration feedback effects for touch operations on different areas of the display screen 194 .
  • Different application scenarios for example: time reminder, receiving information, alarm clock, games, etc.
  • the touch vibration feedback effect can also support customization.
  • the indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
  • the SIM card interface 195 is used to connect a SIM card.
  • the SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 .
  • the electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1.
  • the SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the above-mentioned multiple cards may be the same or different.
  • the SIM card interface 195 can also be compatible with different types of SIM cards.
  • the SIM card interface 195 is also compatible with external memory cards.
  • the electronic device 100 interacts with the network through the SIM card to implement functions such as call and data communication.
  • the electronic device 100 employs an eSIM, ie: an embedded SIM card.
  • the eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100 .
  • the software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture.
  • the software system of the layered architecture may be an Android (Android) system or a Huawei mobile services (huawei mobile services, HMS) system.
  • the embodiments of the present application take an Android system with a layered architecture as an example to exemplarily describe the software structure of the electronic device 100 .
  • FIG. 3 is a block diagram of a software structure of an electronic device 100 according to an embodiment of the present invention.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces.
  • the Android system is divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and a system library, and a kernel layer.
  • the application layer can include a series of application packages.
  • the application package can include applications such as camera, calendar, map, music, short message, gallery, call, navigation, bluetooth, vision detection and so on.
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions.
  • the application framework layer may include window managers, content providers, view systems, telephony managers, resource managers, notification managers, and the like.
  • a window manager is used to manage window programs.
  • the window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
  • Content providers are used to store and retrieve data and make these data accessible to applications.
  • the above data can include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
  • the view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications.
  • a display interface can consist of one or more views.
  • the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
  • the phone manager is used to provide the communication function of the electronic device 100 .
  • the management of call status including connecting, hanging up, etc.).
  • the resource manager provides various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
  • the notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc.
  • the notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications of applications running in the background, and notifications on the screen in the form of dialog windows. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
  • Android Runtime includes core libraries and a virtual machine. Android runtime is responsible for scheduling and management of the Android system.
  • the core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application layer and the application framework layer as binary files.
  • the virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
  • a system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), 3D graphics processing library (eg: OpenGL ES), 2D graphics engine (eg: SGL), etc.
  • surface manager surface manager
  • media library Media Libraries
  • 3D graphics processing library eg: OpenGL ES
  • 2D graphics engine eg: SGL
  • the Surface Manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
  • the media library supports playback and recording of a variety of commonly used audio and video formats, as well as still image files.
  • the media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
  • the 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
  • 2D graphics engine is a drawing engine for 2D drawing.
  • the kernel layer is the layer between hardware and software.
  • the kernel layer contains at least display drivers, camera drivers, audio drivers, and sensor drivers.
  • vision detection may not be an application package installed on the electronic device 100, but an online application, such as a web page application, a small program application, etc. This is not limited.
  • the following describes the workflow of the software and hardware of the electronic device 100 by way of example in conjunction with the vision detection scenario.
  • the visual acuity detection scene is described by taking the user's judgment process of a visual chart symbol as an example.
  • a corresponding hardware interrupt is sent to the kernel layer.
  • the kernel layer processes touch operations into raw input events (including touch coordinates, timestamps of touch operations, etc.). Raw input events are stored at the kernel layer.
  • the application framework layer obtains the original input event from the kernel layer, and identifies the control corresponding to the input event. Take the touch operation as a touch click operation, and the control corresponding to the click operation is the icon control of the vision detection application as an example, the vision detection application calls the interface of the application framework layer to start the vision detection application, and then starts the display by calling the kernel layer.
  • the user interface may include at least one vision chart symbol, optionally, the vision chart symbol used for user detection in the user interface can be marked, such as FIG. 1A User interface 110 shown, user interface 120 shown in FIG. 1B .
  • the vision detection application starts the audio driver by invoking the kernel layer, and prompts the user through the speaker 170A to judge an eye chart symbol displayed on the above-mentioned user interface.
  • the vision detection application also starts the camera driver by invoking the kernel layer, and captures a still image or video including the user (referred to as the user's image information) through the camera 193 .
  • the processor 110 obtains the user's judgment result for the eye chart symbol according to the user's image information, and then determines the next eye chart symbol for the user's judgment according to the judgment result.
  • the electronic device 100 directly obtains the user's judgment result on the symbols of the vision chart according to the user's image information or voice information, thereby obtaining the user's vision detection result.
  • the user may move around, the user's posture is incorrect (for example, the head is distorted, squinting), the user blocks the left and right eyes, and the user's height is not suitable. Vision test results are inaccurate.
  • the embodiments of the present application provide a vision detection method and an electronic device.
  • the electronic device can determine in real time whether test conditions such as user position, user posture, and user height meet the requirements, and if the requirements are not met, the user is prompted to make adjustments or the electronic device can make adjustments. After adjustment, the visual acuity detection process is carried out, and the obtained visual acuity detection results are more accurate. In addition, the electronic device can also correct and compensate the obtained vision detection result according to the incorrect posture of the user, so as to further improve the accuracy of the obtained vision detection result.
  • FIG. 1B An application scenario involved in the embodiments of the present application and a schematic diagram of human-computer interaction in the scenario are described below.
  • the application scenarios shown in the following embodiments are described by taking the vision detection scenario shown in FIG. 1B as an example, where the user interface displayed by the electronic device 100 is the user interface 120 shown in FIG. 1B .
  • FIG. 4A is a schematic diagram of another vision detection scene provided by an embodiment of the present application.
  • the electronic device 100 may include a camera 193 , and obtain image information of the user through the camera 193 , and the image information of the user is used for the electronic device 100 to implement a vision detection process.
  • the user performs a vision detection process through the electronic device 100 .
  • the electronic device 100 can continuously acquire image information of the user through the camera 193 .
  • the image of the user acquired by the electronic device 100 is the image 400 shown in (a) of FIG. 4B .
  • the electronic device 100 may display the user interface 120 , the user interface 120 may include the eye chart symbol 121 and prompt information 122 , and the electronic device 100 may prompt the user to judge the eye chart symbol 121 .
  • the position of the eye chart symbol 121 in the user interface 120 and the size of the eye chart symbol 121 may be determined according to the image 400 .
  • the electronic device 100 can obtain the relative position of the user and the electronic device 100 according to the image 400 and the pre-recorded user image, for example, obtain the user and the electronic device according to the length of the face in the image 400 and the length of the face in the pre-acquired image 100, the user is closer to the left or right side of the electronic device 100. Then, the electronic device 100 may determine the size and position of the eye chart symbol according to the relative position of the user and the electronic device 100, and display the eye chart symbol 121 on the user interface 120 according to the determined size and position of the eye chart symbol.
  • the eye chart symbol 121 displayed by the electronic device 100 is smaller.
  • the eye chart symbol 121 displayed by the electronic device 100 is larger.
  • the position of the eye chart symbol 121 in the user interface 120 may also be shifted to the left side of the electronic device 100 .
  • the position of the eye chart symbol 121 in the user interface 120 may also be shifted to the right side of the electronic device 100.
  • the user moves from the position A to the position B, and then the judgment result of the eye chart symbol 121 is given at the position B.
  • the image of the user acquired by the electronic device 100 is the image 410 shown in (b) of FIG. 4B .
  • the user in image 400 is the same size as the user in image 410 , but in different positions, and the user in image 410 is further to the right than the user in image 400 .
  • the electronic device 100 can obtain a change in the user's position according to the image 400 and the image 410, wherein, from the user's point of view, the moved position (ie, position B) is located to the left of the pre-moved position (ie, position A). If the electronic device 100 takes the judgment result given when the user is at the position B as the judgment result of the user on the eye chart symbol 121 , the visual acuity detection result obtained according to the judgment result will be inaccurate. Therefore, the electronic device 100 can prompt the user to return to the original position, and prompt the user to give the judgment result of the eye chart symbol 121 again.
  • the electronic device 100 can also adjust the position of the eye chart symbol 121 in the user interface 120 according to the image 410.
  • the user interface 120 before adjustment is shown in (a) of FIG. 4C
  • the user interface 120 after adjustment is shown in FIG. 4C .
  • the eye chart symbol 121 shown in FIG. 4C( b ) is further to the right than the eye chart symbol 121 shown in FIG. 4C( a ).
  • the line of sight of the user in position B looking at the eye chart symbol 121 deviates greatly from the target axis.
  • the electronic device 100 adjusts the position of the eye chart symbol 121 in the user interface 120 , the line of sight of the user in position B looking at the eye chart symbol 121 deviates less from the target axis. In this way, the sight line of the user looking at the eye chart symbol 121 and the target sight line at any position are relatively close, and the target axis is the axis perpendicular to the plane where the display screen of the electronic device 100 is located.
  • the moving distance of the eye chart symbol 121 in the user interface 120 may be referred to as the first preset distance, that is, the vision shown in (a) of FIG. 4C
  • the distance between the position of the table symbol 121 and the position of the eye chart symbol 121 shown in (b) of FIG. 4C may be referred to as a first preset distance.
  • the first preset distance may be proportional to the moving distance of the user.
  • the moving distance of the user is the distance that the user moves from the position A to the position B, and the moving distance of the user may be obtained according to the second preset distance.
  • the moving distance of the user in the user image may be referred to as the second preset distance, that is, between the user's position shown in (a) of FIG. 4B and the user's position shown in (b) of FIG. 4B .
  • the distance may be referred to as the second preset distance.
  • the electronic device 100 may also include a time of flight (time of flight, TOF) sensor, and the TOF sensor is used to obtain the relationship between the user and the electronic device 100.
  • the relative position is not limited in this embodiment of the present application.
  • the user may also move according to the embodiment shown in FIG. 4D , that is, move from position A to position C.
  • the image of the user acquired by the electronic device 100 is the image 400 shown in (a) of FIG. 4E
  • the image of the user acquired by the electronic device 100 is shown in (b) of FIG. 4E image 420.
  • the user in image 400 and the user in image 420 are at the same location, but the user in image 400 is smaller than the user in image 420 .
  • the electronic device 100 can obtain that the user's position changes according to the image 400 and the image 420 , wherein the distance between the moved position (ie, the position C) and the electronic device 100 is closer than the position before the movement (ie, the position A). If the electronic device 100 takes the judgment result given when the user is at the position C as the judgment result of the user on the eye chart symbol 121 , the visual acuity detection result obtained according to the judgment result will be inaccurate. Therefore, the electronic device 100 can prompt the user to return to the original position, and prompt the user to give the judgment result of the eye chart symbol 121 again.
  • the electronic device 100 can also adjust the size of the eye chart symbol 121 in the user interface 120 according to the image 420.
  • the user interface 120 before adjustment is shown in (a) of FIG. 4F
  • the user interface 120 after adjustment is shown in FIG. 4F .
  • the eye chart symbol 121 in (b) of FIG. 4F is smaller than the eye chart symbol 121 in (a) of FIG. 4F .
  • the size of the eye chart symbol 121 displayed by the electronic device 100 is obtained according to the distance between the position A and the electronic device 100 .
  • the size of the eye chart symbol 121 displayed by the electronic device 100 is obtained according to the distance between the position C and the electronic device 100 .
  • the size of the visual chart symbol seen by the user at any position is closer to the target size, and the target size is the size of the visual chart symbol that the user needs to judge when performing visual acuity tests in professional places such as hospitals and optician centers.
  • the judgment result is more accurate, and the vision detection result obtained according to the judgment result will also be more accurate.
  • the zoom ratio of the eye chart symbol 121 may be proportional to the moving distance of the user.
  • the scaling ratio of the eye chart symbol 121 is: the size ratio of the eye chart symbol 121 in FIG.
  • the moving distance of the user can be obtained according to the zoom ratio of the user in the user image.
  • the zoom ratio of the user in the user image is: the size ratio of the user in (b) of FIG. 4E and the user in (a) of FIG. 4E .
  • the electronic device 100 can also determine whether the real-time obtained user location is a preset location, and the preset location is a fixed location preset by the electronic device 100 . If it is not the preset position, the electronic device 100 may prompt the user to adjust the position to the preset position, determine the size and position of the displayed eye chart symbol according to the preset position, and display the eye chart symbol. Then, the electronic device 100 obtains the user's judgment result on the symbol of the eye chart.
  • the user when the user gives the judgment result of the eye chart symbol 121, the user squints his eyes, and the specific vision detection scene is shown in FIG. 5A . If the user does not squint, the user image obtained by the electronic device 100 is the image 400 shown in (a) of FIG. 5B , and the width of the user's eyes 401 in the image 400 is d 1 shown in FIG. 5C . If the user squints, the user image obtained by the electronic device 100 is the image 510 shown in (b) of FIG. 5B , and the width of the user's eyes 511 in the image 510 is d 2 shown in FIG. 5C . As shown in Fig. 5C, the user's squinting degree ⁇ is as follows:
  • d 2 can be set as d 1 .
  • the electronic device 100 may prompt the user to open their eyes, and prompt the user to re-give the judgment result of the eye chart symbol 121 .
  • the electronic device 100 can record the squinting degree ⁇ at this time, The judgment result given above is taken as the judgment result of the user on the eye chart symbol 121 .
  • the electronic device 100 After the electronic device 100 obtains the judgment result of the eye chart symbol 121, it continues to perform the detection process of the next eye chart symbol. When the number of the detected eye chart symbols is greater than the preset number, the electronic device 100 can judge according to the multiple eye chart symbols. As a result, the visual acuity detection result of one eye of the user is obtained. The electronic device 100 can correct and compensate the above-mentioned vision detection result according to the recorded multiple squinting degrees ⁇ , so as to obtain the vision detection result with higher precision and accuracy.
  • the electronic device 100 may pre-store a first correspondence between the user's squinting degree and a compensation value, where the compensation value is used to correct and compensate the vision detection result.
  • the first correspondence may be obtained by the electronic device 100 or other servers according to multiple vision detection processes, that is, the first correspondence may be obtained according to a large number of real test data. Then, based on the above-mentioned first correspondence, the electronic device 100 may determine a compensation value corresponding to the average value of the multiple squinting degrees ⁇ recorded above, and correct and compensate the above-mentioned vision detection result according to the compensation value.
  • the first correspondence can be represented by a function f
  • the compensation value can be represented by ⁇
  • f( ⁇ )
  • the curve of f can refer to the curve shown in FIG. 5D .
  • the horizontal axis is the user's squinting degree ⁇
  • the vertical axis is the compensation value ⁇ of the visual acuity detection result.
  • the vision detection process is normally performed.
  • the number of detected eye chart symbols is greater than the preset number, if the multiple squinting degrees ⁇ recorded by the electronic device 100 are all equal to 0, the electronic device 100 does not need to correct and compensate the obtained vision detection results.
  • the electronic device 100 when the user gives the judgment result again, if the user's squinting degree ⁇ obtained by the electronic device 100 is greater than or equal to the preset squinting value (for example, 0.5) and less than or equal to 1, Then, the electronic device 100 prompts the user to open his eyes again, and prompts the user to give the judgment result of the eye chart symbol 121 again. Until the user's squinting degree ⁇ obtained by the electronic device 100 is greater than or equal to 0 and less than the preset squinting value, the electronic device 100 records the squinting degree ⁇ at this time, and uses the above re-given judgment result as the user's eyesight chart. The judgment result of symbol 121.
  • the embodiment of the present application does not limit the specific judgment process.
  • d 2 may not be set to d 1 when d 2 >d 1 , and the user's squinting degree ⁇ may be less than 0.
  • the electronic device 100 may determine that the user is not squinting when the squinting degree ⁇ is less than or equal to 0.
  • the electronic device 100 may also determine that the user is not squinting when the squinting degree ⁇ is within a preset interval, for example, the preset interval is [0, 0.1].
  • the embodiment of the present application does not limit the judging manner of squinting.
  • the electronic device 100 may also first determine the compensation values corresponding to the multiple squinting degrees ⁇ recorded above, and then calculate the average value of the multiple compensation values, which is used as Regarding the compensation value for correcting and compensating the vision detection result, the embodiment of the present application does not limit the manner of obtaining the compensation value.
  • the user's head is distorted, and the specific vision detection scene is shown in FIG. 5E.
  • the image of the user obtained by the electronic device 100 is the image 400 shown in (a) of FIG. 5F
  • the central axis of the user's head in the image 400 is the first axis.
  • the image of the user obtained by the electronic device 100 is the image 520 shown in (b) of FIG. 5F
  • the central axis of the user's head in the image 520 is the second axis
  • the first axis and the second axis are The included angle between them is the first included angle.
  • the first included angle is used to indicate the degree of distortion of the user's head. If the first included angle is 0, it means that the user's head is not distorted, and the value range of the first included angle is [0, 90 degrees].
  • the electronic device 100 can prompt the user to straighten his head, and prompt the user to re-give the judgment result of the eye chart symbol 121 .
  • the electronic device 100 may record the first included angle at this time, and use the above-mentioned re-given judgment result as The user's judgment result for the eye chart symbol 121 .
  • the electronic device 100 After the electronic device 100 obtains the judgment result of the eyesight chart symbol 121, it continues to perform the detection process of the next vision chart symbol. When the number of detected vision chart symbols is greater than the preset number, the electronic device 100 can judge the multiple vision chart symbols according to the judgment result. As a result, the visual acuity detection result of one eye of the user is obtained. The electronic device 100 can correct and compensate the obtained vision detection result according to the recorded multiple first included angles, so as to obtain the vision detection result with higher precision and accuracy.
  • the electronic device 100 may pre-store a second correspondence between the degree of distortion of the user's head and a compensation value, where the compensation value is used to correct and compensate the vision detection result.
  • the second correspondence may be obtained by the electronic device 100 or other servers according to multiple vision detection processes, that is, the second correspondence may be obtained according to a large number of real test data. Then, based on the second correspondence, the electronic device 100 may determine a compensation value of the vision detection result corresponding to the average value of the recorded multiple first angles, and perform correction and compensation on the vision detection result according to the compensation value.
  • the average value of multiple first included angles recorded above is 45 degrees
  • the visual acuity detection result of one eye of the user is 1.0
  • the compensation value corresponding to the degree of head distortion of 45 degrees in the above correspondence is 0.05
  • the vision detection process is normally performed.
  • the electronic device 100 does not need to correct and compensate the obtained vision detection result.
  • the electronic device 100 when the user gives the judgment result again, if the first angle obtained by the electronic device 100 is greater than or equal to a preset angle (for example, 60 degrees) and less than or equal to 90 degrees, the electronic The device 100 again prompts the user to straighten the head, and prompts the user to give the judgment result of the eye chart symbol 121 again. Until the first included angle obtained by the electronic device 100 is greater than or equal to 0 and less than or equal to the preset angle, the electronic device 100 records the first included angle at this time, and uses the above re-given judgment result as the user's eye chart symbol 121 judgment result.
  • the embodiment of the present application does not limit the specific judgment process.
  • the first included angle when the second axis is on the left side of the first axis and the first included angle when the second axis is on the right side of the first axis may be different, then the first included angle may be different.
  • the value range of the angle may be [-90 degrees, 90 degrees] or [0, 180 degrees], and the electronic device 100 may determine that the user's head is distorted when the value of the first included angle is not 0.
  • the electronic device 100 may also determine that the user's head is not distorted when the first included angle is within a preset interval, and the preset interval is, for example, [0, 10 degrees].
  • the embodiments of the present application do not limit the manner of determining the distortion of the user's head.
  • the electronic device 100 may also first determine the compensation values corresponding to the plurality of first included angles recorded above, and then calculate the average value of the plurality of compensation values.
  • the embodiment of the present application does not limit the manner of obtaining the compensation value.
  • the electronic device 100 can also determine the compensation value of the judgment result of each eye chart symbol respectively, and then correct the judgment result of the corresponding eye chart symbol through the compensation value, and finally according to multiple The user's visual acuity detection result is obtained from the judgment result of the corrected and compensated visual acuity chart symbol, and the specific manner of the correction and compensation is not limited in this embodiment of the present application.
  • the electronic device 100 may not prompt the user to adjust postures such as position, head, eyes, etc., but directly obtain the user's judgment result on the symbol of the eye chart, and perform correction and compensation for it, In order to obtain the user's vision test results.
  • the electronic device 100 prompts the user to cover one eye to perform a vision test on the user's other eye, but the user may not cover the eye or the user may cover the other eye, resulting in the obtained vision test result Incorrect.
  • the electronic device 100 finishes testing one eye of the user and prompts the user to block the other eye, but the user does not replace the blocked eye with the other eye, resulting in an incorrect vision detection result.
  • the electronic device 100 may acquire an image of the user through the camera 193, and determine whether the user blocks the eyes and the eyes that the user actually blocks according to the relative positions of the user's eyes and hands in the user image, so as to automatically determine the left and right eyes of the user.
  • the visual acuity test results specific examples are shown in Figures 6A-6C below.
  • FIG. 6A is a schematic diagram of determining an eye blocked by a user according to an embodiment of the present application.
  • the first acquired user image is an image 610 .
  • the electronic device 100 may determine a detection area 611 in the user image 610 , and then extract features of the user's eyes and hands from the detection area 611 .
  • a judgment result can be obtained: the user does not block the eyes.
  • the electronic device 100 may prompt the user to block one eye (eg, prompt the user to block the right eye).
  • the user image obtained by the electronic device 100 is the image 620 shown in FIG. 6B .
  • the electronic device 100 may determine the detection area 621 in the user image 620 , and then extract the above-mentioned features from the detection area 621 .
  • the electronic device 100 determines that the detection area 621 after feature extraction includes one eye and one hand, and the hand is located on the left side of the eye, a judgment result can be obtained: the eye blocked by the user is the left eye. Even if the electronic device 100 starts to prompt the user that the right eye is blocked, the electronic device 100 can obtain that the user's actual blocked eye is the left eye.
  • the electronic device 100 may perform vision detection on the user and obtain the vision detection result of the user's left eye.
  • the electronic device 100 After the electronic device 100 finishes testing the user's left eye, it may prompt the user to block the other eye (ie, the right eye). If the detection area after feature extraction obtained by the electronic device 100 at this time is the same as the detection area 621 after feature extraction shown in FIG. 6B , the electronic device 100 can determine that the user has not replaced the occluded eye, and thus prompts the user again to block the other eye eye (ie right eye).
  • the electronic device 100 may determine the detection area 631 in the user image 630 , and then extract the above-mentioned features from the detection area 631 .
  • the electronic device 100 determines that the detection area 631 after feature extraction includes one eye and one hand, and the hand is located on the right side of the eye, a judgment result can be obtained: the eye blocked by the user is the right eye. At this time, the electronic device 100 may continue to perform vision detection on the user and obtain the vision detection result of the user's right eye.
  • the electronic device 100 can also determine whether the user blocks the eyes according to other objects used to block the user's eyes (for example, an eye mask) and the relative position of the user's eyes, and the eyes actually blocked by the user. This is not limited in the application examples. However, it is understandable that the electronic device 100 determines whether the user blocks the eyes and the eyes that the user actually blocks according to the relative positions of the user's eyes and hands. The user can perform vision detection without additional aids such as the above-mentioned goggles, which is more convenient to use.
  • other objects used to block the user's eyes for example, an eye mask
  • the electronic device 100 determines whether the user blocks the eyes and the eyes that the user actually blocks according to the relative positions of the user's eyes and hands.
  • the user can perform vision detection without additional aids such as the above-mentioned goggles, which is more convenient to use.
  • the height of the user's eyes is generally consistent with the height of the symbol on the vision chart.
  • the height of the eye may differ greatly from the height of the visual chart symbol displayed by the electronic device 100 , and therefore, the visual acuity detection result obtained in the above situation is not accurate enough.
  • the electronic device 100 can adjust the display position of the visual acuity chart symbol on the user interface, so that the height of the user's eyes and the height of the visual chart symbol displayed by the electronic device 100 are more consistent, and the obtained visual acuity detection result is more accurate, The specific process is shown in Figure 7A.
  • FIG. 7A is a comparison diagram before and after adjusting the display position of an eye chart symbol provided by an embodiment of the present application.
  • (a) of FIG. 7A is a schematic diagram before the display position of the symbols on the eye chart is adjusted
  • (b) of FIG. 7A is a schematic diagram after the display position of the symbols on the eye chart is adjusted.
  • the height of the user's eyes from the ground is h 1
  • the display position of the eye chart symbol 121 on the electronic device 100 is represented by a gray square
  • the height of the display position from the ground is h 2 , h 1 >h 2 .
  • the electronic device 100 shown in FIG. 7A is actually a display screen of the electronic device 100 .
  • the user needs to judge the visual acuity chart symbol 121 displayed on the electronic device 100 , and at this time, the line of sight of the user looking at the visual acuity chart symbol 121 is the actual line of sight direction.
  • the electronic device 100 can adjust the display position of the eye chart symbol 121 , and the adjusted schematic diagram is shown in (b) of FIG. 7A .
  • the electronic device 100 can raise the display position of the eye chart symbol 121 in the user interface 120 , and the height of the display position of the eye chart symbol 121 from the ground is h 1 .
  • the electronic device 100 adjusts the display position of the eye chart symbol 121 , the user's gaze direction looking at the eye chart symbol 121 is the target gaze direction shown in (a) of FIG. 7A .
  • the electronic device 100 further performs vision detection on the user, and the obtained vision detection result will be more accurate.
  • the height of the display position of the eye chart symbol 121 from the ground may not be h 1 , but the difference from h 1 is smaller than the preset value.
  • the threshold is not limited in this embodiment of the present application.
  • the electronic device 100 may also prompt the user to adjust the height of the user, so that the height of the user's eyes is more consistent with the height of the visual chart symbol displayed by the electronic device 100, and the obtained visual acuity detection result is more accurate.
  • the specific process is shown in the figure 7B.
  • FIG. 7B is a comparison diagram before and after a user adjusts the height of a user according to an embodiment of the present application.
  • (a) of FIG. 7B is a schematic diagram before the user adjusts the height of the user
  • (b) of FIG. 7B is a schematic diagram after the user adjusts the height of the user.
  • the electronic device 100 may prompt the user to adjust the height of the user until the height of the user is adjusted to h 2 shown in (b) of FIG. 7B , and the electronic device 100 will then perform vision detection on the user. As shown in (b) of FIG. 7B , the user has lowered the height of the user (h 1 -h 2 ). At this time, the height of the user's eyes from the ground is the same as the height of the eye chart symbol 121 displayed by the electronic device 100 (both for h 2 ).
  • the user's line of sight to the eye chart symbol 121 is parallel to the target line of sight shown in (a) of FIG. 7A .
  • the vision detection result obtained by the electronic device 100 performing the vision detection process will be more accurate.
  • the height of the user's eyes from the ground may not be h 2 , but the difference between h 2 and h 2 is smaller than the preset threshold. This is not limited.
  • the electronic device 100 may be provided with a lifting device such as a lift bar, and the electronic device 100 may automatically adjust the height of the display screen of the electronic device 100 (hereinafter referred to as the electronic device 100 adjusting the height of the electronic device 100 ), so that the user's eyes
  • the height of the visual acuity chart symbol displayed by the electronic device 100 is relatively consistent, and the obtained visual acuity detection result is relatively accurate.
  • the specific process is shown in FIG. 7C .
  • FIG. 7C is a comparison diagram of an electronic device 100 before and after the height of the electronic device 100 is adjusted according to an embodiment of the present application.
  • (a) of FIG. 7C is a schematic diagram of the electronic device 100 before adjusting the height of the electronic device 100
  • (b) of FIG. 7C is a schematic diagram of the electronic device 100 after adjusting the height of the electronic device 100 .
  • FIG. 7C is consistent with (a) of FIG. 7A , for details, please refer to the description of (a) of FIG. 7A .
  • the electronic device 100 shown in FIG. 7C is actually a display screen of the electronic device 100 .
  • the electronic device 100 can adjust the height of the display screen through the lifting device, and the schematic diagram after adjustment is shown in (b) of FIG. 7C .
  • the electronic device 100 has increased the height of the display screen (h 1 -h 2 ).
  • the height of the visual chart symbol 121 displayed by the electronic device 100 is greater than that displayed by the electronic device 100 before the height adjustment.
  • the height of the eye chart symbol 121, and the difference is also (h 1 -h 2 ).
  • the electronic device 100 adjusts the height of the display screen, the user's gaze direction when looking at the eye chart symbol 121 is the target gaze direction shown in (a) of FIG. 7C .
  • the electronic device 100 further performs vision detection on the user, and the obtained vision detection result will be more accurate.
  • the height of the position where the electronic device 100 displays the eye chart symbol 121 from the ground may not be h 1 , but the difference from h 1 . is less than the preset threshold, which is not limited in this embodiment of the present application.
  • the electronic device 100 may also directly measure the relative height between the user's eyes and the visual chart symbol displayed by the electronic device 100 , which is not limited in this embodiment of the present application.
  • the electronic device 100 may also prompt the user to adjust the height of the electronic device 100 .
  • the electronic device 100 may further perform correction and compensation according to the relative height of the user’s eyes and the visual chart symbols displayed by the electronic device 100 to obtain higher accuracy vision test results.
  • the electronic device 100 may also pre-store the correspondence between the user's location and the compensation value, the correspondence between
  • the compensation value is used to correct and compensate the vision detection result.
  • the above-mentioned corresponding relationship may be obtained by the electronic device 100 or other servers according to multiple vision detection processes, that is, obtained according to a large number of real test data.
  • the electronic device 100 can obtain the corresponding compensation value according to the above-mentioned corresponding relationship, and perform correction and compensation on the obtained vision detection result according to the compensation value, so as to obtain the vision detection result with higher accuracy. This application does not limit this.
  • the electronic device 100 can also directly combine the user's position, the user's squinting degree, the head distortion degree,
  • the present application does not limit the specific manner of correction compensation.
  • the electronic device 100 may be a large-screen device such as a smart screen and a smart TV.
  • the electronic device 100 can divide the displayed user interface into multiple areas, each area is used for a user to perform vision detection, thereby simultaneously performing vision detection on multiple people, increasing detection efficiency, and making it more convenient for users to use. For specific examples, see the following. 8A-8D.
  • FIG. 8A is a schematic diagram of another vision detection scene provided by an embodiment of the present application.
  • FIG. 8A is used as an example to illustrate the process of the electronic device 100 performing vision detection on two users at the same time.
  • both the first user and the second user perform a vision detection process through the electronic device 100 .
  • the electronic device 100 can continuously obtain image information of the first user and the second user through the camera 193 .
  • the electronic device 100 may display a user interface 810.
  • the user interface 810 may include a first area 811 and a second area 822.
  • the first area 811 is used for the first user to perform vision detection
  • the second area 812 is used for the second user to perform vision detection.
  • the electronic device 100 may prompt the first user to judge the visual chart symbols displayed in the first area 811 , and prompt the second user to judge the visual chart symbols displayed in the second area 812 .
  • the eye chart symbols displayed in the first area 811 and the eye chart symbols displayed in the second area 812 may be different. Specifically, the size and position of the eye chart symbol displayed by the electronic device 100 in the first area 811 may be obtained according to the image information of the first user, and the size and position of the eye chart symbol displayed by the electronic device 100 in the second area 812 may be is obtained according to the image information of the second user. After the electronic device 100 obtains the first user's judgment result on the eye chart symbol currently displayed in the first area 811, the electronic device 100 can determine the next eye chart symbol displayed in the first area 811 according to the judgment result, that is, the next eye chart symbol to be displayed in the first area 811. The eye chart symbol judged by the first user.
  • the electronic device 100 can determine the eye chart symbol to be displayed next in the second area 812 according to the judgment result, that is, The next eye chart symbol for the second user's judgment. That is to say, the electronic device 100 can adjust the visual acuity chart symbols displayed in different regions in real time according to the judgment results of different users, so as to obtain the visual acuity detection results of different users. 1A-1B, 2-3, 4A-4F, 5A-5F, 6A-6C, 7A-7C Example shown.
  • the electronic device 100 can determine whether the position and posture of the first user meet the requirements according to the image information of the first user, and if not, prompt the first user to make adjustments, and the electronic device 100 can also determine whether the position and posture of the first user meet the requirements. A user's incorrect posture adjusts the obtained vision detection result.
  • the electronic device 100 can also determine whether the position and posture of the second user meet the requirements according to the image information of the second user, and if not, prompt the second user to make adjustments, and the electronic device 100 can also determine whether the position and posture of the second user meet the requirements. Incorrect posture adjusts the obtained vision test results.
  • FIGS. 4A-4F, 5A-5F, 6A-6C, and 7A-7C please refer to the embodiments shown in FIGS. 4A-4F, 5A-5F, 6A-6C, and 7A-7C.
  • the adjustment method of the electronic device 100 for the first user and the adjustment for the second user The way can be different or the same.
  • the user interface displayed by the electronic device 100 may also be the user interface 820 shown in FIG. 8B .
  • the user interface 820 includes a third area 821 and a fourth area 822 .
  • the third area 821 is the same as the first area 811 shown in FIG. 8A
  • the fourth area 822 is the same as the second area 812 shown in FIG. 8A .
  • the user interface displayed by the electronic device 100 may be the user interface 830 shown in FIG. 8C
  • the user interface 830 includes four areas.
  • the user interface displayed by the electronic device 100 may be the user interface 840 shown in FIG.
  • the user interface 840 also includes four areas. Different regions are used for different users to perform vision detection, and the symbols of the vision chart displayed in different regions may be different. It is understandable that the vision detection process of the electronic device 100 for any user may be as shown in FIGS. 1A-1B, 2-3, and 3. 4A-FIG. 4F, FIG. 5A-FIG. 5F, FIG. 6A-FIG. 6C, and FIG. 7A-FIG. 7C show the vision detection process.
  • FIG. 9 is a schematic flowchart of a vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • S101 The electronic device starts to measure visual acuity and determine the target user.
  • the electronic device may turn on the camera in response to a first user operation to start measuring vision, wherein the first user operation is, for example, but not limited to: a user operation (such as a click operation) acting on the electronic device, a user gesture (such as OK gestures), voice messages, etc.
  • a user operation such as a click operation
  • a user gesture such as OK gestures
  • voice messages etc.
  • the electronic device determines to start the vision measurement, reference may be made to the description of the electronic device 100 determining to start the vision detection process in FIG. 2 , and details are not repeated here.
  • the electronic device can acquire the image information of the user through the camera, and automatically determine the user in the image information as the target user.
  • the electronic device may also receive the second user operation, and determine the target user according to the second user operation.
  • the example of the second user operation is the same as the example of the first user operation, and will not be repeated here.
  • For an example of determining the target user by the electronic device reference may be made to the description of determining the target user by the electronic device 100 in FIG. 2 , and details are not repeated here.
  • S102 The electronic device continuously acquires image information of the target user.
  • the electronic device continuously acquires image information of the target user, and performs corresponding operations according to the real-time acquired image information of the target user.
  • S103 The electronic device obtains the first location where the target user is located.
  • the first position may include a distance between the target user and the electronic device, and the target user is closer to the left or right side of the electronic device.
  • the electronic device may obtain the first position of the target user according to the image information of the target user, through the TOF sensor, or the like.
  • the electronic device obtains the first position according to the image information of the target user, reference may be made to the embodiments shown in FIG. 4B and FIG. 4E , and details are not repeated here.
  • the electronic device may obtain the distance (referred to as the first distance) between the target user and the electronic device according to the length of the face of the target user in the acquired image and the length of the face of the target user in the pre-recorded image.
  • the distance between the target user and the electronic device (referred to as the second distance) at this time has been determined when the electronic device pre-records the image of the target user.
  • the distance of the device is the position of the second distance.
  • the ratio of the face length of the target user in the acquired image to the face length of the target user in the pre-recorded image may be referred to as the first ratio, and the ratio of the first distance to the second distance is equal to the first ratio.
  • the electronic device may obtain the first distance according to the first ratio and the second distance.
  • S104 The electronic device determines the size and position of the displayed eye chart symbol according to the first position, and displays the eye chart symbol.
  • the electronic device may determine the position of the displayed eye chart symbol according to the target user being closer to the left or right side of the electronic device. For an example of the specific process, see the embodiments shown in FIGS. 4A-4C , which will not be repeated.
  • the size of the same eye chart symbol displayed by the electronic device is different.
  • the above-mentioned eye chart symbol seen by the target user will be smaller, and when the distance between the target user and the electronic device is short, the above-mentioned eye chart symbol seen by the target user will be larger. In this case, if the electronic device performs the vision detection process, the obtained vision detection result will be inaccurate.
  • the electronic device determines that the displayed eye chart symbol should be larger, and when the distance between the target user and the electronic device is short, the electronic device determines that the displayed eye chart symbol should be smaller, so that the target user
  • the size of the same eye chart symbol seen in different positions is the same.
  • the electronic device may determine the size of the displayed eye chart symbol according to the distance between the target user and the electronic device. For an example of a specific process, refer to the embodiments shown in FIGS. 4D-4F , which will not be repeated.
  • the electronic device may randomly select the orientation of the eyesight chart symbols before displaying the vision chart symbols each time, so as to avoid the target user from giving the judgment result of the vision chart symbols by guessing, so as to make the vision detection obtained according to the judgment result The results are more accurate.
  • S105 The electronic device obtains the judgment result of the target user on the symbol of the eye chart.
  • the target user may, but is not limited to, give the judgment result of the eye chart symbol by means of gestures, arm motion trajectory, voice, and the like.
  • the electronic device can acquire the image information of the target user through the camera, and obtain the above judgment result according to the image information of the target user.
  • the electronic device may acquire the voice information of the target user through a microphone, and obtain the above judgment result according to the voice information of the target user.
  • FIGS. 1A-1B For specific examples, reference may be made to the embodiments shown in FIGS. 1A-1B , which will not be described again.
  • S105, S102-S104 can be executed cyclically, that is, the electronic device can acquire the location of the target user in real time, and when the location of the target user changes, the size of the displayed eye chart symbol is determined according to the newly acquired location. and position, and display the symbol of the vision chart, so as to deal with the situation of the target user walking around in time, and the obtained vision detection result is more accurate.
  • S106 The electronic device determines whether the number of acquired determination results is equal to the preset number.
  • the electronic device determines that the test of one eye of the target user has been completed, and executes S107.
  • the electronic device determines that it is necessary to continue the vision test on the eye currently being tested, and determines the vision for the next judgment of the target user according to the above judgment results (for example, the most recently acquired judgment result). table symbols, and execute S102-S105.
  • S107 The electronic device obtains the vision detection result of one eye of the target user according to the preset number of judgment results.
  • S108 The electronic device performs vision detection on the other eye of the target user, and obtains the vision detection result of the other eye of the target user.
  • the electronic device may prompt the target user to block the other eye, and perform a vision test on the other eye of the target user, wherein the electronic device detects the other eye of the target user.
  • the process of performing the vision test on one eye is similar to the process (ie, S102-S107 ) of the above-mentioned electronic device performing the vision test on one eye of the target user, and details are not repeated here.
  • the electronic device can adjust the size and position of the displayed eye chart symbol according to the real-time position of the target user. Even if the target user walks, the same eye chart symbol seen by the target user is relatively consistent. The resulting vision test results are also more accurate.
  • the electronic device can also determine whether the user's posture meets the requirements according to the image information of the target user acquired in real time, and if the user's posture does not meet the requirements, the electronic device can prompt the user to make adjustments.
  • the electronic device can also correct and compensate the obtained vision detection result according to the incorrect posture of the user, so as to obtain the vision detection result with higher accuracy.
  • the specific process is shown in Figure 10.
  • FIG. 10 is a schematic flowchart of another vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • S201 The electronic device starts to measure visual acuity and determine the target user.
  • S201 is consistent with S101 of FIG. 9 , and for details, please refer to the description of S101 of FIG. 9 .
  • S202 The electronic device continuously acquires image information of the target user.
  • S202 is consistent with S102 in FIG. 9 .
  • S102 in FIG. 9 please refer to the description of S102 in FIG. 9 .
  • S203 The electronic device obtains the degree of squinting and the degree of head distortion of the target user according to the image information of the target user.
  • the squinting degree of the target user may be a third ratio
  • the numerator of the third ratio is The difference between the target user's eye width before squinting and the eye width after squinting.
  • the denominator of the third ratio is the target user's eye width before squinting.
  • Eye degree ⁇ For an example of the target user's squinting degree, see the user's squinting degree shown in Figure 5C. Eye degree ⁇ .
  • 5E-5F may refer to the description of obtaining the distortion degree of the head of the target user by the electronic device according to the image information of the target user, wherein the degree of distortion of the head of the target user may be the deviation angle of the central axis of the head of the target user, For a specific example, please refer to the first included angle shown in FIG. 5F .
  • S204 The electronic device determines whether the squinting degree of the target user is less than the first threshold, and whether the head distortion degree is less than the second threshold.
  • the squinting degree of the target user is the squinting degree ⁇ of the user shown in FIG. 5C
  • the value range of ⁇ is [0, 1]
  • the first threshold can be any value in [0, 1], such as 0.5.
  • ⁇ >0 it means that the user is squinting
  • the squinting degree of the target user is greater than 0 and less than the first threshold, indicating that the requirements are met, but the user's posture is not correct at this time.
  • the target user's squinting degree is equal to 0, it means that the user's posture is correct.
  • the degree of head distortion of the target user is the first included angle shown in FIG. 5F
  • the value range of the first included angle is [0, 90 degrees]
  • the first threshold can be any value within [0, 90 degrees] A numeric value, such as 60 degrees.
  • the degree of head distortion of the target user is greater than 0 and less than the second threshold, indicating that the requirements are met, but the user's posture is not correct at this time.
  • the distortion degree of the target user's head is equal to 0, it means that the user's posture is correct.
  • the electronic device may determine that the posture of the target user at this time does not satisfy request, so S205 can be executed.
  • the electronic device determines that the target user's posture at this time meets the requirements, so the vision test can be performed directly, that is, S206 is executed.
  • S205 The electronic device prompts the target user to adjust the posture.
  • the electronic device may prompt the target user to open his eyes, and when the distortion degree of the target user's head is greater than or equal to the second threshold, the electronic device may prompt the target user to straighten his eyes head.
  • the electronic device can repeat S202-S204, and the electronic device determines when the re-acquired squinting degree of the target user is less than the first threshold and the re-acquired head distortion degree of the target user is less than the second threshold.
  • the posture of the target user at this time meets the requirements, so the vision test can be directly performed, that is, S206 is executed.
  • S206 The electronic device obtains the judgment result of the target user on the symbol of the eye chart.
  • the electronic device determines that the degree of squinting of the target user is less than the first threshold, and the degree of head distortion of the target user is less than the second threshold, that is, when the posture of the target user meets the requirements, the electronic device obtains the target user's perception of the eye chart symbols. critical result.
  • the determination result obtained by the electronic device on the eye chart symbol from the target user is consistent with that of S105 in FIG. 9 .
  • S207 The electronic device determines whether the number of acquired determination results is equal to the preset number.
  • the electronic device determines that the test of one eye of the target user has been completed, and executes S209.
  • the electronic device determines that it is necessary to continue the visual acuity test on the eyes currently tested by the target user, and determines the visual acuity to be displayed next time according to the above judgment results (for example, the most recently acquired judgment result).
  • Table symbol specifically execute S202-S207.
  • S208 The electronic device obtains the vision detection result of one eye of the target user according to the preset number of judgment results.
  • the method also includes:
  • the electronic device corrects and compensates the obtained vision detection result according to the degree of head distortion and/or the degree of squinting of the target user.
  • the electronic device can correct and compensate the vision detection result obtained in S209 according to the squinting degree of the target user.
  • the electronic device 100 may pre-store a first correspondence between the squinting degree of the target user and the compensation value, where the compensation value is used to correct and compensate the vision detection result of the target user.
  • the first correspondence may be obtained by the electronic device 100 or other servers according to multiple vision detection processes, and an example of a curve of the first correspondence is shown in FIG. 5D .
  • the electronic device can correct and compensate the vision detection result obtained in S209 according to the head distortion degree of the target user.
  • the electronic device 100 may pre-store the second correspondence between the degree of head distortion of the target user and the compensation value, where the compensation value is used to correct and compensate the vision detection result of the target user.
  • the second correspondence may be obtained by the electronic device 100 or other servers according to multiple vision detection processes.
  • FIG. 10 only shows a process in which the electronic device performs a vision test on one eye of the user.
  • the electronic device After the electronic device obtains the vision detection result of one eye of the target user, it can prompt the target user to block the other eye, and perform a vision test on the other eye of the target user, wherein the electronic device tests the other eye of the target user.
  • the process of the visual acuity test is similar to the process (ie, S202-S209 ) that the electronic device performs the visual acuity test on one eye of the target user, and will not be repeated here.
  • the electronic device can detect whether the target user is walking, and also detect whether the target user's posture meets the requirements, that is, the method shown in FIG. 9 and the method shown in FIG. S102-S105 of FIG. 9 and S202-S206 of FIG. 10 may be performed simultaneously.
  • the electronic device may further determine whether the user blocks the eyes and whether the user blocks the eyes is wrong according to the image information of the target user acquired in real time. If the user does not cover his eyes or the user blocks his eyes incorrectly, the electronic device can prompt the user to make adjustments, thereby improving the accuracy of the test results. In addition, the electronic device can automatically identify the eyes actually blocked by the user, so as to automatically determine the vision detection results of the left and right eyes of the user, which is more convenient for the user to use. The specific process is shown in Figure 11.
  • FIG. 11 is a schematic flowchart of another vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • S301 The electronic device starts to measure visual acuity and determine the target user.
  • S301 is consistent with S101 in FIG. 9 .
  • S101 in FIG. 9 please refer to the description of S101 in FIG. 9 .
  • S302 The electronic device continues to acquire image information of the target user.
  • S302 is consistent with S102 in FIG. 9 .
  • S102 in FIG. 9 please refer to the description of S102 in FIG. 9 .
  • S303 The electronic device determines whether the user blocks one eye according to the image information of the target user.
  • the electronic device prompts the target user to block one eye (ie, S304 is executed). If it is determined that the target user blocks one eye, the electronic device obtains the target user according to the image information of the target user. The actual occluded eyes (ie, perform S305). For an example in which the electronic device determines whether the target user blocks one eye according to the image information of the target user, see the embodiment shown in FIG. 6A .
  • S304 The electronic device prompts the target user to cover one eye.
  • S305 The electronic device obtains the eyes blocked by the target user according to the image information of the target user.
  • the electronic device can first obtain the relative positions of the eyes and hands of the target user according to the image information of the target user, and then obtain the eyes blocked by the target user according to the relative positions of the eyes and hands of the target user.
  • the electronic device can first obtain the relative positions of the eyes and hands of the target user according to the image information of the target user, and then obtain the eyes blocked by the target user according to the relative positions of the eyes and hands of the target user.
  • FIG. 6B-Fig. The embodiment shown in 6C.
  • S306 The electronic device performs vision detection on the unobstructed eyes of the target user, and obtains a corresponding vision detection result.
  • FIGS. 9-10 For the process of the electronic device performing vision detection on one eye of the target user, reference may be made to the vision detection process shown in FIGS. 9-10 and the following FIG. 12 .
  • S307 The electronic device prompts the target user to block the other eye.
  • the electronic device may prompt the target user to block the other eye to test the other eye of the target user.
  • S308 The electronic device determines whether the eye blocked by the user is the other eye according to the image information of the target user.
  • the electronic device obtains the relative positions of the eyes and hands of the target user according to the image information of the target user acquired in real time, and then obtains the eyes blocked by the target user according to the relative positions of the eyes and hands of the target user, and determines the target user at this time. Whether the user's occluded eye is the target user's other eye. When the eye blocked by the target user is not the other eye at this time, the electronic device prompts the user to block the other eye again (ie, S307 is executed). When the eye blocked by the target user at this time is the other eye, the electronic device performs vision detection on the unblocked eye of the target user at this time (ie, S309 is executed).
  • the electronic device performs vision detection on the other eye of the target user, and obtains a corresponding vision detection result.
  • the visual acuity detection process of any eye of the target user by the electronic device is similar.
  • the electronic device can adjust the display position of the eye chart symbol or prompt the user to adjust the user's height, thereby ensuring that the height of the user's eyes and the height of the electronic device
  • the height of the symbols displayed on the visual acuity chart is consistent to improve the accuracy of visual inspection results.
  • the electronic device can also adjust the height of the display screen of the electronic device, and the user does not need to adjust, which is more convenient to use. The specific process is shown in Figure 12.
  • FIG. 12 is a schematic flowchart of another vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • S401 The electronic device starts to measure visual acuity and determine the target user.
  • S401 is consistent with S101 of FIG. 9 , and for details, please refer to the description of S101 of FIG. 9 .
  • S402 The electronic device continues to acquire image information of the target user.
  • S402 is consistent with S102 of FIG. 9 , and for details, please refer to the description of S102 of FIG. 9 .
  • S403 The electronic device determines the first height of the target user's eyes from the ground.
  • the electronic device can obtain the first height of the target user's eyes from the ground according to the image information of the target user, through a TOF sensor or the like.
  • S404 The electronic device displays the eye chart symbol, and determines the second height of the display position of the eye chart symbol from the ground.
  • the electronic device can obtain the second height of the display position of the eye chart symbol from the ground according to its own size and the display position of the eye chart symbol in the user interface.
  • S405 The electronic device determines whether the absolute value of the difference between the first height and the second height is smaller than the preset height.
  • the preset height may or may not be 0, for example, 1 cm.
  • the electronic device can perform S406 to adjust the first height or the second height until the difference between the first height and the second height becomes
  • the electronic device obtains the judgment result of the target user (ie, S407 is executed).
  • the electronic device performs at least one of the following: adjusting the display position of the eye chart symbol, prompting the user to adjust the height of the user, and adjusting the height of the electronic device.
  • the electronic device can adjust the display position of the eye chart symbol in the user interface according to the first height and the second height. For a specific example, see the embodiment shown in FIG. 7A .
  • the electronic device may also prompt the user to adjust the height of the user. For a specific example, see the embodiment shown in FIG. 7B .
  • the electronic device can adjust the height of the display screen of the electronic device. For a specific example, see the embodiment shown in FIG. 7C .
  • S407 The electronic device obtains the judgment result of the target user on the symbol of the eye chart.
  • S407 is consistent with S105 in FIG. 9 , and for details, please refer to the description of S105 in FIG. 9 .
  • S105 for details of the vision detection process after S407, reference may be made to the description of S106-S108 in FIG. 9, and details are not repeated here.
  • the electronic device can not only detect whether the target user is walking, but also detect whether the target user's posture meets the requirements, and also detect whether the height of the target user's eyes is consistent with the height of the eye chart symbol displayed by the electronic device. That is to say, the method shown in FIG. 9 , the method shown in FIG. 10 , and the method shown in FIG. 12 can be executed simultaneously, that is, S102-S105 in FIG. 9 , S202-S206 in FIG. 10 , and S402-S407 in FIG. 12 can be executed simultaneously.
  • Figures 9 to 12 above all take the vision detection process of a user as an example to illustrate. If the electronic device 100 is a large-screen device such as a smart screen or a smart TV, the electronic device 100 can perform vision detection on multiple people at the same time, which improves eyesight. The detection efficiency is more convenient and fast. The specific process is shown in Figure 13.
  • FIG. 13 is a schematic flowchart of another vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • S501 The electronic device starts to measure visual acuity and determines multiple target users.
  • S501 is the same as S101 in FIG. 9 , except that in S501, when the electronic device automatically identifies the target user according to the acquired image information, multiple users in the image information can be determined as the target user, or the electronic device receives the first When two users operate, the second user operations of multiple users may be received.
  • S101 in FIG. 9 please refer to the description of S101 in FIG. 9 .
  • S502 The electronic device continuously acquires image information of multiple target users.
  • S502 is the same as S102 in FIG. 9 , except that in S502 , the acquired image information includes image information of multiple target users.
  • the acquired image information includes image information of multiple target users.
  • S503 The electronic device displays multiple vision detection areas.
  • the user interface displayed by the electronic device includes a plurality of vision detection areas, and the number of vision detection areas is equal to the number of target users.
  • a vision detection area is used for vision detection of a target user, which may be referred to as a target user corresponding to a vision detection area later.
  • Any vision detection area may include at least one vision chart symbol, and the size and position of the vision chart symbol may be obtained according to the location of the target user using the vision detection area.
  • S104 in FIG. 9 .
  • S504 The electronic device obtains the judgment result of each target user on the visual acuity chart symbol in the corresponding visual acuity detection area.
  • the electronic device can prompt the target user to give a judgment result of an eye chart symbol, and the vision detection area used by the target user (that is, the vision detection area corresponding to the target user) is used to display the above-mentioned vision Table symbol.
  • the electronic device may separately obtain the judgment result of each target user.
  • S505 The electronic device determines the next eye chart symbol to be judged according to the judgment result of each target user, and displays the eye chart symbol in the corresponding vision detection area.
  • the electronic device can determine the next eye chart symbol for the target user's judgment according to the judgment result, and determine the next eye chart symbol used for the target user's judgment according to the judgment result.
  • the detection area displays the next chart symbol determined above.
  • the electronic device may continue to obtain the target user's judgment result for the next eye chart symbol determined above, that is, to perform S504 in a loop.
  • the judgment result of the visual acuity chart symbol given by each target user is different, the visual acuity chart symbol displayed in each visual acuity detection area is also different, and the progress of the visual acuity detection process for each target user is also different.
  • the electronic device can continue to obtain the judgment results until the number of judgment results obtained by the electronic device is equal to the preset number, then the electronic device can obtain the judgment results according to the preset number.
  • the number of judgment results is used to obtain the vision test result.
  • the preset number may be the number of eye chart symbols that are usually tested in the field of vision detection, that is, the preset number may be obtained from experience. Not limited to this, the preset number may also be set by the user. When the number of judgment results is greater than or equal to the preset number, the electronic device will confirm that the obtained vision test results are accurate.
  • the vision detection process of each target user through the electronic device can be performed independently and simultaneously without affecting each other.
  • the vision detection process shown in FIGS. 9-12 please refer to the vision detection process shown in FIGS. 9-12 .
  • FIG. 14 is a schematic flowchart of another vision detection method provided by the present application.
  • the method can be applied to the electronic device 100 shown in FIG. 2 .
  • the method can be applied to the electronic device 100 shown in FIG. 3 .
  • the method may include but is not limited to the following steps:
  • the first character may be an eye chart symbol.
  • the display manner of the first character includes: display position, size, color, thickness, inclination angle, and the like.
  • the display screen of the electronic device displays a detection area, where at least one eye chart symbol is displayed, and the first character is any one of the at least one eye chart symbol.
  • This detection area is used for vision detection of a target user.
  • examples of the electronic device displaying the first character are shown in FIGS. 1A-1B , FIG. 4A , FIG. 4D , FIG. 5A , and FIG. 5E .
  • the display screen of the electronic device displays a preset number of detection areas, and the preset number is the number of target users.
  • a detection area is used for vision detection of a target user.
  • a detection area displays at least one eye chart symbol, and the first character is any one of the at least one eye chart symbol. That is to say, the electronic device can perform vision detection on multiple target users at the same time, a specific description is shown in FIG. 13 .
  • different target users may have different identification results for eye chart symbols, and then the eye chart symbols displayed by the electronic device according to the identification results may also be different. That is to say, the first characters displayed in different detection areas may be the same or different. At this time, examples of the electronic device displaying the first character are shown in FIGS. 8A-8D .
  • the electronic device may acquire a first image through a camera, and the first image includes the target user. Examples of the first image are shown in Figures 4B, 4E, 5B, 5F, 6A-6C.
  • S603 Obtain a first detection result according to the gesture of the target user in the first image and the identification result of the target user for the first character.
  • the posture of the target user includes, for example, but not limited to, the position, the degree of squinting, the degree of head distortion, and the height of the eyes from the ground (referred to as the first height).
  • the first height For an example of determining the location, reference may be made to the embodiments shown in FIGS. 4A-4F .
  • An example of determining the degree of squinting can be found in the embodiment shown in FIG. 5C .
  • An example of determining the degree of head distortion can be found in the embodiments shown in FIGS. 5E-5F.
  • An example of determining the first height may refer to the embodiment shown in FIGS. 7A-7C .
  • the electronic device may, but is not limited to, obtain the target user's identification result for the first character through a camera, microphone, sensor, etc. For a specific example, see the description of obtaining the user's judgment result for the eye chart symbol 111 in FIG. 1A .
  • the electronic device may determine that the posture of the target user in the first image does not meet the requirements, for example, the position is not the first preset position, the degree of squinting is greater than 0, the degree of head distortion is greater than 0, the first height and the first The absolute value of the difference between the display position of the character and the height of the ground (referred to as the second height) is greater than 0.
  • the electronic device can obtain the first detection result according to the pre-acquired correction method, combining the posture of the target user in the first image and the identification results of the target user for multiple different eye chart symbols.
  • FIG. 5A- FIG. 5D shows an illustration of the visual acuity detection result obtained by correcting and compensating for the degree of squinting.
  • the first detection result represents the vision level of the target user, such as four vision levels of good vision, better vision, poor vision, and poor vision.
  • the method may further include: acquiring a second image, where the second image includes the target user; determining that the posture of the target user in the second image is different from the preset posture; outputting prompt information or adjusting the first How characters are displayed.
  • the posture of the target user in the second image is different from the preset posture, for example, the position is not the second preset position, the degree of squinting is greater than or equal to the preset width, the degree of head distortion is greater than or equal to the preset angle, The absolute value of the difference between the first height and the second height is greater than or equal to a preset height or the like.
  • the prompt information is used to prompt the user to adjust the posture, such as prompting the user to adjust the position, open the eyes, straighten the head, and adjust the height.
  • the electronic device may acquire the image including the target user again, and determine whether the target user's posture is a preset posture.
  • the electronic device executes S603. If the gesture of the target user is still not the preset gesture, the electronic device may continue to output prompt information or adjust the display mode of the first character.
  • the electronic device may not output prompt information, but directly adjust the display mode of the first character, and then execute S602-S603. That is, the electronic device can directly adjust the display mode of the first character according to the gesture of the target user, thereby ensuring that the gesture of the target user is the same as the gesture required at this time, wherein the gesture required at this time and the preset gesture are usually different.
  • the target user is at the position B shown in FIG. 4A
  • the second preset position is the position A shown in FIG. 4A .
  • the electronic device determines that the position B where the target user is located is different from the second preset position (ie, the position A)
  • the electronic device can directly display the user interface 120 shown in (b) of FIG. 4C .
  • the required position is the position B where the user is located, not the second preset position (ie, the position A).
  • the second preset position is position A.
  • the electronic device determines that the user is at position B or position C through the acquired second image, and the electronic device can prompt the target user to adjust the position to position A.
  • the electronic device may re-determine the target user's identification result for the first character, and execute S603.
  • the electronic device may adjust the display mode of the first character according to the example shown in FIG. 4C or FIG. 4F , then reacquire the identification result of the first character, and execute S603 .
  • the preset width is 0.5.
  • the electronic device determines that the squinting degree ⁇ of the target user is greater than or equal to 0.5 through the acquired second image, and the electronic device can prompt the target user to open his eyes.
  • the electronic device may re-determine the identification result of the target user for the first character, and execute S603 .
  • the electronic device may increase the size of the first character, increase the font size of the first character, etc., and then reacquire the identification result of the first character, and execute S603.
  • the preset angle is 60 degrees.
  • the electronic device may prompt the target user to straighten his head.
  • the electronic device may re-determine the target user's identification result for the first character, and execute S603.
  • the electronic device may adjust the inclination angle of the first character, etc., and then reacquire the identification result of the first character, and execute S603.
  • the electronic device determines through the acquired second image: the absolute value of the difference between the first height and the second height
  • the electronic device may re-determine the target user's identification result for the first character, and execute S603 .
  • the electronic device can raise or lower the display position of the first character on the display screen.
  • the electronic device includes a lifting device, the display screen can be raised or lowered to raise or lower the height. The display position of the first character. Then re-acquire the identification result of the first character, and execute S603.
  • the electronic device may determine the eyes of the target user to be tested according to whether the eyes of the target user are blocked in the first image, and the obtained first detection result represents the vision level of the target eye to be tested. For example, the electronic device can determine whether the target user's eyes are blocked according to the relative positional relationship between the target user's hands and eyes, and in the case of blocking, determine whether the blocked eye is the left eye or the right eye, a specific example is shown in Figure 6A-FIG. shown in 6C.
  • FIG. 14 can refer to FIGS. 1A-1B, 2-3, 4A-4F, 5A-5F, 6A-6C, 7A-7C, The embodiments shown in FIGS. 8A to 8D and FIGS. 9 to 13 will not be described again.
  • the above-mentioned embodiments it may be implemented in whole or in part by software, hardware, firmware or any combination thereof.
  • software it can be implemented in whole or in part in the form of a computer program product.
  • the computer program product described above includes one or more computer instructions.
  • the computer program instructions described above are loaded and executed on a computer, the procedures or functions described above in accordance with the present application are produced in whole or in part.
  • the aforementioned computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable devices.
  • the above-mentioned computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the above-mentioned computer instructions may be transmitted from a website site, computer, server or data center via wired communication. (eg coaxial cable, optical fiber, digital subscriber line) or wireless (eg infrared, wireless, microwave, etc.) to another website site, computer, server or data center.
  • the above-mentioned computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, a data center, etc. that includes one or more available media integrated.
  • the above-mentioned usable media may be magnetic media (eg, floppy disks, hard disks, magnetic tapes), optical media (eg, DVD), or semiconductor media (eg, Solid State Disk), and the like.
  • magnetic media eg, floppy disks, hard disks, magnetic tapes
  • optical media eg, DVD
  • semiconductor media eg, Solid State Disk

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Heart & Thoracic Surgery (AREA)
  • Emergency Management (AREA)
  • Ophthalmology & Optometry (AREA)
  • Biomedical Technology (AREA)
  • Business, Economics & Management (AREA)
  • Medical Informatics (AREA)
  • Molecular Biology (AREA)
  • Surgery (AREA)
  • Animal Behavior & Ethology (AREA)
  • Biophysics (AREA)
  • Public Health (AREA)
  • Veterinary Medicine (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • Psychiatry (AREA)
  • Social Psychology (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本申请实施例提供一种视力检测方法,应用于电子设备,该方法包括:显示第一字符;获取第一图像,其中第一图像包括目标用户;根据第一图像中目标用户的姿势,以及目标用户对于第一字符的指认结果得到第一检测结果,第一检测结果表征目标用户的视力等级。采用本申请实施例能够让用户简单便捷地进行视力检测过程,并考虑了用户姿势对视力检测结果的影响,从而提高视力检测结果的准确性。

Description

视力检测方法及电子设备
本申请要求于2020年11月30日提交中国专利局、申请号为202011387013.0、申请名称为“视力检测方法及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及视力检测技术领域,尤其涉及一种视力检测方法及电子设备。
背景技术
目前的视力检测手段主要是视力表指认,视力表指认对于灯光、距离、用户姿势等测试环境的要求较高。用户可以在医院、配镜中心等专业场所由专业人员主导进行视力表指认,但对于用户来说很不方便。用户也可以通过视力检测设备自行进行视力表指认,但目前的视力检测设备没有充分考虑测试环境对于视力检测结果的影响,从而导致得到的视力检测结果不准确。因此,如何让用户简单便捷得到精度较高的视力检测结果是本领域的技术人员正在研究的问题。
发明内容
本申请实施例公开了一种视力检测方法及电子设备,能够让用户简单便捷地进行视力检测过程,且得到的视力检测结果精度较高。
第一方面,本申请实施例提供了一种视力检测方法,应用于电子设备,该方法包括:显示第一字符;获取第一图像,上述第一图像包括目标用户;根据上述第一图像中上述目标用户的姿势,以及上述目标用户对于上述第一字符的指认结果得到第一检测结果,上述第一检测结果表征上述目标用户的视力等级。
本申请实施例中,电子设备可以根据目标用户的姿势确定表征视力等级的第一检测结果,充分考虑了用户姿势对于视力检测过程的影响。目标用户可以直接通过电子设备得到精度较高的视力检测结果,而无需到特定场所下由专业人员配合进行视力检测,便利性和实用性更高,用户体验感也更好。
在一种可能的实现方式中,上述获取第一图像之前,该方法还包括:获取第二图像,上述第二图像包括上述目标用户;确定上述第二图像中上述目标用户的姿势和预设姿势不同;输出提示信息,上述提示信息用于提示上述目标用户调整姿势,上述第一图像中上述目标用户的姿势为上述预设姿势;或者,调整上述第一字符的显示方式,上述显示方式包括以下一项或多项:显示位置、大小、颜色、粗细、倾斜角度。
本申请实施例中,在获取第一检测结果之前,电子设备可以先对目标用户的姿势进行判断。当目标用户的姿势不为预设姿势时,提示用户进行调整,或者,调整第一字符的显示方式。然后电子设备再重新获取第一图像和第一字符的指认结果,并得到第一检测结果,进一步避免了用户姿势不正确对第一检测结果的影响,提高了第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同,包括:确定上述第二图像中上述目标用户所处位置和预设位置不同;上述提示信息具体 用于提示上述目标用户调整位置,上述第一图像中上述目标用户所处位置为上述预设位置。
本申请实施例中,电子设备可以根据目标用户的实时位置调整第一字符的大小、位置等显示方式,即使目标用户出现走动,目标用户看到的同一个第一字符也是较为一致的,从而避免用户走动而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同,包括:确定上述第二图像中上述目标用户头部歪曲的角度大于或等于预设角度;上述提示信息具体用于提示上述目标用户调整头部歪曲的角度,上述第一图像中上述目标用户头部歪曲的角度小于上述预设角度。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同,包括:确定上述第二图像中上述目标用户眼睛的宽度小于预设宽度;上述提示信息具体用于提示上述目标用户睁大眼睛,上述第一图像中上述目标用户眼睛的宽度大于或等于上述预设宽度。
本申请实施例中,电子设备可以根据实时获取的目标用户的图像信息判断用户姿态(例如头部歪曲的角度、眼睛的宽度等)是否满足要求。若用户姿态不满足要求,电子设备可以提示用户进行调整,或者调整第一字符的显示方式,从而避免用户姿态不正确而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同,包括:确定第一高度和第二高度的差值的绝对值大于或等于预设高度,上述第一高度为上述第二图像中上述目标用户的眼睛距离地面的高度,上述第二高度为上述第一字符的显示位置距离地面的高度;上述提示信息具体用于提示上述目标用户调整所处高度,上述第二高度和第三高度的差值的绝对值小于上述预设高度,上述第三高度为上述第一图像中上述目标用户的眼睛距离地面的高度。
本申请实施例中,当目标用户眼睛的高度和电子设备显示第一字符的高度不一致时,电子设备可以提示用户调整用户的高度或调整第一字符的显示位置,从而避免高度不一致而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述第一图像中上述目标用户的第一眼睛被遮盖,上述目标用户的第二眼睛未被遮盖,上述第一检测结果具体表征上述第二眼睛的视力等级。
本申请实施例中,电子设备可以自动识别用户实际遮挡的眼睛,以此自动确定得到的第一检测结果所对应的用户眼睛,无需用户手动选择,使用起来更加便捷。
在一种可能的实现方式中,上述显示第一字符,包括:显示预设数量个检测区域,上述检测区域中显示有上述第一字符,上述预设数量为上述目标用户的数量,一个上述检测区域用于一个上述目标用户进行视力检测,第一区域中的上述第一字符和第二区域中的上述第一字符相同或不同,上述第一区域和上述第二区域为上述预设数量个检测区域中的任意两个区域。
本申请实施例中,电子设备可以同时对多人进行视力检测,提高了视力检测的效率,用户使用更加便捷。
第二方面,本申请实施例提供了一种电子设备,上述电子设备包括至少一个存储器、至少一个处理器,上述至少一个存储器与上述至少一个处理器耦合,上述至少一个存储器用于存储计算机程序,上述至少一个处理器用于调用上述计算机程序,上述计算机程序包括指令,当上述指令被上述至少一个处理器执行时,使得上述电子设备执行:显示第一字符;获取第 一图像,上述第一图像包括目标用户;根据上述第一图像中上述目标用户的姿势,以及上述目标用户对于上述第一字符的指认结果得到第一检测结果,上述第一检测结果表征上述目标用户的视力等级。
本申请实施例中,电子设备可以根据目标用户的姿势确定表征视力等级的第一检测结果,充分考虑了用户姿势对于视力检测过程的影响。目标用户可以直接通过电子设备得到精度较高的视力检测结果,而无需到特定场所下由专业人员配合进行视力检测,便利性和实用性更高,用户体验感也更好。
在一种可能的实现方式中,上述获取第一图像之前,上述电子设备还用于执行:获取第二图像,上述第二图像包括上述目标用户;确定上述第二图像中上述目标用户的姿势和预设姿势不同;输出提示信息,上述提示信息用于提示上述目标用户调整姿势,上述第一图像中上述目标用户的姿势为上述预设姿势;或者,调整上述第一字符的显示方式,上述显示方式包括以下一项或多项:显示位置、大小、颜色、粗细、倾斜角度。
本申请实施例中,在获取第一检测结果之前,电子设备可以先对目标用户的姿势进行判断。当目标用户的姿势不为预设姿势时,提示用户进行调整,或者,调整第一字符的显示方式。然后电子设备再重新获取第一图像和第一字符的指认结果,并得到第一检测结果,进一步避免了用户姿势不正确对第一检测结果的影响,提高了第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同时,上述电子设备具体执行:确定上述第二图像中上述目标用户所处位置和预设位置不同;上述提示信息具体用于提示上述目标用户调整位置,上述第一图像中上述目标用户所处位置为上述预设位置。
本申请实施例中,电子设备可以根据目标用户的实时位置调整第一字符的大小、位置等显示方式,即使目标用户出现走动,目标用户看到的同一个第一字符也是较为一致的,从而避免用户走动而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同时,上述电子设备具体执行:确定上述第二图像中上述目标用户头部歪曲的角度大于或等于预设角度;上述提示信息具体用于提示上述目标用户调整头部歪曲的角度,上述第一图像中上述目标用户头部歪曲的角度小于上述预设角度。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同时,上述电子设备具体执行:确定上述第二图像中上述目标用户眼睛的宽度小于预设宽度;上述提示信息具体用于提示上述目标用户睁大眼睛,上述第一图像中上述目标用户眼睛的宽度大于或等于上述预设宽度。
本申请实施例中,电子设备可以根据实时获取的目标用户的图像信息判断用户姿态(例如头部歪曲的角度、眼睛的宽度等)是否满足要求。若用户姿态不满足要求,电子设备可以提示用户进行调整,或者调整第一字符的显示方式,从而避免用户姿态不正确而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述确定上述第二图像中上述目标用户的姿势和预设姿势不同时,上述电子设备具体执行:确定第一高度和第二高度的差值的绝对值大于或等于预设高度,上述第一高度为上述第二图像中上述目标用户的眼睛距离地面的高度,上述第二高度为上述第一字符的显示位置距离地面的高度;上述提示信息具体用于提示上述目标用户调整所处高度,上述第二高度和第三高度的差值的绝对值小于上述预设高度,上述第三高度为上述第一图像中上述目标用户的眼睛距离地面的高度。
本申请实施例中,当目标用户眼睛的高度和电子设备显示第一字符的高度不一致时,电子设备可以提示用户调整用户的高度或调整第一字符的显示位置,从而避免高度不一致而带来的误差,提高第一检测结果的准确性。
在一种可能的实现方式中,上述电子设备包括显示屏和升降装置,上述显示屏用于显示上述第一字符;上述调整上述第一字符的显示方式时,上述电子设备具体执行:通过上述升降装置调整上述显示屏距离地面的高度。
本申请实施例中,当目标用户眼睛的高度和电子设备显示第一字符的高度不一致时,电子设备可以通过升降装置自动调整显示屏的高度,从而调整目标用户眼睛的高度。可调整的高度较为灵活,且无需用户调整自身高度,用户使用更加便捷,体验感更好。
在一种可能的实现方式中,上述第一图像中上述目标用户的第一眼睛被遮盖,上述目标用户的第二眼睛未被遮盖,上述第一检测结果具体表征上述第二眼睛的视力等级。
本申请实施例中,电子设备可以自动识别用户实际遮挡的眼睛,以此自动确定得到的第一检测结果所对应的用户眼睛,无需用户手动选择,使用起来更加便捷。
在一种可能的实现方式中,上述显示第一字符,包括:显示预设数量个检测区域,上述检测区域中显示有上述第一字符,上述预设数量为上述目标用户的数量,一个上述检测区域用于一个上述目标用户进行视力检测,第一区域中的上述第一字符和第二区域中的上述第一字符相同或不同,上述第一区域和上述第二区域为上述预设数量个检测区域中的任意两个区域。
本申请实施例中,电子设备可以同时对多人进行视力检测,提高了视力检测的效率,用户使用更加便捷。
第三方面,本申请实施例提供了一种计算机存储介质,包括计算机指令,当上述计算机指令在电子设备上运行时,使得上述电子设备执行本申请实施例中第一方面、第一方面的任意一种实现方式提供的视力检测方法。
第四方面,本申请实施例提供了一种计算机程序产品,当该计算机程序产品在电子设备上运行时,使得该电子设备执行本申请实施例中第一方面、第一方面的任意一种实现方式提供的视力检测方法。
第五方面,本申请实施例提供了一种芯片,上述芯片包括至少一个处理器、接口电路、存储器,上述存储器、上述接口电路和上述至少一个处理器通过线路互联,上述存储器中存储有计算机程序,上述计算机程序被上述至少一个处理器执行时实现本申请实施例中第一方面、第一方面的任意一种实现方式提供的视力检测方法。
可以理解地,上述第三方面提供的计算机存储介质、第四方面提供的计算机程序产品以及第五方面提供的芯片均用于执行第一方面、第一方面的任意一种实现方式提供的视力检测方法。因此,其所能达到的有益效果可参考第一方面所提供的视力检测方法中的有益效果,不再赘述。
附图说明
以下对本申请实施例用到的附图进行介绍。
图1A-图1B是本申请实施例提供的一些视力检测场景的示意图;
图2是本申请实施例提供的一种电子设备的结构示意图;
图3是本申请实施例提供的又一种电子设备的结构示意图;
图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C、图8A-图8D是本申请实施例提供的一些视力检测场景的实施例的示意图;
图9-图14是本申请实施例提供的有一些视力检测方法的流程示意图。
具体实施方式
下面将结合附图对本申请实施例中的技术方案进行清楚、详尽地描述。本申请实施例的实施方式部分使用的术语仅用于对本申请的具体实施例进行解释,而非旨在限定本申请。
请参见图1A,图1A是本申请实施例提供的一种视力检测场景的示意图。如图1A所示,用户可以通过电子设备100自行进行视力表指认。电子设备100显示用户界面110,用户界面110包括多个视力表符号,其中,视力表符号111在用户界面110中被圈出来,用于指示用户对视力表符号111进行判断。电子设备100可以获取用户的判断结果,并根据该判断结果确定下一个圈出来的视力表符号。在该判断结果为正确结果的情况下,下一个圈出来的视力表符号可以和视力表符号111的大小一致,也可以比视力表符号111小。在该判断结果为错误结果的情况下,下一个圈出来的视力表符号可以和视力表符号111的大小一致,也可以比视力表符号111大。
在一些实施例中,电子设备100可以通过摄像头获取用户的手势,并根据用户的手势得到用户的判断结果。例如,用户的手势为握拳且食指向上时,电子设备100确定用户判断视力表符号的指向朝上,用户的判断结果和用户界面110中的视力表符号111的指向一致,因此用户的判断结果为正确结果。用户的手势为握拳且食指向左时,电子设备确定用户判断视力表符号的指向朝左,用户的判断结果和用户界面110中的视力表符号111的指向不一致,因此用户的判断结果为错误结果。
在一些实施例中,电子设备100也可以通过摄像头获取用户手臂的运动轨迹,并根据用户手臂的运动轨迹得到用户的判断结果。例如,用户手臂的运动轨迹为自下而上时,电子设备100确定用户判断视力表符号的指向朝上,用户的判断结果和用户界面110中的视力表符号111的指向一致,因此用户的判断结果为正确结果。用户手臂的运动轨迹为自上而下时,电子设备100确定用户判断视力表符号的指向朝下,用户的判断结果和用户界面110中的视力表符号111的指向不一致,因此用户的判断结果为错误结果。
在一些实施例中,电子设备100也可以通过麦克风获取用户的语音信息,并根据用户的语音信息得到用户的判断结果。例如,用户的语音信息包括“上”、“向上、“上边”等词语时,电子设备100确定用户判断视力表符号的指向朝上,用户的判断结果和用户界面110中的视力表符号111的指向一致,因此用户的判断结果为正确结果。用户的语音信号包括“右”、“向右”、“右边”等词语时,电子设备100确定用户判断视力表符号的指向朝右,用户的判断结果和用户界面110中的视力表符号111的指向不一致,因此用户的判断结果为错误结果。
不限于图1A示例的情况,在具体实现中,电子设备100还可以播放语音信息,该语音信息用于指示用户对视力表符号111进行判断。电子设备100还可以在用户界面110仅显示一个视力表符号和提示信息,该提示信息用于提示用户对当前显示的视力表符号进行判断,具体示例可参见图1B。
如图1B所示,电子设备100可以显示用户界面120,用户界面120包括一个视力表符号121和提示信息122。提示信息122用于指示用户对视力表符号121进行判断。电子设备100可以获取用户的判断结果,并根据该判断结果确定下一个显示的视力表符号,并用该视力表 符号替换掉视力表符号121。下一个显示的视力表符号的说明和图1A一致,不再赘述。
可以理解地,视力检测过程中,电子设备100按照上述方式不断获取用户对于不同视力表符号的判断结果,当判断结果的数量大于预设数量时,电子设备100可以根据得到的多个判断结果得到用户一只眼睛的视力检测结果。然后,电子设备100可以提示用户测试另一只眼睛,用户测试另一只眼睛的过程和上述测试一只眼睛的过程类似,最后电子设备100可以得到用户两只眼睛的视力检测结果。
本申请实施例对视力检测过程中,电子设备100显示的用户界面,电子设备100提示用户对视力表符号进行判断的方式,电子设备100获取用户的判断结果的方式不作限定。
本申请实施例中涉及的电子设备可以是智慧屏、智能电视等大屏设备,也可以是手机,平板电脑,桌面型、膝上型、笔记本电脑,超级移动个人计算机(Ultra-mobile Personal Computer,UMPC),手持计算机,上网本,个人数字助理(Personal Digital Assistant,PDA),可穿戴电子设备等设备。
接下来介绍本申请实施例中提供的示例性的电子设备。
请参见图2,图2示出了一种电子设备100的结构示意图。
电子设备100可以包括处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,气压传感器180C,磁传感器180D,加速度传感器180E,距离传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,骨传导传感器180M等。
可以理解的是,本发明实施例示意的结构并不构成对电子设备100的具体限定。在本申请另一些实施例中,电子设备100可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。
控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从上述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。
在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous  receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purpose input/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K,充电器,闪光灯,摄像头193等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现电子设备100的触摸功能。
I2S接口可以用于音频通信。在一些实施例中,处理器110可以包含多组I2S总线。处理器110可以通过I2S总线与音频模块170耦合,实现处理器110与音频模块170之间的通信。在一些实施例中,音频模块170可以通过I2S接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。
PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块170与无线通信模块160可以通过PCM总线接口耦合。在一些实施例中,音频模块170也可以通过PCM接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。上述I2S接口和上述PCM接口都可以用于音频通信。
UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。例如:处理器110通过UART接口与无线通信模块160中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块170可以通过UART接口向无线通信模块160传递音频信号,实现通过蓝牙耳机播放音乐的功能。
MIPI接口可以被用于连接处理器110与显示屏194,摄像头193等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serial interface,DSI)等。在一些实施例中,处理器110和摄像头193通过CSI接口通信,实现电子设备100的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现电子设备100的显示功能。
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头193,显示屏194,无线通信模块160,音频模块170,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。
USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口130可以用于连接充电器为电子设备100充电,也可以用于电子设备100与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。
可以理解的是,本发明实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备100的结构限定。在本申请另一些实施例中,电子设备100也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。
充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。在一些有线充电的实施例中,充电管理模块140可以通过USB接口130接收有线充电器的充电输入。在一些无线充电的实施例中,充电管理模块140可以通过电子设备100的无线充电线圈接收无线充电输入。充电管理模块140为电池142充电的同时,还可以通过电源管理模块141为电子设备供电。
电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,显示屏194,摄像头193,和无线通信模块160等供电。电源管理模块141还可以用于监测电池容量,电池循环次数,电池健康状态(漏电,阻抗)等参数。在其他一些实施例中,电源管理模块141也可以设置于处理器110中。在另一些实施例中,电源管理模块141和充电管理模块140也可以设置于同一个器件中。
电子设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。
天线1和天线2用于发射和接收电磁波信号。电子设备100中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。
移动通信模块150可以提供应用在电子设备100上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。
无线通信模块160可以提供应用在电子设备100上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。
在一些实施例中,电子设备100的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得电子设备100可以通过无线通信技术与网络以及其他设备通信。上述无线通信技术可以包括全球移动通讯系统(global system for mobile communications,GSM),通用分组无线服务(general packet radio service,GPRS),码分多址接入(code division multiple access,CDMA),宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-division code division multiple access,TD-SCDMA),长期演进(long term evolution,LTE),BT,GNSS,WLAN,NFC,FM,和/或IR技术等。上述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system, GLONASS),北斗卫星导航系统(beidou navigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。
电子设备100通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。
显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。在一些实施例中,电子设备100可以包括1个或N个显示屏194,N为大于1的正整数。
电子设备100可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。
ISP用于处理摄像头193反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将上述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头193中。
摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备100可以包括1个或N个摄像头193,N为大于1的正整数。
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备100在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。
视频编解码器用于对数字视频压缩或解压缩。电子设备100可以支持一种或多种视频编解码器。这样,电子设备100可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备100的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。
外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。
内部存储器121可以用于存储计算机可执行程序代码,上述可执行程序代码包括指令。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件, 闪存器件,通用闪存存储器(universal flash storage,UFS)等。处理器110通过运行存储在内部存储器121的指令,和/或存储在设置于处理器中的存储器的指令,执行电子设备100的各种功能应用以及数据处理。
电子设备100可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。
音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。
扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。电子设备100可以通过扬声器170A收听音乐,或收听免提通话。
受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当电子设备100接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。
麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。电子设备100可以设置至少一个麦克风170C。在另一些实施例中,电子设备100可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,电子设备100还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。
耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。
本申请实施例中,电子设备100可以通过显示屏194显示用于视力检测的用户界面,该用户界面可以包括至少一个视力表符号,可选地,该用户界面中用于用户检测的视力表符号可以被标注出来,例如图1A所示的用户界面110、图1B所示的用户界面120。电子设备100可以在上述用户界面显示提示信息,或者,电子设备100可以通过扬声器170A或受话器170B播放语音提示信息,以使用户对上述用户界面中的视力表符号进行判断。然后,电子设备100可以通过摄像头193获取用户的图像信息,然后根据用户的图像信息得到用户的判断结果。例如,上述用户的图像信息可以包括用户的手势或用户手臂的运动轨迹,电子设备100可以根据用户的手势或用户手臂的运动轨迹得到用户的判断结果。不限于此,电子设备100还可以通过麦克风170C获取用户的语音信息,然后根据用户的语音信息得到用户的判断结果。例如,上述用户的语音信号包括“上”、“下”、“左”、“右”等指示方向的词语,电子设备100可以根据这些指向方向的词语得到用户对于视力表符号的指向的判断结果。
获取用户对于视力表符号的判断结果后,电子设备100可以根据用户的判断结果确定下一个用于用户判断的视力表符号,并在显示屏194上显示该视力表符号,可选地,该视力表符号在显示屏194显示的用户界面上被标注出来,以使用户继续对该视力表符号进行判断。
电子设备100可以按照上述过程持续获取用户对于不同视力表符号的判断结果,当判断结果的数量大于预设数量时,电子设备100可以根据这多个判断结果得到用户一只眼睛的视力检测结果。然后,电子设备100可以在用户界面上显示提示信息,或者,电子设备100可以通过扬声器170A或受话器170B播放语音提示信息,以提示用户测试另一只眼睛,具体测试过程和上述过程类似,最后,电子设备100可以得到用户两只眼睛的视力检测结果。电子 设备100可以通过显示屏194显示用户两只眼睛的视力检测结果,或者,可以通过扬声器170A或受话器170B播放用户两只眼睛的视力检测结果。
在一些实施例中,电子设备100可以存储上述用户两只眼睛的视力检测结果,例如将上述视力检测结果存储到内部存储器121或外部存储器接口120连接的外部存储卡。在另一些实施例中,电子设备100可以将上述视力检测结果发送到连接的云端服务器中,当需要使用时再从云端服务器获取,从而减小电子设备100的存储压力。用户可以通过电子设备100获取到历史的视力检测结果,从而判断视力的变化趋势。用户无需定期花费较多的时间和精力去医院、配镜中心等专业场所进行视力检测过程。这样有助于用户长期追踪视力情况,当视力变差时,可以及时调整用眼习惯或更换眼镜,从而避免视力继续变差。
压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。电子设备100根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,电子设备100根据压力传感器180A检测上述触摸操作强度。电子设备100也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。
陀螺仪传感器180B可以用于确定电子设备100的运动姿态。在一些实施例中,可以通过陀螺仪传感器180B确定电子设备100围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器180B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器180B检测电子设备100抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消电子设备100的抖动,实现防抖。陀螺仪传感器180B还可以用于导航,体感游戏场景。
气压传感器180C用于测量气压。在一些实施例中,电子设备100通过气压传感器180C测得的气压值计算海拔高度,辅助定位和导航。
磁传感器180D包括霍尔传感器。电子设备100可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当电子设备100是翻盖机时,电子设备100可以根据磁传感器180D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。
加速度传感器180E可检测电子设备100在各个方向上(一般为三轴)加速度的大小。当电子设备100静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。
距离传感器180F,用于测量距离。电子设备100可以通过红外或激光测量距离。在一些实施例中,拍摄场景,电子设备100可以利用距离传感器180F测距以实现快速对焦。
接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。电子设备100通过发光二极管向外发射红外光。电子设备100使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定电子设备100附近有物体。当检测到不充分的反射光时,电子设备100可以确定电子设备100附近没有物体。电子设备100可以利用接近光传感器180G检测用户手持电子设备100贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋 模式自动解锁与锁屏。
环境光传感器180L用于感知环境光亮度。电子设备100可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环境光传感器180L还可以与接近光传感器180G配合,检测电子设备100是否在口袋里,以防误触。
指纹传感器180H用于采集指纹。电子设备100可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。
温度传感器180J用于检测温度。在一些实施例中,电子设备100利用温度传感器180J检测的温度,执行温度处理策略。例如,当温度传感器180J上报的温度超过阈值,电子设备100执行降低位于温度传感器180J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,电子设备100对电池142加热,以避免低温导致电子设备100异常关机。在其他一些实施例中,当温度低于又一阈值时,电子设备100对电池142的输出电压执行升压,以避免低温导致的异常关机。
触摸传感器180K,也称“触控器件”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于电子设备100的表面,与显示屏194所处的位置不同。
骨传导传感器180M可以获取振动信号。在一些实施例中,骨传导传感器180M可以获取人体声部振动骨块的振动信号。骨传导传感器180M也可以接触人体脉搏,接收血压跳动信号。在一些实施例中,骨传导传感器180M也可以设置于耳机中,结合成骨传导耳机。音频模块170可以基于上述骨传导传感器180M获取的声部振动骨块的振动信号,解析出语音信号,实现语音功能。应用处理器可以基于上述骨传导传感器180M获取的血压跳动信号解析心率信息,实现心率检测功能。
按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。电子设备100可以接收按键输入,产生与电子设备100的用户设置以及功能控制有关的键信号输入。
本申请实施例中,电子设备100可以通过压力传感器180A和/或触摸传感器180K检测到用户作用于显示屏194的用户操作(例如点击操作),响应于该用户操作,电子设备100可以开始执行视力检测过程。或者,电子设备100可以通过压力传感器180A和/或触摸传感器180K检测到用户作用于按键190的用户操作(例如按压操作),响应于该用户操作,电子设备100可以开始执行视力检测过程。或者,电子设备100可以通过麦克风170C获取用户的语音信息(例如“视力测试”),响应于该语音信息,电子设备100可以开始执行视力检测过程。
在一些实施例中,电子设备100还可以通过提示用户执行相应的操作,并根据用户操作确定当前用户是否为目标用户,电子设备100需对目标用户进行视力检测。例如,电子设备100可以提示用户执行特定手势(如OK手势),并通过摄像头193获取用户的图像信息,当用户的图像信息包括上述特定手势的信息时,电子设备100确定当前用户为目标用户,并针对当前用户进行视力检测。或者,电子设备100还可以提示用户点击显示屏194显示的特定控件,电子设备100可以通过压力传感器180A和/或触摸传感器180K检测到用户作用于特定控件的用户操作,响应于该用户操作,电子设备100确定当前用户为目标用户,并针对当前用户进行视力检测。
本申请实施例对如何确定目标用户的方式不作限定。本申请实施例对于如何确定开始执行视力检测过程的方式不作限定。
在一些实施例中,电子设备100可以在视力检测过程中持续获取用户的图像信息,当该图像信息包括的用户发生改变,即当前用户不是目标用户时,电子设备100可以提示当前进行视力检测的用户和之前不一致,并暂停当前的视力检测过程。在预设时段内,若电子设备100获取的用户的图像信息包括目标用户,电子设备100可以继续执行上述视力检测过程。在预设时段内,若电子设备100获取的用户的图像信息不包括目标用户,电子设备100可以直接结束当前的视力检测过程,或者,电子设备100可以保持暂停当前的视力检测过程,直到目标用户下一次触发视力检测过程,电子设备100才继续执行上述视力检测过程。在预设时段内,电子设备100可以检测用于指示重新开始视力检测过程的用户操作(例如语音信息:“重新开始视力检测”),响应于该用户操作,电子设备100可以直接结束当前的视力检测过程,并重新开始执行新的视力检测过程。
马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏194不同区域的触摸操作,马达191也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。
指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。
SIM卡接口195用于连接SIM卡。SIM卡可以通过插入SIM卡接口195,或从SIM卡接口195拔出,实现和电子设备100的接触和分离。电子设备100可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口195可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口195可以同时插入多张卡。上述多张卡的类型可以相同,也可以不同。SIM卡接口195也可以兼容不同类型的SIM卡。SIM卡接口195也可以兼容外部存储卡。电子设备100通过SIM卡和网络交互,实现通话以及数据通信等功能。在一些实施例中,电子设备100采用eSIM,即:嵌入式SIM卡。eSIM卡可以嵌在电子设备100中,不能和电子设备100分离。
电子设备100的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。例如,分层架构的软件系统可以是安卓(Android)系统,也可以是华为移动服务(huawei mobile services,HMS)系统。本申请实施例以分层架构的Android系统为例,示例性说明电子设备100的软件结构。
图3是本发明实施例的电子设备100的软件结构框图。
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。
应用程序层可以包括一系列应用程序包。
如图3所示,应用程序包可以包括相机,日历,地图,音乐,短信息,图库,通话,导航,蓝牙,视力检测等应用程序。
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。
如图3所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。
窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。上述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。
电话管理器用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。
资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。
通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。
Android Runtime包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL)等。
表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。
媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。
三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。
2D图形引擎是2D绘图的绘图引擎。
内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。
不限于图3示例的情况,在具体实现中,视力检测也可以不是一个安装在电子设备100上的应用程序包,而是在线的应用,例如网页应用、小程序应用等,本申请实施例对此不作限定。
下面结合视力检测场景,示例性说明电子设备100软件以及硬件的工作流程。其中,该视力检测场景以用户对一个视力表符号的判断过程为例进行说明。
当触摸传感器180K接收到触摸操作,相应的硬件中断被发给内核层。内核层将触摸操作加工成原始输入事件(包括触摸坐标,触摸操作的时间戳等信息)。原始输入事件被存储在内核层。应用程序框架层从内核层获取原始输入事件,识别该输入事件所对应的控件。以该触摸操作是触摸单击操作,该单击操作所对应的控件为视力检测应用的图标控件为例,视力 检测应用调用应用框架层的接口,启动视力检测应用,进而通过调用内核层启动显示驱动,通过显示屏194显示用于视力检测的用户界面,该用户界面可以包括至少一个视力表符号,可选地,该用户界面中用于用户检测的视力表符号可以被标注出来,例如图1A所示的用户界面110、图1B所示的用户界面120。
然后,视力检测应用通过调用内核层启动音频驱动,通过扬声器170A提示用户对上述用户界面显示的一个视力表符号进行判断。并且,视力检测应用还通过调用内核层启动摄像头驱动,通过摄像头193捕获包括用户的静态图像或视频(简称用户的图像信息)。处理器110根据用户的图像信息得到用户对于视力表符号的判断结果,然后根据该判断结果确定下一个用于用户判断的视力表符号。
可以理解地,上述视力检测过程中,电子设备100直接根据用户的图像信息或语音信息得到用户对于视力表符号的判断结果,从而得到用户的视力检测结果。并未考虑到视力检测过程中用户可能出现走动,用户姿态不正确(例如头部歪曲、眯眼),用户遮挡左右眼出错,用户高度不合适等问题对视力检测结果的影响,从而导致得到的视力检测结果不准确。
本申请实施例提供了一种视力检测方法及电子设备,电子设备可以实时判断用户位置、用户姿态、用户高度等测试条件是否满足要求,若不满足要求则提示用户进行调整或者电子设备进行调整,调整后再进行视力检测过程,得到的视力检测结果更准确。并且,电子设备还可以根据用户不正确的姿态对得到的视力检测结果进行校正补偿,进一步提高得到的视力检测结果的准确性。
下面介绍本申请实施例涉及的应用场景以及该场景下的人机交互示意图。以下实施例示出的应用场景以图1B所示的视力检测场景为例进行说明,其中,电子设备100显示的用户界面为图1B所示的用户界面120。
请参见图4A,图4A是本申请实施例提供的又一种视力检测场景的示意图。其中,电子设备100可以包括摄像头193,并通过摄像头193获取用户的图像信息,用户的图像信息用于电子设备100实现视力检测过程。
可以理解的是,图4A示出的摄像头193在电子设备100上的位置和数量仅用于解释本申请实施例,不应构成限定。
如图4A所示,用户通过电子设备100进行视力检测过程,视力检测过程中,电子设备100可以通过摄像头193持续获取用户的图像信息。用户处于位置A时,电子设备100获取到的用户图像为图4B的(a)所示的图像400。此时,电子设备100可以显示用户界面120,用户界面120可以包括视力表符号121和提示信息122,电子设备100可以提示用户对视力表符号121进行判断。
其中,视力表符号121在用户界面120中的位置、视力表符号121的大小可以是根据图像400确定的。具体地,电子设备100可以根据图像400和预先录入的用户图像得到用户与电子设备100的相对位置,例如根据图像400中的人脸长度、预先获取的图像中的人脸长度得到用户和电子设备100的距离、用户更接近电子设备100的左侧或右侧。然后,电子设备100可以根据用户与电子设备100的相对位置确定视力表符号的大小和位置,并按照确定的视力表符号的大小和位置在用户界面120上显示视力表符号121。例如,用户和电子设备100的距离较近时,电子设备100显示的视力表符号121较小。用户和电子设备的距离较远时,电子设备100显示的视力表符号121较大。用户更接近电子设备100的左侧时,视力表符号121在用户界面120中的位置也可以偏电子设备100的左侧。用户更接近电子设备100的右 侧时,视力表符号121在用户界面120中的位置也可以偏电子设备100的右侧。
如图4A所示,用户从位置A移动至位置B,然后在位置B给出视力表符号121的判断结果。用户处于位置B时,电子设备100获取到的用户图像为图4B的(b)所示的图像410。如图4B所示,图像400中的用户和图像410中的用户大小一致,但位置不同,图像410中的用户比图像400中的用户更靠右。因此,电子设备100可以根据图像400和图像410得到用户位置发生变化,其中,从用户角度来看,移动后的位置(即位置B)位于移动前的位置(即位置A)的左侧。若电子设备100将用户处于位置B时给出的判断结果作为用户对于视力表符号121的判断结果,则根据该判断结果得到的视力检测结果会不准确。因此,电子设备100可以提示用户回到原位置,并提示用户重新给出视力表符号121的判断结果。
可选地,电子设备100也可以根据图像410调整用户界面120中视力表符号121的位置,调整前的用户界面120如图4C的(a)所示,调整后的用户界面120如图4C的(b)所示。图4C的(b)所示的视力表符号121相比图4C的(a)所示的视力表符号121更靠右。电子设备100调整用户界面120中视力表符号121的位置前,处于位置B的用户看向视力表符号121的视线与目标轴线偏离较大。电子设备100调整用户界面120中视力表符号121的位置后,处于位置B的用户看向视力表符号121的视线和目标轴线偏离较小。这样使得处于任意位置的用户看向视力表符号121的视线和目标视线都较接近,目标轴线为与电子设备100的显示屏所在平面垂直的轴线。用户在医院、配镜中心等专业场所进行视力测试时,用户看向视力表符号的视线和视力表所在平面垂直的轴线都较接近,这样得到的判断结果更准确,根据该判断结果得到的视力检测结果也会更准确。
其中,电子设备100调整用户界面120中视力表符号121的位置前后,视力表符号121在用户界面120中的移动距离可以称为第一预设距离,即图4C的(a)所示的视力表符号121所在位置和图4C的(b)所示的视力表符号121所在位置之间的距离可以称为第一预设距离。第一预设距离可以和用户的移动距离成正比。用户的移动距离是用户从位置A移动至位置B的距离,用户的移动距离可以是根据第二预设距离得到的。用户移动位置前后,用户在用户图像中的移动距离可以称为第二预设距离,即图4B的(a)所示的用户所在位置和图4B的(b)所示的用户所在位置之间的距离可以称为第二预设距离。
不限于上述示例的确定用户与电子设备100的相对位置的方式,在具体实现中,电子设备100还可以包括飞行时间法(time of flight,TOF)传感器,通过TOF传感器获取用户与电子设备100的相对位置,本申请实施例对此不作限定。
在一些实施例中,用户也可以按照图4D所示实施例移动,即从位置A移动至位置C。用户处于位置A时,电子设备100获取到的用户图像为图4E的(a)所示的图像400,用户处于位置C时,电子设备100获取到的用户图像为图4E的(b)所示的图像420。如图4E所示,图像400中的用户和图像420中的用户位置相同,但图像400中的用户小于图像420中的用户。因此,电子设备100可以根据图像400和图像420得到用户位置发生变化,其中,相比移动前的位置(即位置A),移动后的位置(即位置C)和电子设备100的距离更近。若电子设备100将用户处于位置C时给出的判断结果作为用户对于视力表符号121的判断结果,则根据该判断结果得到的视力检测结果会不准确。因此,电子设备100可以提示用户回到原位置,并提示用户重新给出视力表符号121的判断结果。
可选地,电子设备100也可以根据图像420调整用户界面120中视力表符号121的大小,调整前的用户界面120如图4F的(a)所示,调整后的用户界面120如图4F的(b)所示。图4F的(b)中的视力表符号121小于图4F的(a)中的视力表符号121。电子设备100调 整用户界面120中视力表符号121的大小前,电子设备100显示的视力表符号121的大小是根据位置A和电子设备100的距离得到的。电子设备100调整用户界面120中视力表符号121的大小后,电子设备100显示的视力表符号121的大小是根据位置C和电子设备100的距离得到的。这样使处于任意位置的用户看到的视力表符号的大小都更接近目标大小,目标大小为用户在医院、配镜中心等专业场所进行视力测试时需判断的视力表符号的大小,这样得到的判断结果更准确,根据该判断结果得到的视力检测结果也会更准确。其中,视力表符号121的缩放比例可以和用户的移动距离成正比。视力表符号121的缩放比例为:图4F的(b)中的视力表符号121和图4F的(a)中的视力表符号121的大小比值。用户的移动距离可以根据用户在用户图像中的缩放比例得到,用户在用户图像中的缩放比例为:图4E的(b)中的用户和图4E的(a)中的用户的大小比值。
不限于图4A-图4F所示的情况,在具体实现中,电子设备100也可以判断实时获取的用户所在位置是否为预设位置,预设位置是电子设备100预设的固定位置。若不是预设位置,电子设备100可以提示用户调整所在位置为预设位置,并根据预设位置确定显示的视力表符号的大小和位置,以及显示视力表符号。然后,电子设备100再获取用户对视力表符号的判断结果。
在一些实施例中,用户给出视力表符号121的判断结果时,用户眯眼,具体的视力检测场景如图5A所示。若用户未眯眼,则电子设备100获取到的用户图像为图5B的(a)所示的图像400,图像400中用户眼睛401的宽度为图5C所示的d 1。若用户眯眼,则电子设备100获取到的用户图像为图5B的(b)所示的图像510,图像510中用户眼睛511的宽度为图5C所示的d 2。如图5C所示,用户的眯眼程度θ如下式所示:
Figure PCTCN2021133754-appb-000001
其中,若d 2>d 1,则可以将d 2设置为d 1。用户的眯眼程度θ的取值范围为[0,1],若θ=0,则表示用户未眯眼,若θ=1,则表示用户闭眼。
若电子设备100直接将用户眯眼时给出的判断结果作为用户对于视力表符号121的判断结果,则根据该判断结果得到的视力检测结果会不准确。因此,电子设备100可以提示用户睁大眼睛,并提示用户重新给出视力表符号121的判断结果。用户重新给出判断结果时,若电子设备100获取到的用户图像中用户眼睛的宽度小于d 1,即用户的眯眼程度θ大于0,则电子设备100可以记录此时的眯眼程度θ,并将上述重新给出的判断结果作为用户对于视力表符号121的判断结果。电子设备100获取视力表符号121的判断结果后继续进行下一个视力表符号的检测过程,当已检测的视力表符号的数目大于预设数量时,电子设备100可以根据多个视力表符号的判断结果得到用户一只眼睛的视力检测结果。电子设备100可以根据记录的多个眯眼程度θ对上述视力检测结果进行校正补偿,以此得到精度、准确度更高的视力检测结果。
可选地,电子设备100可以预存用户的眯眼程度和补偿值的第一对应关系,该补偿值用于对视力检测结果进行校正补偿。第一对应关系可以是电子设备100或其他服务器等根据多次视力检测过程得到的,即第一对应关系是根据大量真实测试的数据得到的。然后,基于上述第一对应关系,电子设备100可以确定和上述记录的多个眯眼程度θ的平均值对应的补偿值,并根据该补偿值对上述视力检测结果进行校正补偿。
例如,第一对应关系可以用函数f表示,补偿值可以用ε表示,则ε=f(θ),f的曲线可以可参见图5D所示的曲线。如图5D所示,横轴为用户的眯眼程度θ,纵轴为视力检测结果的补偿值ε。假设上述记录的多个眯眼程度θ的平均值为0.5,ε=f(θ)=0.06,上述视力检测结果为1.0,则根据ε对上述视力检测结果进行校正补偿后得到的视力检测结果为1.0+0.06=1.06。
可以理解地,若电子设备100获取到的用户图像中用户眼睛的宽度等于d 1,即用户的眯眼程度θ等于0,则正常进行视力检测过程。当已检测的视力表符号的数目大于预设数量时,若电子设备100记录的多个眯眼程度θ均等于0,则电子设备100无需对得到的视力检测结果进行校正补偿。
不限于上述列举的情况,在具体实现中,用户重新给出判断结果时,若电子设备100得到的用户的眯眼程度θ大于或等于预设眯眼值(例如0.5)且小于或等于1,则电子设备100再次提示用户睁大眼睛,并提示用户重新给出视力表符号121的判断结果。直到电子设备100得到的用户的眯眼程度θ大于或等于0且小于预设眯眼值,电子设备100记录此时的眯眼程度θ,并将上述重新给出的判断结果作为用户对于视力表符号121的判断结果。本申请实施例对具体判断过程不作限定。
不限于上述列举的情况,在具体实现中,也可以不在d 2>d 1时,将d 2设置为d 1,则用户的眯眼程度θ可以小于0。电子设备100可以在眯眼程度θ小于或等于0时,确定用户未眯眼。或者,电子设备100也可以在眯眼程度θ在预设区间内时,确定用户未眯眼,预设区间例如是[0,0.1]。本申请实施例对眯眼的判断方式不作限定。
不限于上述列举的情况,在具体实现中,电子设备100也可以首先确定上述记录的多个眯眼程度θ所对应的补偿值,然后计算这多个补偿值的平均值,该平均值为用于对视力检测结果进行校正补偿的补偿值,本申请实施例对得到补偿值的方式不作限定。
在一些实施例中,用户给出视力表符号121的判断结果时,用户的头部歪曲,具体的视力检测场景如图5E所示。若用户头部未歪曲,则电子设备100获取到的用户图像为图5F的(a)所示的图像400,图像400中用户头部的中轴线为第一轴线。若用户头部歪曲,则电子设备100获取到的用户图像为图5F的(b)所示的图像520,图像520中用户头部的中轴线为第二轴线,第一轴线和第二轴线之间的夹角为第一夹角。其中,第一夹角用于表示用户头部的歪曲程度,若第一夹角为0,则表示用户头部未歪曲,第一夹角的取值范围为[0,90度]。
若电子设备100直接将上述判断结果作为用户对于视力表符号121的判断结果,则根据该判断结果得到的视力检测结果会不准确。因此,电子设备100可以提示用户摆正头部,并提示用户重新给出视力表符号121的判断结果。用户重新给出判断结果时,若电子设备100获取到的用户图像中第一夹角仍大于0,则电子设备100可以记录此时的第一夹角,并将上述重新给出的判断结果作为用户对于视力表符号121的判断结果。电子设备100获取视力表符号121的判断结果后继续进行下一个视力表符号的检测过程,当已检测的视力表符号的数目大于预设数量时,电子设备100可以根据多个视力表符号的判断结果得到用户一只眼睛的视力检测结果。电子设备100可以根据记录的多个第一夹角对得到的视力检测结果进行校正补偿,以此得到精度、准确度更高的视力检测结果。
可选地,电子设备100可以预存用户头部歪曲程度和补偿值的第二对应关系,该补偿值用于对视力检测结果进行校正补偿。第二对应关系可以是电子设备100或其他服务器等根据多次视力检测过程得到的,即第二对应关系是根据大量真实测试的数据得到的。然后,基于上述第二对应关系,电子设备100可以确定和上述记录的多个第一夹角的平均值对应的视力检测结果的补偿值,并根据该补偿值对上述视力检测结果进行校正补偿。例如,上述记录的多个第一夹角的平均值为45度,上述用户一只眼睛的视力检测结果为1.0,上述对应关系中与头部歪曲程度为45度对应的补偿值是0.05,则电子设备100补偿得到的视力检测结果是1.0+0.05=1.05。
可以理解地,若电子设备100获取到的用户图像中用户头部的中轴线为第一轴线,即第一夹角等于0,则正常进行视力检测过程。当已检测的视力表符号的数目大于预设数量时, 若电子设备100记录的多个第一夹角均等于0,则电子设备100无需对得到的视力检测结果进行校正补偿。
不限于上述列举的情况,在具体实现中,用户重新给出判断结果时,若电子设备100得到的第一夹角大于或等于预设角度(例如60度)且小于或等于90度,则电子设备100再次提示用户摆正头部,并提示用户重新给出视力表符号121的判断结果。直到电子设备100得到的第一夹角大于或等于0且小于或等于预设角度,电子设备100记录此时的第一夹角,并将上述重新给出的判断结果作为用户对于视力表符号121的判断结果。本申请实施例对具体判断过程不作限定。
不限于上述列举的情况,在具体实现中,第二轴线在第一轴线的左侧时第一夹角和第二轴线在第一轴线的右侧时第一夹角可以不同,则第一夹角的取值范围可以为[-90度,90度]或[0,180度],电子设备100可以在第一夹角的取值不为0时,确定用户头部歪曲。或者,电子设备100也可以在第一夹角在预设区间内时,确定用户头部未歪曲,预设区间例如是[0,10度]。本申请实施例对于用户头部歪曲的判断方式不作限定。
不限于上述列举的情况,在具体实现中,电子设备100也可以首先确定上述记录的多个第一夹角所对应的补偿值,然后计算这多个补偿值的平均值,该平均值为用于对视力检测结果进行校正补偿的补偿值,本申请实施例对得到补偿值的方式不作限定。
不限于上述列举的情况,在具体实现中,电子设备100也可以分别确定每个视力表符号的判断结果的补偿值,然后通过补偿值校正补偿对应的视力表符号的判断结果,最后根据多个校正补偿过的视力表符号的判断结果得到用户的视力检测结果,本申请实施例对于校正补偿的具体方式不作限定。
不限于上述列举的情况,在具体实现中,电子设备100也可以不提示用户调整位置、头部、眼睛等姿态,而是直接获取用户对于视力表符号的判断结果,并对其进行校正补偿,以得到用户的视力检测结果。
在一些实施例中,电子设备100提示用户遮挡一只眼睛,以对用户的另一只眼睛进行视力测试,但用户可能未遮挡眼睛或者用户遮挡上述另一只眼睛,从而导致得到的视力检测结果不正确。或者,电子设备100对用户的一只眼睛测试完毕,提示用户遮挡另一只眼睛,但用户没有更换遮挡的眼睛为上述另一只眼睛,从而导致得到的视力检测结果不正确。本申请实施例中,电子设备100可以通过摄像头193获取用户图像,并根据用户图像中用户的眼睛和手的相对位置确定用户是否遮挡眼睛,以及用户实际遮挡的眼睛,从而自动确定用户左右眼的视力检测结果,具体示例如下图6A-图6C所示。
请参见图6A,图6A是本申请实施例提供的一种确定用户遮挡的眼睛的示意图。
如图6A所示,电子设备100开始进行视力检测过程后,首先获取到的用户图像为图像610。电子设备100可以在用户图像610中确定检测区域611,然后从检测区域611中提取用户的眼睛和手的特征。当电子设备100确定提取特征后的检测区域610包括两只眼睛时,可以得到判断结果:用户未遮挡眼睛。此时,电子设备100可以提示用户遮挡一只眼睛(例如提示用户遮挡右眼),用户遮挡眼睛后,电子设备100获取到的用户图像为图6B所示的图像620。电子设备100可以在用户图像620中确定检测区域621,然后从检测区域621中提取上述特征。当电子设备100确定提取特征后的检测区域621包括一只眼睛和一只手,且手位于眼睛的左侧时,可以得到判断结果:用户遮挡的眼睛为左眼。即使电子设备100开始提示用户遮挡的是右眼,电子设备100也可以得到用户实际遮挡的眼睛是左眼。电子设备100可以 对用户进行视力检测并得到用户左眼的视力检测结果。
电子设备100对用户的左眼测试完毕后,可以提示用户遮挡另一只眼睛(即右眼)。若电子设备100此时获取到的提取特征后的检测区域和图6B所示的提取特征后的检测区域621相同,则电子设备100可以确定用户未更换遮挡眼睛,因此再次提示用户遮挡另一只眼睛(即右眼)。当电子设备100获取到的用户图像为图6C所示的图像630时,电子设备100可以在用户图像630中确定检测区域631,然后从检测区域631中提取上述特征。当电子设备100确定提取特征后的检测区域631包括一只眼睛和一只手,且手位于眼睛的右侧时,可以得到判断结果:用户遮挡的眼睛为右眼。此时,电子设备100可以继续对用户进行视力检测并得到用户右眼的视力检测结果。
不限于上述示例的情况,在具体实现中,电子设备100也可以根据其他用于遮挡用户眼睛的物体(例如眼罩)和用户眼睛的相对位置确定用户是否遮挡眼睛,以及用户实际遮挡的眼睛,本申请实施例对此不作限定。但可以理解地,电子设备100根据用户眼睛和手的相对位置确定用户是否遮挡眼睛,以及用户实际遮挡的眼睛,用户无需上述眼罩等额外的辅助物就能进行视力检测,使用更加方便。
在一些实施例中,用户在医院、配镜中心等专业场所进行视力测试时,用户眼睛的高度和视力表中视力表符号的高度一般较为一致,而用户通过电子设备100进行视力检测时,用户眼睛的高度和电子设备100显示的视力表符号的高度可能差距较大,因此,上述情况下得到的视力检测结果不够准确。本申请实施例中,电子设备100可以调整视力表符号在用户界面上的显示位置,以使用户眼睛的高度和电子设备100显示的视力表符号的高度较为一致,得到的视力检测结果较为准确,具体过程如图7A所示。
请参见图7A,图7A是本申请实施例提供的一种调整视力表符号的显示位置前后的对比图。图7A的(a)为调整视力表符号的显示位置前的示意图,图7A的(b)为调整视力表符号的显示位置后的示意图。
如图7A的(a)所示,视力检测过程中,用户的眼睛距离地面的高度为h 1,视力表符号121在电子设备100上的显示位置用灰色方块表示,该显示位置距离地面的高度为h 2,h 1>h 2。需要说明的是,图7A所示的电子设备100实际为电子设备100的显示屏。用户需对电子设备100显示的视力表符号121进行判断,此时用户看向视力表符号121的视线方向为实际视线方向。而用户在医院、配镜中心等专业场所进行视力测试时,用户眼睛的高度和视力表中视力表符号的高度一般较为一致,也就是说,用户看向视力表符号121的视线方向更接近目标视线方向。因此,若按照图7A的(a)所示的场景对用户进行视力检测,则得到的视力检测结果不够准确。电子设备100可以调整视力表符号121的显示位置,调整后的示意图如图7A的(b)所示。
如图7A的(b)所示,电子设备100可以调高视力表符号121在用户界面120中的显示位置,调高后视力表符号121的显示位置距离地面的高度为h 1。电子设备100调整视力表符号121的显示位置后,用户看向视力表符号121的视线方向为图7A的(a)所示的目标视线方向。此时,电子设备100再对用户进行视力检测,得到的视力检测结果会更准确。
不限于上述列举的情况,在具体实现中,调整视力表符号121的显示位置后,视力表符号121的显示位置距离地面的高度可以不为h 1,而是和h 1的差值小于预设阈值,本申请实施例对此不作限定。
在一些实施例中,电子设备100也可以提示用户调整用户的高度,以使用户眼睛的高度和电子设备100显示的视力表符号的高度较为一致,得到的视力检测结果较为准确,具体过程如图7B所示。
请参见图7B,图7B是本申请实施例提供的一种用户调整用户的高度前后的对比图。图7B的(a)为用户调整用户的高度前的示意图,图7B的(b)为用户调整用户的高度后的示意图。
图7B的(a)和图7A的(a)一致,具体可参见图7A的(a)的说明。电子设备100可以提示用户调整用户的高度,直到用户的高度调整至图7B的(b)所示的h 2,电子设备100再对用户进行视力检测。如图7B的(b)所示,用户将用户的高度调低了(h 1-h 2),此时,用户的眼睛距离地面的高度和电子设备100显示视力表符号121的高度相同(均为h 2)。用户调整用户的高度后,用户看向视力表符号121的视线方向和图7A的(a)所示的目标视线方向平行。在这种情况下,电子设备100再进行视力检测过程得到的视力检测结果会较为准确。
不限于上述列举的情况,在具体实现中,用户调整用户的高度后,用户的眼睛距离地面的高度可以不为h 2,而是和h 2的差值小于预设阈值,本申请实施例对此不作限定。
在一些实施例中,电子设备100可以具备升降杆等升降装置,电子设备100可以自动调整电子设备100的显示屏的高度(后续简称为电子设备100调整电子设备100的高度),以使用户眼睛的高度和电子设备100显示的视力表符号的高度较为一致,得到的视力检测结果较为准确,具体过程如图7C所示。
请参见图7C,图7C是本申请实施例提供的一种电子设备100调整电子设备100的高度前后的对比图。图7C的(a)为电子设备100调整电子设备100的高度前的示意图,图7C的(b)为电子设备100调整电子设备100的高度后的示意图。
图7C的(a)和图7A的(a)一致,具体可参见图7A的(a)的说明。和图7A类似,图7C所示的电子设备100实际为电子设备100的显示屏。电子设备100可以通过升降装置调整显示屏的高度,调整后的示意图如图7C的(b)所示。如图7C的(b)所示,电子设备100将显示屏的高度调高了(h 1-h 2),调高后电子设备100显示视力表符号121的高度大于调高前电子设备100显示视力表符号121的高度,且差值也为(h 1-h 2)。电子设备100调整显示屏的高度后,用户看向视力表符号121的视线方向为图7C的(a)所示的目标视线方向。此时,电子设备100再对用户进行视力检测,得到的视力检测结果会更准确。
不限于上述列举的情况,在具体实现中,电子设备100调整显示屏的高度后,电子设备100显示视力表符号121的位置距离地面的高度可以不为h 1,而是和h 1的差值小于预设阈值,本申请实施例对此不作限定。
不限于图7A-图7C所示的情况,在具体实现中,电子设备100还可以直接测量用户眼睛和电子设备100显示的视力表符号之间的相对高度,本申请实施例对此不作限定。
不限于图7A-图7C所示的情况,在具体实现中,电子设备100也可以提示用户调整电子设备100的高度。
可以理解地,在不同的场景下可以采用不同的调整方式,以使用户眼睛的高度和电子设备100显示视力表符号的高度较为一致。例如,若电子设备100所在位置较低,即使按照图7A所示方式调整视力表符号121的显示位置后,用户眼睛距离地面的高度也远远大于电子设备100显示视力表符号121的高度,则此时可以采用图7B或图7C所示方式进行调整。或者,若电子设备100不具备升降装置,则可以选用图7A或图7B所示方式进行调整。或者,若电子设备100具备升降装置,则可以优先选用图7C所示方式进行调整,用户无需调整自身高度,使用起来更加方便。
在一些实施例中,电子设备100按照图7A-图7C所示方式调整后,电子设备100还可以根据用户眼睛和电子设备100显示视力表符号的相对高度进行校正补偿,以得到准确度更高的视力检测结果。
不限于上述示例的情况,在具体实现中,电子设备100也可以预存用户所处位置和补偿 值的对应关系,|h 1-h 2|和补偿值的对应关系等。该补偿值用于对视力检测结果进行校正补偿。上述对应关系可以是电子设备100或其他服务器等根据多次视力检测过程得到的,即根据大量真实测试的数据得到的。电子设备100可以根据上述对应关系得到对应的补偿值,并根据补偿值对得到的视力检测结果进行校正补偿,以得到准确度更高的视力检测结果。本申请对此不作限定。
不限于上述示例的情况,在具体实现中,电子设备100也可以直接结合用户所处位置、用户眯眼程度、头部歪曲程度、|h 1-h 2|等表征用户姿势的参数,以及得到的视力表符号的指认结果得到视力检测结果。也就是说,电子设备在根据视力表符号的指认结果得到视力检测结果的过程中就考虑进去了补偿值。本申请对校正补偿的具体方式不作限定。
本申请实施例中,电子设备100可以是智慧屏、智能电视等大屏设备。电子设备100可以将显示的用户界面划分为多个区域,每个区域用于一个用户进行视力检测,从而同时对多人进行视力检测,增加了检测效率,用户使用更加方便,具体示例可参见下图8A-图8D。
请参见图8A,图8A是本申请实施例提供的又一种视力检测场景的示意图。图8A以电子设备100同时对两个用户进行视力检测过程为例进行说明。
如图8A所示,第一用户和第二用户均通过电子设备100进行视力检测过程,视力检测过程中,电子设备100可以通过摄像头193持续获取第一用户和第二用户的图像信息。电子设备100可以显示用户界面810,用户界面810可以包括第一区域811和第二区域822,第一区域811用于第一用户进行视力检测,第二区域812用于第二用户进行视力检测。电子设备100可以提示第一用户对第一区域811显示的视力表符号进行判断,提示第二用户对第二区域812显示的视力表符号进行判断。
其中,第一区域811显示的视力表符号和第二区域812显示的视力表符号可以不同。具体地,电子设备100在第一区域811显示的视力表符号的大小和位置可以是根据第一用户的图像信息得到的,电子设备100在第二区域812显示的视力表符号的大小和位置可以是根据第二用户的图像信息得到的。当电子设备100获取到第一用户对于第一区域811当前显示的视力表符号的判断结果后,电子设备100可以根据该判断结果确定第一区域811下一个显示的视力表符号,即下一个用于第一用户判断的视力表符号。类似地,当电子设备100获取到第二用户对于第二区域812当前显示的视力表符号的判断结果后,电子设备100可以根据该判断结果确定第二区域812下一个显示的视力表符号,即下一个用于第二用户判断的视力表符号。也就是说,电子设备100可以根据不同用户的判断结果实时调整不同区域内显示的视力表符号,以得到不同用户的视力检测结果。电子设备100针对任意一个用户的视力检测过程的说明可参见图1A-图1B、图2-图3、图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C所示实施例。
在一些实施例中,电子设备100可以根据第一用户的图像信息确定第一用户的位置和姿态是否满足要求,若不满足要求则提示第一用户进行调整,并且,电子设备100还可以根据第一用户不正确的姿态对得到的视力检测结果进行调整。类似地,电子设备100也可以根据第二用户的图像信息确定第二用户的位置和姿态是否满足要求,若不满足要求则提示第二用户进行调整,并且,电子设备100还可以根据第二用户不正确的姿态对得到的视力检测结果进行调整。具体调整方式可参见图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C所示实施例,电子设备100针对第一用户的调整方式和针对第二用户的调整方式可以不同,也可以相同。
不限于图8A所示的区域划分方式,在具体实现中,电子设备100显示的用户界面也可 以为图8B所示的用户界面820,用户界面820包括第三区域821和第四区域822,第三区域821和图8A所示的第一区域811一致,第四区域822和图8A所示的第二区域812一致。若用户更多,例如有四个用户,则电子设备100显示的用户界面可以为图8C所示的用户界面830,用户界面830包括四个区域。或者,电子设备100显示的用户界面可以为图8D所示的用户界面840,用户界面840也包括四个区域。不同区域用于不同用户进行视力检测,不同区域显示的视力表符号可以不同,可以理解地,电子设备100针对任意一个用户的视力检测过程可以为图1A-图1B、图2-图3、图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C所示的视力检测过程。
基于上图1A-图1B、图2-图3、图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C、图8A-图8D所示的一些实施例,下面介绍本申请提供的视力检测方法。
请参见图9,图9是本申请提供的一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S101:电子设备开始测视力并确定目标用户。
具体地,电子设备可以响应于第一用户操作,开启摄像头以开始测视力,其中,第一用户操作例如但不限于为:作用于电子设备的用户操作(如点击操作)、用户手势(如OK手势)、语音信息等。电子设备确定开始测视力的示例可参见图2中电子设备100确定开始执行视力检测过程的说明,不再赘述。然后,电子设备可以通过摄像头获取用户的图像信息,并自动将该图像信息中的用户确定为目标用户。或者,电子设备也可以接收第二用户操作,并根据第二用户操作确定目标用户。第二用户操作的示例和第一用户操作的示例相同,不再赘述。电子设备确定目标用户的示例可参见图2中电子设备100确定目标用户的说明,不再赘述。
S102:电子设备持续获取目标用户的图像信息。
具体地,电子设备会在视力检测过程中,即得到目标用户两只眼睛的视力检测结果之前,持续获取目标用户的图像信息,并根据实时获取的目标用户的图像信息执行相应的操作。
S103:电子设备得到目标用户所在的第一位置。
具体地,第一位置可以包括目标用户和电子设备的距离、目标用户更接近电子设备的左侧或右侧。电子设备可以根据目标用户的图像信息、通过TOF传感器等方式得到目标用户所在的第一位置。电子设备根据目标用户的图像信息得到第一位置的示例可参见图4B和图4E所示实施例,不再赘述。
例如,电子设备可以根据获取的图像中目标用户的人脸长度、预先录入的图像中目标用户的人脸长度得到目标用户和电子设备的距离(简称为第一距离)。其中,电子设备预先录入目标用户的图像时已确定此时目标用户和电子设备的距离(简称为第二距离),可选地,电子设备预先录入目标用户的图像时可以指示目标用户位于和电子设备的距离为第二距离的位置。获取的图像中目标用户的人脸长度和预先录入的图像中目标用户的人脸长度的比值可以称为第一比值,第一距离和第二距离的比值等于第一比值。电子设备可以根据第一比值和第二距离得到第一距离。
S104:电子设备根据第一位置确定显示的视力表符号的大小和位置,并显示视力表符号。
具体地,电子设备可以根据目标用户更接近电子设备的左侧或右侧确定显示的视力表符号的位置,具体过程的示例可参见图4A-图4C所示实施例,不再赘述。
目标用户和电子设备的距离较远和较近时,电子设备显示的同一个视力表符号的大小不 同。目标用户和电子设备的距离较远时,目标用户所见的上述视力表符号会较小,目标用户和电子设备的距离较近时,目标用户所见的上述视力表符号会较大。若在这种情况下电子设备进行视力检测过程,则得到的视力检测结果会不准确。目标用户和电子设备的距离较远时,电子设备确定显示的视力表符号应该较大,目标用户和电子设备的距离较近时,电子设备确定显示的视力表符号应该较小,以使目标用户处于不同位置时看到同一个视力表符号的大小是一致的。电子设备可以根据目标用户和电子设备的距离确定显示的视力表符号的大小,具体过程的示例可参见图4D-图4F所示实施例,不再赘述。
在一些实施例中,电子设备可以在每次显示视力表符号之前随机选择视力表符号的朝向,以避免目标用户通过猜测方式给出视力表符号的判断结果,以使根据判断结果得到的视力检测结果更加准确。
S105:电子设备获取目标用户对于视力表符号的判断结果。
具体地,目标用户可以但不限于通过手势、手臂的运动轨迹、语音等方式给出视力表符号的判断结果。相应地,电子设备可以通过摄像头获取目标用户的图像信息,并根据目标用户的图像信息得到上述判断结果。或者,电子设备可以通过麦克风获取目标用户的语音信息,并根据目标用户的语音信息得到上述判断结果。具体示例可参见图1A-图1B所示实施例,不再赘述。
可以理解地,S105之前,S102-S104可以循环执行,也就是说,电子设备可以实时获取目标用户所在位置,当目标用户所在位置发生变化,则根据最新获取的位置确定显示的视力表符号的大小和位置,并显示视力表符号,从而及时处理目标用户出现走动的情况,得到的视力检测结果更加准确。
S106:电子设备判断获取的判断结果的数量是否等于预设数量。
具体地,当获取的判断结果的数量等于预设数量时,电子设备确定目标用户的一只眼睛已经测试完成,执行S107。当获取的判断结果的数量小于预设数量时,电子设备确定需对当前测试的眼睛继续进行视力测试,根据上述判断结果(例如最近一次获取的判断结果)确定下一次用于目标用户判断的视力表符号,并执行S102-S105。
S107:电子设备根据预设数量个判断结果得到目标用户一只眼睛的视力检测结果。
S108:电子设备对目标用户的另一只眼睛进行视力检测,并得到目标用户另一只眼睛的视力检测结果。
具体地,电子设备得到目标用户一只眼睛的视力检测结果后,可以提示目标用户遮挡另一只眼睛,并对目标用户的另一只眼睛进行视力测试,其中,电子设备对目标用户的另一只眼睛进行视力测试的过程和上述电子设备对目标用户的一只眼睛进行视力测试的过程(即S102-S107)类似,不再赘述。
可以理解地,电子设备通过图9所示方法进行视力检测的场景可参见图4A-图4F所示实施例。
在图9所示的方法中,电子设备可以根据目标用户的实时位置调整显示的视力表符号的大小和位置,即使目标用户出现走动,目标用户看到的同一个视力表符号也是较为一致的,得到的视力检测结果的准确性也更高。
本申请实施例中,电子设备还可以根据实时获取的目标用户的图像信息判断用户姿态是否满足要求,若用户姿态不满足要求,电子设备可以提示用户进行调整。并且,电子设备还可以根据用户不正确的姿态对得到的视力检测结果进行校正补偿,从而得到准确性更高的视 力检测结果。具体过程如图10所示。
请参见图10,图10是本申请提供的又一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S201:电子设备开始测视力并确定目标用户。
具体地,S201和图9的S101一致,具体可参见图9的S101的说明。
S202:电子设备持续获取目标用户的图像信息。
具体地,S202和图9的S102一致,具体可参见图9的S102的说明。
S203:电子设备根据目标用户的图像信息得到目标用户的眯眼程度、头部歪曲程度。
具体地,电子设备根据目标用户的图像信息得到目标用户的眯眼程度的说明可参见图5A-图5C的说明,其中,目标用户的眯眼程度可以是第三比值,第三比值的分子为目标用户眯眼前的眼睛宽度和眯眼后的眼睛宽度的差值,第三比值的分母为目标用户眯眼前的眼睛宽度,目标用户的眯眼程度的示例可参见图5C所示的用户的眯眼程度θ。
电子设备根据目标用户的图像信息得到目标用户的头部歪曲程度的说明可参见图5E-图5F的说明,其中,目标用户的头部歪曲程度可以是目标用户头部的中轴线的偏离角度,具体示例可参见图5F所示的第一夹角。
S204:电子设备判断目标用户的眯眼程度是否小于第一阈值,头部歪曲程度是否小于第二阈值。
例如,目标用户的眯眼程度是图5C所示的用户的眯眼程度θ,θ的取值范围为[0,1],第一阈值可以是[0,1]内的任意一个数值,如0.5。当θ=0,则表示用户未眯眼,当θ>0,则表示用户眯眼,当θ=1,则表示用户闭眼。需要说明的是,目标用户的眯眼程度大于0且小于第一阈值,表示满足要求,但此时用户的姿态并不正确。当目标用户的眯眼程度等于0才表示用户的姿态正确。
例如,目标用户的头部歪曲程度是图5F所示的第一夹角,第一夹角的取值范围为[0,90度],第一阈值可以是[0,90度]内的任意一个数值,如60度。当第一夹角等于0,则表示用户头部未歪曲,当第一夹角大于0,则表示用户头部歪曲。需要说明的是,目标用户的头部歪曲程度大于0且小于第二阈值,表示满足要求,但此时用户的姿态并不正确。当目标用户的头部歪曲程度等于0才表示用户的姿态正确。
具体地,当满足以下至少一项:目标用户的眯眼程度大于或等于第一阈值,目标用户的头部歪曲程度大于或等于第二阈值,则电子设备可以确定目标用户此时的姿态不满足要求,因此可以执行S205。当目标用户的眯眼程度小于第一阈值,以及目标用户的头部歪曲程度小于第二阈值时,电子设备确定目标用户此时的姿态满足要求,因此可以直接进行视力测试,即执行S206。
S205:电子设备提示目标用户调整姿态。
具体地,当目标用户的眯眼程度大于或等于第一阈值,电子设备可以提示目标用户睁大眼睛,当目标用户的头部歪曲程度大于或等于第二阈值,电子设备可以提示目标用户摆正头部。目标用户调整姿态后,电子设备可以重复执行S202-S204,当重新获取的目标用户的眯眼程度小于第一阈值,重新获取的目标用户的头部歪曲程度小于第二阈值时,电子设备才确定目标用户此时的姿态满足要求,因此可以直接进行视力测试,即执行S206。
S206:电子设备获取目标用户对视力表符号的判断结果。
具体地,当电子设备确定目标用户的眯眼程度小于第一阈值,以及目标用户的头部歪曲程度小于第二阈值,即目标用户的姿态满足要求时,电子设备获取目标用户对于视力表符号 的判断结果。电子设备获取目标用户对于视力表符号的判断结果和图9的S105一致,具体可参见图9的S105的说明。
S207:电子设备判断获取的判断结果的数量是否等于预设数量。
具体地,当获取的判断结果的数量等于预设数量时,电子设备确定目标用户的一只眼睛已经测试完成,执行S209。当获取的判断结果的数量小于预设数量时,电子设备确定需对目标用户当前测试的眼睛继续进行视力测试,并根据上述判断结果(例如最近一次获取的判断结果)确定下一次需显示的视力表符号,具体执行S202-S207。
S208:电子设备根据预设数量个判断结果得到目标用户一只眼睛的视力检测结果。
在一些实施例中,若执行S206时,目标用户的眯眼程度虽小于第一阈值但大于0,和/或,目标用户的头部歪曲程度虽小于第二阈值但大于0,则S208之后,该方法还包括:
S209:电子设备根据目标用户的头部歪曲程度和/或眯眼程度对得到的视力检测结果进行校正补偿。
具体地,当目标用户的眯眼程度大于0,电子设备可以根据目标用户的眯眼程度对S209得到的视力检测结果进行校正补偿,具体示例可参见图5A-图5D所示说明。可选地,电子设备100可以预存目标用户的眯眼程度和补偿值的第一对应关系,该补偿值用于对目标用户的视力检测结果进行校正补偿。第一对应关系可以是电子设备100或其他服务器等根据多次视力检测过程得到的,第一对应关系的曲线示例如图5D所示。
当目标用户的头部歪曲程度大于0,电子设备可以根据目标用户的头部歪曲程度对S209得到的视力检测结果进行校正补偿,具体示例可参见5E-5F所示说明。可选地,电子设备100可以预存目标用户的头部歪曲程度和补偿值的第二对应关系,该补偿值用于对目标用户的视力检测结果进行校正补偿。第二对应关系可以是电子设备100或其他服务器等根据多次视力检测过程得到的。
可以理解地,图10仅示出了电子设备对用户的一只眼睛进行视力测试的过程。电子设备得到目标用户一只眼睛的视力检测结果后,可以提示目标用户遮挡另一只眼睛,并对目标用户的另一只眼睛进行视力测试,其中,电子设备对目标用户的另一只眼睛进行视力测试的过程和上述电子设备对目标用户的一只眼睛进行视力测试的过程(即S202-S209)类似,不再赘述。
可以理解地,电子设备通过图10所示方法进行视力检测的场景可参见图5A-图5F所示实施例。
可以理解地,视力检测过程中,电子设备可以既检测目标用户是否走动,也检测目标用户的姿态是否满足要求,也就是说,图9所示方法和图10所示方法可以同时执行,即图9的S102-S105和图10的S202-S206可以同时执行。
本申请实施例中,电子设备还可以根据实时获取的目标用户的图像信息判断用户是否遮挡眼睛、用户遮挡眼睛是否错误。若用户未遮挡眼睛、用户遮挡眼睛错误,电子设备可以提示用户进行调整,从而提高测试结果的准确性。并且,电子设备可以自动识别用户实际遮挡的眼睛,以此自动确定用户左右眼的视力检测结果,用户使用更加方便。具体过程如图11所示。
请参见图11,图11是本申请提供的又一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S301:电子设备开始测视力并确定目标用户。
具体地,S301和图9的S101一致,具体可参见图9的S101的说明。
S302:电子设备持续获取目标用户的图像信息。
具体地,S302和图9的S102一致,具体可参见图9的S102的说明。
S303:电子设备根据目标用户的图像信息判断用户是否遮挡一只眼睛。
具体地,当确定目标用户并未遮挡一只眼睛时,电子设备提示目标用户遮挡一只眼睛(即执行S304),若确定目标用户遮挡一只眼睛,电子设备根据目标用户的图像信息得到目标用户实际遮挡的眼睛(即执行S305)。电子设备根据目标用户的图像信息判断目标用户是否遮挡一只眼睛的示例可参见图6A所示实施例。
S304:电子设备提示目标用户遮挡一只眼睛。
S305:电子设备根据目标用户的图像信息得到目标用户遮挡的眼睛。
具体地,电子设备可以首先根据目标用户的图像信息得到目标用户的眼睛和手的相对位置,然后根据目标用户的眼睛和手的相对位置得到目标用户遮挡的眼睛,具体示例可参见图6B-图6C所示实施例。
S306:电子设备对目标用户未被遮挡的眼睛进行视力检测,并得到对应的视力检测结果。
具体地,电子设备对目标用户一只眼睛进行视力检测的过程具体可参见图9-图10、下图12所示的视力检测过程。
S307:电子设备提示目标用户遮挡另一只眼睛。
具体地,电子设备在S306得到目标用户一只眼睛的视力检测结果后,可以提示目标用户遮挡另一只眼睛,以测试目标用户的另一只眼睛。
S308:电子设备根据目标用户的图像信息判断用户遮挡的眼睛是否为另一只眼睛。
具体地,电子设备根据实时获取的目标用户的图像信息得到目标用户的眼睛和手的相对位置,然后根据目标用户的眼睛和手的相对位置得到此时目标用户遮挡的眼睛,并判断此时目标用户遮挡的眼睛是否为目标用户的另一只眼睛。当此时目标用户遮挡的眼睛不为另一只眼睛,则电子设备再次提示用户遮挡另一只眼睛(即执行S307)。当此时目标用户遮挡的眼睛为另一只眼睛,则电子设备对此时目标用户未遮挡的眼睛进行视力检测(即执行S309)。
S309:电子设备对目标用户的另一只眼睛进行视力检测,并得到对应的视力检测结果。
具体地,电子设备对目标用户的任意一只眼睛的视力检测过程类似,具体可参见图9-图10、图12所示的视力检测过程。
本申请实施例中,当用户眼睛的高度和电子设备显示视力表符号的高度不一致时,电子设备可以调整视力表符号的显示位置或提示用户调整用户的高度,从而保证用户眼睛的高度和电子设备显示视力表符号的高度一致,提高视力检测结果的准确性。可选地,若电子设备具备升降装置,则电子设备也可以调整电子设备的显示屏的高度,无需用户调整,使用更加方便。具体过程如图12所示。
请参见图12,图12是本申请提供的又一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S401:电子设备开始测视力并确定目标用户。
具体地,S401和图9的S101一致,具体可参见图9的S101的说明。
S402:电子设备持续获取目标用户的图像信息。
具体地,S402和图9的S102一致,具体可参见图9的S102的说明。
S403:电子设备确定目标用户的眼睛距离地面的第一高度。
具体地,电子设备可以根据目标用户的图像信息、通过TOF传感器等方式得到目标用户的眼睛距离地面的第一高度。
S404:电子设备显示视力表符号,并确定视力表符号的显示位置距离地面的第二高度。
具体地,电子设备可以根据自身的尺寸、视力表符号在用户界面中的显示位置得到视力表符号的显示位置距离地面的第二高度。
S405:电子设备判断第一高度和第二高度的差值的绝对值是否小于预设高度。
具体地,预设高度可以为0,也可以不为0,例如为1厘米。当第一高度和第二高度的差值的绝对值大于或等于预设高度,电子设备可以执行S406以此来调整第一高度或第二高度,直到第一高度和第二高度的差值的绝对值小于预设高度,电子设备才获取目标用户的判断结果(即执行S407)。
S406:电子设备执行以下至少一项:调整视力表符号的显示位置、提示用户调整用户的高度、调整电子设备的高度。
具体地,电子设备可以根据第一高度和第二高度调整视力表符号在用户界面中的显示位置,具体示例可参见图7A所示实施例。电子设备也可以提示用户调整用户的高度,具体示例可参见图7B所示实施例。可选地,若电子设备具备升降杆等升降装置,则电子设备可以调整电子设备的显示屏的高度,具体示例可参见图7C所示实施例。
S407:电子设备获取目标用户对于视力表符号的判断结果。
具体地,S407和图9的S105一致,具体可参见图9的S105的说明。S407之后的视力检测过程具体可参见图9的S106-S108的说明,不再赘述。
可以理解地,电子设备通过图12所示方法进行视力检测的场景可参见图7A-图7C所示实施例。
可以理解地,视力检测过程中,电子设备可以既检测目标用户是否走动,也检测目标用户的姿态是否满足要求,还检测目标用户眼睛的高度和电子设备显示的视力表符号的高度是否一致。也就是说,图9所示方法、图10所示方法和图12所示方法可以同时执行,即图9的S102-S105、图10的S202-S206、图12的S402-S407可以同时执行。
上图9-图12均以一个用户的视力检测过程为例进行说明,若电子设备100是智慧屏、智能电视等大屏设备,则电子设备100可以同时对多人进行视力检测,提高了视力检测的效率,更加方便快捷。具体过程如图13所示。
请参见图13,图13是本申请提供的又一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S501:电子设备开始测视力并确定多个目标用户。
具体地,S501和图9的S101一致,只是在S501中,电子设备根据获取的图像信息自动识别目标用户时,可以将图像信息中的多个用户均确定为目标用户,或者,电子设备接收第二用户操作时,可以接收多个用户的第二用户操作,具体可参见图9的S101的说明。
S502:电子设备持续获取多个目标用户的图像信息。
具体地,S502和图9的S102一致,只是在S502中,获取的图像信息包括多个目标用户的图像信息,具体可参见图9的S102的说明。
S503:电子设备显示多个视力检测区域。
具体地,电子设备显示的用户界面包括多个视力检测区域,视力检测区域的数目和目标用户的数目相等。一个视力检测区域用于一个目标用户进行视力检测,后续可以称为一个目标用户对应一个视力检测区域。任意一个视力检测区域可以包括至少一个视力表符号,该视力表符号的大小和位置可以是根据使用该视力检测区域的目标用户的所在位置得到的,具体可参见图9的S104的说明。
S504:电子设备分别获取每个目标用户对于对应的视力检测区域中的视力表符号的判断结果。
具体地,对于每个目标用户,电子设备可以提示该目标用户给出一个视力表符号的判断结果,该目标用户使用的视力检测区域(即该目标用户对应的视力检测区域)用于显示上述视力表符号。电子设备可以分别获取每个目标用户的判断结果。
S505:电子设备根据每个目标用户的判断结果确定下一个需判断的视力表符号,并在对应的视力检测区域显示该视力表符号。
具体地,对于每个目标用户,电子设备在获取到一个视力表符号的判断结果后,可以根据该判断结果确定下一个用于该目标用户判断的视力表符号,并在该目标用户使用的视力检测区域显示上述确定的下一个视力表符号。电子设备可以继续获取该目标用户对于上述确定的下一个视力表符号的判断结果,即循环执行S504。每个目标用户给出的视力表符号的判断结果不同,每个视力检测区域显示的视力表符号也不同,每个目标用户进行视力检测过程的进度也不同。对于每个目标用户,当电子设备得到的判断结果的数量小于预设数量时,电子设备可以继续获取判断结果,直到电子设备得到的判断结果的数量等于预设数量,则电子设备可以根据预设数量个判断结果得到视力检测结果。
可以理解地,预设数量可以是视力检测领域中通常需测试的视力表符号的数量,即预设数量可以是经验所得。不限于此,预设数量也可以是用户设置的。当判断结果的数量大于或等于预设数量时,电子设备才会确认得到的视力检测结果是准确的。
可以理解地,每个目标用户通过电子设备进行视力检测的过程可以独立且同时进行,互相不会影响,每个目标用户的视力检测过程具体可参见图9-图12所示的视力检测过程。
可以理解地,电子设备通过图13所示方法进行视力检测的场景可参见图8A-图8D所示实施例。
请参见图14,图14是本申请提供的又一种视力检测方法的流程示意图。该方法可以应用于图2所示的电子设备100。该方法可以应用于图3所示的电子设备100。该方法可以包括但不限于如下步骤:
S601:显示第一字符。
具体地,第一字符可以为视力表符号。第一字符的显示方式,例如但不限于包括:显示位置、大小、颜色、粗细、倾斜角度等。
在一些实施例中,电子设备的显示屏显示有一个检测区域,该检测区域中显示有至少一个视力表符号,第一字符为至少一个视力表符号中任意一个视力表符号。这一个检测区域用于一个目标用户进行视力检测。此时,电子设备显示第一字符的示例如图1A-图1B、图4A、图4D、图5A、图5E所示。
在一些实施例中,电子设备的显示屏显示有预设数量个检测区域,预设数量为目标用户的数量。一个检测区域用于一个目标用户进行视力检测。一个检测区域显示有至少一个视力 表符号,第一字符为至少一个视力表符号中任意一个视力表符号。也就是说,电子设备可以同时对多个目标用户进行视力检测,具体说明如图13所示。其中,不同目标用户对于视力表符号的指认结果可以不同,则电子设备根据该指认结果显示的视力表符号也可以不同。也就是说,不同检测区域中显示的第一字符可以相同,也可以不同。此时,电子设备显示第一字符的示例如图8A-图8D所示。
S602:获取第一图像。
具体地,电子设备可以通过摄像头获取第一图像,第一图像包括目标用户。第一图像的示例如图4B、图4E、图5B、图5F、图6A-图6C所示。
S603:根据第一图像中目标用户的姿势、以及目标用户对于第一字符的指认结果得到第一检测结果。
具体地,目标用户的姿势例如但不限于包括:所处位置、眯眼程度、头部歪曲程度、眼睛距离地面的高度(简称第一高度)。其中,确定所处位置的示例可参见图4A-图4F所示实施例。确定眯眼程度的示例可参见图5C所示实施例。确定头部歪曲程度的示例可参见图5E-图5F所示实施例。确定第一高度的示例可参见图7A-图7C所示实施例。
电子设备可以但不限于通过摄像头、麦克风、传感器等获取目标用户对于第一字符的指认结果,具体示例可参见图1A中获取用户对视力表符号111的判断结果的说明。
具体地,电子设备可以确定第一图像中目标用户的姿势不符合要求,例如所处位置不为第一预设位置、眯眼程度大于0、头部歪曲程度大于0、第一高度和第一字符的显示位置距离地面的高度(简称第二高度)的差值的绝对值大于0。此时,电子设备可以按照预先获取的校正方式,结合第一图像中目标用户的姿势和目标用户对于多个不同的视力表符号的指认结果得到第一检测结果,具体示例可参见图5A-图5D所示的根据眯眼程度校正补偿得到的视力检测结果的说明。第一检测结果表征目标用户的视力等级,例如视力好、视力较好、视力较差和视力很差这四个视力等级。
在一些实施例中,S602之前,该方法还可以包括:获取第二图像,其中第二图像包括目标用户;确定第二图像中目标用户的姿势和预设姿势不同;输出提示信息或者调整第一字符的显示方式。
具体地,第二图像中目标用户的姿势和预设姿势不同,例如所处位置不为第二预设位置、眯眼程度大于或等于预设宽度、头部歪曲程度大于或等于预设角度、第一高度和第二高度的差值的绝对值大于或等于预设高度等。提示信息用于提示用户调整姿势,例如提示用户调整所处位置、睁大眼睛、摆正头部、调整所处高度等。用户调整姿势后,电子设备可以再次获取包括目标用户的图像,并判断目标用户的姿势是否为预设姿势。当确定获取的第一图像中目标用户的姿势为预设姿势时,电子设备执行S603。若目标用户的姿势仍然不为预设姿势,则电子设备可以继续输出提示信息或者调整第一字符的显示方式。
在一些实施例中,电子设备也可以不输出提示信息,而是直接调整第一字符的显示方式,然后执行S602-S603。也就是说,电子设备可以直接根据目标用户的姿势调整第一字符的显示方式,从而保证目标用户的姿势和此时要求的姿势相同,其中,上述此时要求的姿势和预设姿势通常不同。例如,获取的第二图像中目标用户处于图4A所示的位置B,假设第二预设位置为图4A所示的位置A。电子设备确定目标用户所处的位置B和第二预设位置(即位置A)不同,则电子设备可以直接显示图4C的(b)所示的用户界面120。此时要求的位置即为用户所处的位置B,而不是第二预设位置(即位置A)。
示例性地,图4A-图4F中,假设第二预设位置为位置A。电子设备通过获取的第二图像 确定用户处于位置B或位置C,则电子设备可以提示目标用户调整所处位置为位置A。当根据重新获取的第一图像确定目标用户处于位置A时,电子设备可以重新确定目标用户对于第一字符的指认结果,并执行S603。或者,电子设备可以按照图4C或图4F所示示例调整第一字符的显示方式,然后重新获取第一字符的指认结果,并执行S603。
示例性地,图5A-图5D中,假设预设宽度为0.5。电子设备通过获取的第二图像确定目标用户的眯眼程度θ大于或等于0.5,则电子设备可以提示目标用户睁大眼睛。当根据重新获取的第一图像确定目标用户的眯眼程度θ小于0.5时,电子设备可以重新确定目标用户对于第一字符的指认结果,并执行S603。或者,电子设备可以调大第一字符、调粗第一字符的字体等,然后重新获取第一字符的指认结果,并执行S603。
示例性地,图5E-图5F中,假设预设角度为60度。电子设备通过获取的第二图像确定目标用户头部歪曲程度(即第一夹角)大于或等于60度时,则电子设备可以提示目标用户摆正头部。当根据重新获取的第一图像确定第一夹角小于60度时,电子设备可以重新确定目标用户对于第一字符的指认结果,并执行S603。或者,电子设备可以调整第一字符的倾斜角度等,然后重新获取第一字符的指认结果,并执行S603。
示例性地,图7A-图7C中,电子设备通过获取的第二图像确定:第一高度和第二高度的差值的绝对值|h 1-h 2|大于或等于预设宽度,则电子设备可以提示目标用户调高或调低所处高度。当根据重新获取的第一图像确定|h 1-h 2|小于预设宽度时,电子设备可以重新确定目标用户对于第一字符的指认结果,并执行S603。或者,电子设备可以调高或调低第一字符在显示屏上的显示位置,可选地,若电子设备包括升降装置,则可以通过调高或调低显示屏的高度来调高或调低第一字符的显示位置。然后重新获取第一字符的指认结果,并执行S603。
在一些实施例中,电子设备可以根据第一图像中目标用户的眼睛是否被遮挡,确定目标用户待测试的眼睛,得到的第一检测结果表征目标待测试眼睛的视力等级。例如,电子设备可以根据目标用户手部和眼睛的相对位置关系确定目标用户的眼睛是否被遮挡,并在遮挡的情况下确定被遮挡的眼睛是左眼或右眼,具体示例如图6A-图6C所示。
可以理解地,图14所示方法的具体实现可参见图1A-图1B、图2-图3、图4A-图4F、图5A-图5F、图6A-图6C、图7A-图7C、图8A-图8D、图9-图13所示实施例,不再赘述。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。上述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行上述计算机程序指令时,全部或部分地产生按照本申请上述的流程或功能。上述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。上述计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,上述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线)或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。上述计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。上述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘Solid State Disk)等。总之,以上上述仅为本发明技术方案的实施例而已,并非用于限定本发明的保护范围。凡根据本发明的揭露,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的精神和范围。这样,倘若本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也意图包含这些改动和变型在内。

Claims (19)

  1. 一种视力检测方法,其特征在于,应用于电子设备,所述方法包括:
    显示第一字符;
    获取第一图像,所述第一图像包括目标用户;
    根据所述第一图像中所述目标用户的姿势,以及所述目标用户对于所述第一字符的指认结果得到第一检测结果,所述第一检测结果表征所述目标用户的视力等级。
  2. 如权利要求1所述的方法,其特征在于,所述获取第一图像之前,所述方法还包括:
    获取第二图像,所述第二图像包括所述目标用户;
    确定所述第二图像中所述目标用户的姿势和预设姿势不同;
    输出提示信息,所述提示信息用于提示所述目标用户调整姿势,所述第一图像中所述目标用户的姿势为所述预设姿势;或者,调整所述第一字符的显示方式,所述显示方式包括以下一项或多项:显示位置、大小、颜色、粗细、倾斜角度。
  3. 如权利要求2所述的方法,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同,包括:确定所述第二图像中所述目标用户所处位置和预设位置不同;
    所述提示信息具体用于提示所述目标用户调整位置,所述第一图像中所述目标用户所处位置为所述预设位置。
  4. 如权利要求2所述的方法,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同,包括:确定所述第二图像中所述目标用户头部歪曲的角度大于或等于预设角度;
    所述提示信息具体用于提示所述目标用户调整头部歪曲的角度,所述第一图像中所述目标用户头部歪曲的角度小于所述预设角度。
  5. 如权利要求2所述的方法,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同,包括:确定所述第二图像中所述目标用户眼睛的宽度小于预设宽度;
    所述提示信息具体用于提示所述目标用户睁大眼睛,所述第一图像中所述目标用户眼睛的宽度大于或等于所述预设宽度。
  6. 如权利要求2所述的方法,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同,包括:确定第一高度和第二高度的差值的绝对值大于或等于预设高度,所述第一高度为所述第二图像中所述目标用户的眼睛距离地面的高度,所述第二高度为所述第一字符的显示位置距离地面的高度;
    所述提示信息具体用于提示所述目标用户调整所处高度,所述第二高度和第三高度的差值的绝对值小于所述预设高度,所述第三高度为所述第一图像中所述目标用户的眼睛距离地面的高度。
  7. 如权利要求1所述的方法,其特征在于,所述第一图像中所述目标用户的第一眼睛被遮盖,所述目标用户的第二眼睛未被遮盖,所述第一检测结果具体表征所述第二眼睛的视力等级。
  8. 如权利要求1所述的方法,其特征在于,所述显示第一字符,包括:
    显示预设数量个检测区域,所述检测区域中显示有所述第一字符,所述预设数量为所述目标用户的数量,一个所述检测区域用于一个所述目标用户进行视力检测,第一区域中的所述第一字符和第二区域中的所述第一字符相同或不同,所述第一区域和所述第二区域为所述预设数量个检测区域中的任意两个区域。
  9. 一种电子设备,其特征在于,所述电子设备包括至少一个存储器、至少一个处理器,所述至少一个存储器与所述至少一个处理器耦合,所述至少一个存储器用于存储计算机程序,所述至少一个处理器用于调用所述计算机程序,所述计算机程序包括指令,当所述指令被所述至少一个处理器执行时,使得所述电子设备执行以下操作:
    显示第一字符;
    获取第一图像,所述第一图像包括目标用户;
    根据所述第一图像中所述目标用户的姿势,以及所述目标用户对于所述第一字符的指认结果得到第一检测结果,所述第一检测结果表征所述目标用户的视力等级。
  10. 如权利要求9所述的电子设备,其特征在于,所述获取第一图像之前,所述电子设备还用于执行:
    获取第二图像,所述第二图像包括所述目标用户;
    确定所述第二图像中所述目标用户的姿势和预设姿势不同;
    输出提示信息,所述提示信息用于提示所述目标用户调整姿势,所述第一图像中所述目标用户的姿势为所述预设姿势;或者,调整所述第一字符的显示方式,所述显示方式包括以下一项或多项:显示位置、大小、颜色、粗细、倾斜角度。
  11. 如权利要求10所述的电子设备,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同时,所述电子设备具体执行:确定所述第二图像中所述目标用户所处位置和预设位置不同;
    所述提示信息具体用于提示所述目标用户调整位置,所述第一图像中所述目标用户所处位置为所述预设位置。
  12. 如权利要求10所述的电子设备,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同时,所述电子设备具体执行:确定所述第二图像中所述目标用户头部歪曲的角度大于或等于预设角度;
    所述提示信息具体用于提示所述目标用户调整头部歪曲的角度,所述第一图像中所述目标用户头部歪曲的角度小于所述预设角度。
  13. 如权利要求10所述的电子设备,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同时,所述电子设备具体执行:确定所述第二图像中所述目标用户眼睛的宽度小于预设宽度;
    所述提示信息具体用于提示所述目标用户睁大眼睛,所述第一图像中所述目标用户眼睛的宽度大于或等于所述预设宽度。
  14. 如权利要求10所述的电子设备,其特征在于,所述确定所述第二图像中所述目标用户的姿势和预设姿势不同时,所述电子设备具体执行:确定第一高度和第二高度的差值的绝对值大于或等于预设高度,所述第一高度为所述第二图像中所述目标用户的眼睛距离地面的高度,所述第二高度为所述第一字符的显示位置距离地面的高度;
    所述提示信息具体用于提示所述目标用户调整所处高度,所述第二高度和第三高度的差值的绝对值小于所述预设高度,所述第三高度为所述第一图像中所述目标用户的眼睛距离地面的高度。
  15. 如权利要求14所述的电子设备,其特征在于,所述电子设备包括显示屏和升降装置,所述显示屏用于显示所述第一字符;所述调整所述第一字符的显示方式时,所述电子设备具体执行:通过所述升降装置调整所述显示屏距离地面的高度。
  16. 如权利要求9所述的电子设备,其特征在于,所述第一图像中所述目标用户的第一眼睛被遮盖,所述目标用户的第二眼睛未被遮盖,所述第一检测结果具体表征所述第二眼睛的视力等级。
  17. 如权利要求9所述的电子设备,其特征在于,所述显示第一字符,所述电子设备具体执行:
    显示预设数量个检测区域,所述检测区域中显示有所述第一字符,所述预设数量为所述目标用户的数量,一个所述检测区域用于一个所述目标用户进行视力检测,第一区域中的所述第一字符和第二区域中的所述第一字符相同或不同,所述第一区域和所述第二区域为所述预设数量个检测区域中的任意两个区域。
  18. 一种计算机存储介质,其特征在于,包括计算机指令,当所述计算机指令在电子设备上运行时,使得所述电子设备执行如权利要求1-8任一项所述的方法。
  19. 一种计算机程序产品,当所述计算机程序产品在电子设备上运行时,使得所述电子设备执行权利要求1-8任一项所述的方法。
PCT/CN2021/133754 2020-11-30 2021-11-27 视力检测方法及电子设备 WO2022111663A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011387013.0A CN114639114A (zh) 2020-11-30 2020-11-30 视力检测方法及电子设备
CN202011387013.0 2020-11-30

Publications (1)

Publication Number Publication Date
WO2022111663A1 true WO2022111663A1 (zh) 2022-06-02

Family

ID=81753772

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/133754 WO2022111663A1 (zh) 2020-11-30 2021-11-27 视力检测方法及电子设备

Country Status (2)

Country Link
CN (1) CN114639114A (zh)
WO (1) WO2022111663A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116736937A (zh) * 2022-09-30 2023-09-12 荣耀终端有限公司 一种笔记本电脑及输入操作的获取方法

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106778597A (zh) * 2016-12-12 2017-05-31 朱明� 基于图像分析的智能视力检测仪
CN108634925A (zh) * 2018-03-16 2018-10-12 河海大学常州校区 一种基于手势识别的视力测试系统
CN111387932A (zh) * 2019-01-02 2020-07-10 中国移动通信有限公司研究院 一种视力检测方法、装置及设备
CN111543934A (zh) * 2020-04-29 2020-08-18 深圳创维-Rgb电子有限公司 一种视力检测方法、装置、电子产品及存储介质

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106778597A (zh) * 2016-12-12 2017-05-31 朱明� 基于图像分析的智能视力检测仪
CN108634925A (zh) * 2018-03-16 2018-10-12 河海大学常州校区 一种基于手势识别的视力测试系统
CN111387932A (zh) * 2019-01-02 2020-07-10 中国移动通信有限公司研究院 一种视力检测方法、装置及设备
CN111543934A (zh) * 2020-04-29 2020-08-18 深圳创维-Rgb电子有限公司 一种视力检测方法、装置、电子产品及存储介质

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116736937A (zh) * 2022-09-30 2023-09-12 荣耀终端有限公司 一种笔记本电脑及输入操作的获取方法

Also Published As

Publication number Publication date
CN114639114A (zh) 2022-06-17

Similar Documents

Publication Publication Date Title
US11553078B2 (en) Touchscreen response method and electronic device
WO2020134869A1 (zh) 电子设备的操作方法和电子设备
EP4024829B1 (en) Volume adjustment method and electronic device
CN113645351B (zh) 应用界面交互方法、电子设备和计算机可读存储介质
WO2021052016A1 (zh) 一种人体姿态检测方法及电子设备
JP2023501777A (ja) タッチスクリーン、電子デバイス、および表示制御方法
WO2021082564A1 (zh) 一种操作提示的方法和电子设备
WO2022068819A1 (zh) 一种界面显示方法及相关装置
WO2022017393A1 (zh) 显示交互系统、显示方法及设备
WO2021008589A1 (zh) 一种应用的运行方法及电子设备
JP7400095B2 (ja) 表示要素の表示方法及び電子機器
CN114887323B (zh) 一种电子设备操控方法及电子设备
WO2022160991A1 (zh) 权限控制方法和电子设备
WO2022052740A1 (zh) 一种折叠设备及其开合控制方法
WO2022095744A1 (zh) Vr显示控制方法、电子设备及计算机可读存储介质
WO2021169370A1 (zh) 服务元素的跨设备分配方法、终端设备及存储介质
WO2022143180A1 (zh) 协同显示方法、终端设备及计算机可读存储介质
WO2022105702A1 (zh) 保存图像的方法及电子设备
WO2022111663A1 (zh) 视力检测方法及电子设备
WO2020192716A1 (zh) 一种系统语言的切换方法及相关装置
CN113391775A (zh) 一种人机交互方法及设备
WO2022062902A1 (zh) 一种文件传输方法和电子设备
EP4057122A1 (en) Screenshot method and related device
WO2023207862A1 (zh) 确定头部姿态的方法以及装置
CN116048236B (zh) 通信方法及相关装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21897163

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21897163

Country of ref document: EP

Kind code of ref document: A1