Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be obtained by a person skilled in the art without inventive step based on the embodiments of the present invention, are within the scope of protection of the present invention.
For convenience of description, the terminal is taken as an execution subject in the embodiment of the present invention, and the described terminal may include: a Mobile phone, a tablet computer, a palm computer, or a Mobile Internet Device (MID), etc., which are examples and not exhaustive, and include but are not limited to the above terminals.
Referring to fig. 1, which is a schematic flow chart of an image acquiring method according to an embodiment of the present invention, as shown in fig. 1, an image acquiring method may include the following steps:
and S100, receiving an ultrasonic echo signal array reflected by an ultrasonic signal emitted to the skin texture of the user through an ultrasonic sensor array.
In the embodiment of the present invention, the terminal may transmit the ultrasonic waves and receive the ultrasonic echoes through the ultrasonic probe, where the ultrasonic probe may be an ultrasonic sensor array, and the ultrasonic sensor array is composed of a plurality of ultrasonic sensors, such as an ultrasonic sensor array composed of N rows and M columns of sensors. In a specific application, the ultrasonic probe can specifically refer to the ultrasonic probe shown in fig. 2, and as can be seen from the figure, the ultrasonic probe is an ultrasonic sensor array. In the embodiment of the invention, the ultrasonic probe can realize the conversion of electric energy and sound energy by utilizing the piezoelectric effect of the ultrasonic sensor, so that the terminal can transmit ultrasonic signals through the ultrasonic probe and can also receive the ultrasonic signals through the ultrasonic probe.
In the embodiment of the present invention, the skin texture of the user may specifically be skin textures such as a user fingerprint, a user hand print, a user toe print, and the like. Therefore, when the terminal detects a fingerprint image collecting instruction, a user can place a finger in front of the ultrasonic sensor array, the terminal can control the ultrasonic sensor array to emit an ultrasonic signal, and after the ultrasonic signal is emitted, the ultrasonic sensor array receives an ultrasonic echo signal array in which the ultrasonic signal is reflected back through the fingerprint of the user, wherein the ultrasonic echo signal array is formed by the ultrasonic echo signals received by each ultrasonic sensor in the ultrasonic sensor array. In a specific application, the ultrasonic sensor array may be disposed in the button 1 on the terminal shown in fig. 3, and when the terminal places a finger on the button 1, the terminal may detect an instruction to acquire a fingerprint image, and then transmit an ultrasonic signal through the ultrasonic sensor array in the button 1 and receive an ultrasonic echo signal array through the ultrasonic sensor array.
S101, determining a target ultrasonic echo signal reflected by skin texture between ridges and valleys in the skin texture of the user in the ultrasonic echo signal array.
In an embodiment of the present invention, when the terminal receives the ultrasonic echo signal array reflected by the user fingerprint, the terminal may traverse each ultrasonic echo signal in the ultrasonic echo signal array, and determine at least one target ultrasonic echo signal reflected by skin texture between ridges and valleys in the user fingerprint.
In the embodiment of the present invention, the determination, by the terminal, of the target ultrasonic echo signal reflected by the skin texture between the ridge and the valley in the user fingerprint in the ultrasonic echo signal array may specifically be: the terminal judges whether the ultrasonic echo signals in the ultrasonic echo signal array are located between wave crests and wave troughs in the ultrasonic echo signal array one by one, and when the ultrasonic echo signals are determined to be located between the wave crests and the wave troughs in the ultrasonic echo signal array, the terminal determines that the ultrasonic echo signals are target ultrasonic echo signals.
In the embodiment of the present invention, the specific step of the terminal determining whether the ultrasonic echo signal in the ultrasonic echo signal array is located between the peak and the trough in the ultrasonic echo signal array may be: the terminal firstly determines an ultrasonic signal corresponding to a wave crest and an ultrasonic signal corresponding to a wave trough in an ultrasonic echo signal array. The terminal can detect whether the intensity of the ultrasonic signals is smaller than or equal to the intensity of the surrounding ultrasonic signals one by one, and when the intensity of the ultrasonic signals is smaller than the intensity of the surrounding ultrasonic signals, the terminal can determine that the ultrasonic signals with the intensity smaller than the intensity of the surrounding ultrasonic signals are ultrasonic signals corresponding to wave troughs; the terminal can also detect whether the intensity of the ultrasonic signals is greater than or equal to that of the surrounding ultrasonic signals one by one, and when the intensity of the ultrasonic signals is determined to be greater than or equal to that of the surrounding ultrasonic signals, the terminal can determine that the ultrasonic waves with the intensity greater than or equal to that of the surrounding ultrasonic signals are ultrasonic signals corresponding to wave peaks.
Secondly, after the terminal determines the ultrasonic signals corresponding to the wave crests and the ultrasonic signals corresponding to the wave troughs in the ultrasonic echo signal array, the terminal can detect whether the ultrasonic echo signals in the ultrasonic echo signal array are located between the positions of the ultrasonic signals corresponding to the wave crests and the positions of the ultrasonic signals corresponding to the wave troughs one by one. Specifically, the terminal can judge whether the intensity of the ultrasonic echo signal is smaller than the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest and larger than the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough, and when the intensity of the ultrasonic echo signal is determined to be smaller than the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest and larger than the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough, the terminal can determine that the ultrasonic echo signal is located between the ultrasonic echo signal corresponding to the wave crest and the ultrasonic echo signal corresponding to the wave trough in the ultrasonic echo signal array.
Specifically, referring to fig. 4, a schematic diagram of an ultrasonic sensor array for collecting fingerprints is shown, where a fingerprint cross section in fig. 4 is a partial cross section in a fingerprint of a user, and a row of ultrasonic sensors in fig. 4 may be a plurality of ultrasonic sensors located adjacent to each other in any row of ultrasonic sensors in the ultrasonic sensor array. As can be seen from fig. 4, the ultrasonic echo signal acquired by the ultrasonic sensor 1 is an ultrasonic echo signal reflected by a ridge of a user fingerprint, and because an air gap between the ridge and the sensor is small and impedance is small, the intensity of the ultrasonic echo signal acquired by the sensor 1 is the highest relative to the intensity of the ultrasonic echo signal acquired by an adjacent ultrasonic sensor, and thus the terminal can determine that the ultrasonic echo signal acquired by the ultrasonic sensor 1 is an ultrasonic echo signal corresponding to a peak. The ultrasonic echo signals collected by the ultrasonic sensor 3 are ultrasonic echo signals reflected by the valleys of the user fingerprint, and because the air gap between the valleys and the sensor is large and the impedance is large, the intensity of the ultrasonic echo signals collected by the ultrasonic sensor 3 is the lowest relative to the intensity of the ultrasonic echo signals collected by the adjacent ultrasonic sensor, so that the terminal can determine that the ultrasonic echo signals collected by the ultrasonic sensor 3 are ultrasonic echo signals corresponding to the valleys. The ultrasonic echo signal collected by the ultrasonic sensor 2 is the ultrasonic echo signal reflected by the texture between the ridge and the valley of the user fingerprint, and because the air gap between the texture and the sensor is not the maximum or the minimum, the intensity of the ultrasonic echo signal collected by the ultrasonic sensor 2 is smaller than that of the ultrasonic echo signal corresponding to the adjacent wave crest and is larger than that of the ultrasonic echo signal corresponding to the adjacent wave trough, so that the terminal can determine that the ultrasonic echo signal collected by the ultrasonic sensor 2 is the target ultrasonic echo signal of the reflection of the texture between the ridge and the valley of the user fingerprint.
The terminal obtains the intensity of each ultrasonic echo signal in the ultrasonic echo signal array, judges whether the intensity of the ultrasonic echo signal is smaller than a preset first threshold and larger than a preset second threshold, and determines that the ultrasonic echo signal is located between a wave crest and a wave trough in the ultrasonic echo signal array when the intensity of the ultrasonic echo signal is smaller than the preset first threshold and larger than the preset second threshold. The first threshold is the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the ultrasonic echo signal, and the second threshold is the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough of the ultrasonic echo signal. The terminal determines that the ultrasonic echo signals corresponding to the adjacent wave crests of the ultrasonic echo signals can be adjacent ultrasonic echo signals of the ultrasonic echo signals read by the terminal in an ultrasonic echo signal array, the intensity of the adjacent ultrasonic echo signals is obtained, whether the intensity of the adjacent ultrasonic echo signals is greater than or equal to that of the surrounding ultrasonic echo signals is judged, and when the intensity of the adjacent ultrasonic echo signals is greater than or equal to that of the surrounding ultrasonic echo signals, the adjacent ultrasonic echo signals are determined to be the ultrasonic echo signals corresponding to the adjacent wave crests; when it is determined that the intensity of the adjacent ultrasonic echo signals is not greater than or equal to the intensity of the surrounding ultrasonic echo signals, the terminal may further acquire the adjacent ultrasonic echo signals of the adjacent ultrasonic echo signals in the ultrasonic echo signal array until the intensity of the signals acquired by the terminal is greater than or equal to the intensity of the surrounding ultrasonic echo signals, and determine that the signals are the ultrasonic echo signals corresponding to the ring peaks.
And S102, performing enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal.
In the embodiment of the present invention, the specific processing of the terminal on the target ultrasonic echo signal may be: the terminal obtains the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the target ultrasonic echo signal and the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the target ultrasonic echo signal, sums and averages the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the obtained target ultrasonic echo signal and the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the target ultrasonic echo signal, and uses the averaged intensity as the intensity of the processed ultrasonic echo signal, thereby achieving the purpose of enhancing the target ultrasonic signal. Specifically, referring to fig. 4, when the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 2, the terminal may determine that the ultrasonic echo signal corresponding to the adjacent peak of the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 1, and the ultrasonic echo signal corresponding to the adjacent valley of the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 3. Therefore, the terminal can acquire that the intensity of the ultrasonic echo signal acquired by the ultrasonic sensor 1 is a and the intensity of the ultrasonic echo signal acquired by the ultrasonic sensor 3 is b, and therefore, the intensity of the target ultrasonic echo signal can be acquired by the terminal as c = (a + b)/2.
Furthermore, in the embodiment of the present invention, the terminal may further set a weight, and calculate, according to the set weight, the intensity of the ultrasonic echo signal corresponding to the adjacent peak of the target ultrasonic echo signal, the intensity of the ultrasonic echo signal corresponding to the adjacent trough of the target ultrasonic echo signal, and the intensity of the target ultrasonic echo signal, so as to achieve the purpose of enhancing the target ultrasonic echo signal. Specifically, the terminal may set the weight values to 0.5,0.7, 0.8, and the like, which is not limited herein. Referring to fig. 4, when the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 2, the terminal may determine that the ultrasonic echo signal corresponding to the adjacent peak of the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 1, and the ultrasonic echo signal corresponding to the adjacent trough of the target ultrasonic echo signal is the ultrasonic echo signal collected by the ultrasonic sensor 3. Therefore, the terminal can obtain the intensity of the target ultrasonic echo signal as d, the intensity of the ultrasonic echo signal collected by the ultrasonic sensor 1 as a, the intensity of the ultrasonic echo signal collected by the ultrasonic sensor 3 as b, and when the terminal sets the weight as 0.5, the terminal can obtain the intensity of the processed ultrasonic echo signal c = (a + b)/2 + 0.5+ d + 0.5 according to a formula. Further, the terminal may also obtain the intensity of the ultrasonic echo signal according to another formula, which is not limited herein.
S103, obtaining a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals except the target ultrasonic echo signal in the ultrasonic echo signal array.
In the embodiment of the present invention, the terminal may obtain the intensity of the processed ultrasound echo signal and the intensities of the ultrasound echo signals in the ultrasound echo signal array except for the target ultrasound echo signal, obtain the pixel value corresponding to each ultrasound echo signal according to the direct proportional corresponding relationship between the preset intensity and the gray value, and generate the texture image of the skin of the user according to the position of each ultrasound echo signal in the ultrasound echo signal array and the corresponding pixel value, where the pixel value may be the gray value or another pixel value, which is not limited herein. In particular, the user skin texture image may be a user fingerprint image. When the terminal acquires the user fingerprint image, the terminal can perform next processing according to the acquired user fingerprint image, such as outputting the user fingerprint image, or performing operations such as fingerprint identification according to the user fingerprint image.
In the embodiment of the invention, the terminal receives an ultrasonic echo signal array reflected by an ultrasonic signal transmitted to a skin texture of a user through an ultrasonic sensor array, determines a target ultrasonic echo signal reflected by the skin texture between a ridge and a valley in the skin texture of the user in the ultrasonic echo signal array, performs enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal, and acquires a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals except the target ultrasonic echo signal in the ultrasonic echo signal array, so that the definition of acquiring the skin texture image of the user by the terminal can be improved.
Fig. 5 is a flowchart illustrating a terminal according to a first embodiment of the present invention. As shown in fig. 5, a terminal according to this embodiment includes:
a receiving unit 100 for receiving an ultrasonic echo signal array reflected back by an ultrasonic signal transmitted toward the skin texture of the user through the ultrasonic sensor array.
A determining unit 200 for determining a target ultrasound echo signal in the ultrasound echo signal array, which is reflected by skin texture between ridges and valleys in the skin texture of the user.
The processing unit 300 is configured to perform enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal.
An obtaining unit 400, configured to obtain a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals in the ultrasonic echo signal array except the target ultrasonic echo signal.
It can be understood that the functions of each functional module of the apparatus in this embodiment may be specifically implemented according to the method in the foregoing method embodiment, and the specific implementation process may refer to the relevant description of the foregoing method embodiment, which is not described herein again.
In the embodiment of the invention, the terminal receives an ultrasonic echo signal array reflected by an ultrasonic signal transmitted to a skin texture of a user through an ultrasonic sensor array, determines a target ultrasonic echo signal reflected by the skin texture between a ridge and a valley in the skin texture of the user in the ultrasonic echo signal array, performs enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal, and acquires a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals except the target ultrasonic echo signal in the ultrasonic echo signal array, so that the definition of acquiring the skin texture image of the user by the terminal can be improved.
Referring to fig. 6, a schematic block diagram of a terminal according to another embodiment of the present invention is shown. The terminal in the present embodiment shown in fig. 6 may include: one or more processors 601; one or more input devices 602, one or more output devices 603, and memory 604. The processor 601, the input device 602, the output device 603, and the memory 604 are connected by a bus 605. The memory 604 is used for storing instructions and the processor 601 is used for executing instructions stored by the memory 604. Wherein, the processor 601 is configured to:
receiving, by an ultrasonic sensor array, an ultrasonic echo signal array reflected back by an ultrasonic signal that has been transmitted toward a skin texture of a user;
determining in the array of ultrasonic echo signals a target ultrasonic echo signal reflected back by skin texture between ridges and valleys in the user's skin texture;
performing enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal;
and acquiring a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals except the target ultrasonic echo signal in the ultrasonic echo signal array.
Wherein the processor 601 determines a target ultrasound echo signal in the ultrasound echo signal array that is reflected by skin texture between ridge and valley in the skin texture of the user comprises:
judging whether the ultrasonic echo signals in the ultrasonic echo signal array are positioned between the ultrasonic echo signals corresponding to the wave crests and the ultrasonic echo signals corresponding to the wave troughs one by one;
and when the ultrasonic echo signal is determined to be positioned between the ultrasonic echo signal corresponding to the wave crest and the ultrasonic echo signal corresponding to the wave trough in the ultrasonic echo signal array, determining that the ultrasonic echo signal is the target ultrasonic echo signal.
The step of judging, by the processor 601, whether the ultrasonic echo signals in the ultrasonic echo signal array are located between the ultrasonic echo signal corresponding to the wave crest and the ultrasonic echo signal corresponding to the wave trough in the ultrasonic echo signal array one by one includes:
acquiring the intensity of the ultrasonic echo signal;
judging whether the intensity of the ultrasonic echo signal is smaller than that of the ultrasonic echo signal corresponding to the adjacent wave crest and larger than that of the ultrasonic echo signal corresponding to the adjacent wave trough or not;
and when the intensity of the ultrasonic echo signal is determined to be smaller than the intensity of the ultrasonic echo signal corresponding to the adjacent wave peak and larger than the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough, determining that the ultrasonic echo signal is positioned between the wave peak and the wave trough in the ultrasonic echo signal array.
The processor 601 performs enhancement processing on the target ultrasonic echo signal, and obtaining the processed ultrasonic echo signal includes:
and combining the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the target ultrasonic echo signal and the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough of the target ultrasonic echo signal to perform enhancement processing on the target ultrasonic echo signal, so as to obtain the processed ultrasonic echo signal.
The processor 601 combines the intensity of the ultrasonic echo signal corresponding to the adjacent peak of the target ultrasonic echo signal and the intensity of the ultrasonic echo signal corresponding to the adjacent valley of the target ultrasonic echo signal to perform enhancement processing on the target ultrasonic echo signal, and obtaining the processed ultrasonic echo signal includes:
based on a preset weight, combining the intensity of the ultrasonic echo signal corresponding to the adjacent wave crest of the target ultrasonic echo signal, the intensity of the ultrasonic echo signal corresponding to the adjacent wave trough of the target ultrasonic echo signal and the intensity of the target ultrasonic echo signal to perform enhancement processing on the target ultrasonic echo signal, and obtaining the processed ultrasonic echo signal.
It can be understood that the functions of each functional module of the apparatus in this embodiment may be specifically implemented according to the method in the foregoing method embodiment, and the specific implementation process may refer to the relevant description of the foregoing method embodiment, which is not described herein again.
In the embodiment of the invention, the terminal receives an ultrasonic echo signal array reflected by an ultrasonic signal transmitted to a skin texture of a user through an ultrasonic sensor array, determines a target ultrasonic echo signal reflected by the skin texture between a ridge and a valley in the skin texture of the user in the ultrasonic echo signal array, performs enhancement processing on the target ultrasonic echo signal to obtain a processed ultrasonic echo signal, and acquires a skin texture image of the user according to the processed ultrasonic echo signal and other ultrasonic echo signals except the target ultrasonic echo signal in the ultrasonic echo signal array, so that the definition of acquiring the skin texture image of the user by the terminal can be improved.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
The above disclosure is only for the purpose of illustrating the preferred embodiments of the present invention, and it is therefore to be understood that the invention is not limited by the scope of the appended claims.