WO2022166550A1 - 数据传输方法及电子设备 - Google Patents

数据传输方法及电子设备 Download PDF

Info

Publication number
WO2022166550A1
WO2022166550A1 PCT/CN2022/071620 CN2022071620W WO2022166550A1 WO 2022166550 A1 WO2022166550 A1 WO 2022166550A1 CN 2022071620 W CN2022071620 W CN 2022071620W WO 2022166550 A1 WO2022166550 A1 WO 2022166550A1
Authority
WO
WIPO (PCT)
Prior art keywords
electronic device
image
information
data
user interface
Prior art date
Application number
PCT/CN2022/071620
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 WO2022166550A1 publication Critical patent/WO2022166550A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/147Digital output to display device ; Cooperation and interconnection of the display device with other functional units using display panels
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Definitions

  • the present application relates to the field of electronic technology, and in particular, to a data transmission method and an electronic device.
  • the present application provides a data transmission method, which is applied to a communication system, where the communication system includes a first electronic device and a second electronic device, and the first electronic device and the second electronic device are communicatively connected;
  • the first electronic device is equipped with a camera; the method includes: the first electronic device displays a first image, and the first image includes data information; the first electronic device detects a first user input;
  • the first electronic device displays a first user interface, and the first user interface includes a first position indication mark and a second image acquired by the camera; in the second image
  • the first electronic device detects a second user input, and the second user interface Refers to the user interface displayed by the second electronic device; in response to the second user input, the first electronic device sends a first data packet to the second electronic device, where the first data packet includes all the second image, the data information and the position information of the first
  • the user when the user wants to insert the data information in the first image into the second electronic device, the user can first perform the first user input on the first electronic device, and secondly, indicate the mark at the first position
  • the second user input is performed on the first electronic device, and secondly, the first electronic device sends the first data packet to the second electronic device, and the second electronic device can send the data to the second electronic device.
  • the information is inserted in the second user interface at the first location.
  • the real-time embodiment of the present application is conducive to simplifying the steps of transmitting data information from the first electronic device to the second electronic device, thereby improving the efficiency of data transmission.
  • the second electronic device inserts the data information into the second user interface at the first position according to the first data packet , the method further includes: the second electronic device determines the matching feature points in the second user interface and the second image; the second electronic device determines the matching feature points according to the matching feature points and the first position The position information of the indication mark is used to determine the first position in the second user interface; the second electronic device inserts the data information into the first position.
  • the second electronic device can determine the first position in the second user interface according to the feature point.
  • the time point when the first electronic device detects the second user input is the first time point; the position information of the first position indication mark indicates that the The position coordinates of the first position indication mark in the first coordinate system at the first time point.
  • the first image is acquired in real time through the camera; the first electronic device also displays a second position while displaying the first image an indicator, when the first electronic device detects the first user input, the second position indicator is located in the first information area in the first image; after the first user input is detected , before the first electronic device sends the first data packet to the second electronic device, the method further includes: the first electronic device performs image processing on the first image according to the second position indication mark , determine the first information area, and obtain the data information in the first information area.
  • the first electronic device can accurately determine the first information area from the first image according to the second position indicator, and then obtain the information that the user wants to insert into the second user interface from the first information area. Data information.
  • the method further includes: If the number of information regions included in the first image is one, the first electronic device determines that one information region included in the first image is the first information region, and the first electronic device targets the The first image is subjected to image processing to obtain the data information in the first information area.
  • the first electronic device performs image processing on the information area to obtain the data information that the user wants to insert into the second user interface, which improves the obtaining Efficiency of data information.
  • the method further includes: If the number of information areas included in the first image is two or more, the first electronic device displays two or more of the information areas; the first electronic device detects that A selection instruction of the first information area in two or more of the information areas; the first electronic device determines, according to the selection instruction, all of the two or more of the information areas the first information area; the first electronic device performs image processing on the first image to obtain the data information in the first information area.
  • the first electronic device can receive a selection instruction for the multiple information areas, and then determine the first information area according to the selection instruction, so that the first information area is
  • the data information obtained after the image processing is performed in the information area is the data information that the user wants to insert into the second user interface.
  • the data information included in the first data packet specifically refers to data information obtained after image processing is performed on the first image.
  • the data information included in the first data packet is carried by the first image, and the first data packet includes the first image.
  • the first image is acquired in real time through the camera; the first electronic device also displays a second position while displaying the first image an indication mark, when the first electronic device detects the first user input, the second position indication mark is located in the first information area in the first image; the first data packet further includes For the second position indication mark, after the first electronic device sends a first data packet to the second electronic device, the second electronic device inserts the data information into the second electronic device according to the first data packet.
  • the method further includes: the second electronic device performs image processing on the first image according to the second position indication mark, and determines the first image. information area, and obtain the data information in the first information area.
  • the second electronic device can accurately determine the first information area from the first image according to the second position indicator, and then obtain the information that the user wants to insert into the second user interface from the first information area. Data information.
  • the second electronic device sends the data packet to the second electronic device according to the first data packet.
  • the method further includes: if the number of the information areas included in the first image is one, the second electronic device determines An information area included in the first image is a first information area, and the second electronic device performs image processing on the first image to obtain the data information in the first information area.
  • the second electronic device when the first image includes only one information area, the second electronic device performs image processing on the information area to obtain the data information that the user wants to insert into the second user interface, which improves the obtaining Efficiency of data information.
  • the second electronic device sends the data packet to the second electronic device according to the first data packet.
  • the method further includes: if the number of information areas included in the first image is two or more, then The second electronic device displays two or more of the information areas; the second electronic device detects a selection instruction for the first information area among the two or more of the information areas; the first information area The second electronic device determines the first information area in the two or more information areas according to the selection instruction; the second electronic device performs image processing on the first image to obtain the the data information in the first information area.
  • the second electronic device can receive a selection instruction for the multiple information areas, and then determine the first information area according to the selection instruction, so that the first information area is
  • the data information obtained after the image processing is performed in the information area is the data information that the user wants to insert into the second user interface.
  • the first position indication mark is a first information area including the data information in the first image.
  • the first position indication mark is a preset mark symbol.
  • the first user input is a touch operation for the first electronic device; the second user input is ending all operations for the first electronic device. touch operation.
  • the present application provides a data transmission method, which is characterized by being applied to a first electronic device, the first electronic device and the second electronic device being communicatively connected; the first electronic device is provided with a camera; the The method includes: the first electronic device displays a first image, the first image includes data information; the first electronic device detects a first user input; in response to the first user input, the first The electronic device displays a first user interface, the first user interface includes a first position indication mark and a second image acquired by the camera; the second image includes a second user interface, and the first position indicator When the position where a position indication mark is located in the second user interface is the first position, the first electronic device detects a second user input, and the second user interface refers to the user input displayed by the second electronic device. an interface; in response to the second user input, the first electronic device sends a first data packet to the second electronic device, the first data packet includes the second image, the data information and all The position information of the first position indicating mark is described.
  • the time point when the first electronic device detects the second user input is the first time point; the position information of the first position indication mark indicates that the The position coordinates of the first position indication mark in the first coordinate system at the first time point.
  • the first image is acquired in real time through the camera; the first electronic device also displays a second position while displaying the first image an indicator, when the first electronic device detects the first user input, the second position indicator is located in the first information area in the first image; after the first user input is detected , before the first electronic device sends the first data packet to the second electronic device, the method further includes: the first electronic device performs image processing on the first image according to the second position indication mark , determine the first information area, and obtain the data information in the first information area.
  • the method further includes: If the number of information regions included in the first image is one, the first electronic device determines that one information region included in the first image is the first information region, and the first electronic device targets the The first image is subjected to image processing to obtain the data information in the first information area.
  • the method further includes: If the number of information areas included in the first image is two or more, the first electronic device displays two or more of the information areas; the first electronic device detects that A selection instruction of the first information area in two or more of the information areas; the first electronic device determines, according to the selection instruction, all of the two or more of the information areas the first information area; the first electronic device performs image processing on the first image to obtain the data information in the first information area.
  • the data information included in the first data packet specifically refers to data information obtained after image processing is performed on the first image.
  • the present application provides a data transmission method, which is applied to a second electronic device, where the second electronic device is communicatively connected to the first electronic device; the first electronic device is provided with a camera; the method includes: The second electronic device receives a first data packet sent by the first electronic device, and the first data packet includes a second image, data information and position information of the first position indication mark; the second electronic device according to The first data package inserts the data information into a first position in a second user interface, where the second user interface refers to a user interface displayed by the second electronic device.
  • the second electronic device inserts the data information into the first position in the second user interface according to the first data packet, including: the first The second electronic device determines the matching feature points in the second user interface and the second image; the second electronic device determines the matching feature points according to the matching feature points and the position information of the first position indicator a first location in a second user interface; the second electronic device inserts the data information at the first location.
  • the data information included in the first data packet is carried by a first image, and the first data packet includes the first image.
  • the first image is acquired in real time by the camera; the first electronic device also displays the second position while displaying the first image an indication mark, when the first electronic device detects a first user input, the second position indication mark is located in the first information area in the first image; the first data packet further includes the The second position indication mark, after the second electronic device receives the first data packet sent by the first electronic device, the second electronic device inserts the data information into the second user according to the first data packet Before the first position in the interface, the method further includes: the second electronic device performs image processing on the first image according to the second position indication mark, determines the first information area, and obtains the data information in the first information area.
  • the second electronic device after the second electronic device receives the first data packet sent by the first electronic device, the second electronic device sends the data packet according to the first data packet.
  • the method further includes: if the number of information areas included in the first image is one, determining, by the second electronic device, the first image An information area included in an image is a first information area, and the second electronic device performs image processing on the first image to obtain the data information in the first information area.
  • the second electronic device after the second electronic device receives the first data packet sent by the first electronic device, the second electronic device sends the data packet according to the first data packet.
  • the method further includes: if the number of information areas included in the first image is two or more, then the second electronic The device displays two or more of the information areas; the second electronic device detects a selection instruction for the first one of the two or more information areas; the second electronic device The first information area in the two or more information areas is determined according to the selection instruction; the second electronic device performs image processing on the first image to obtain the first information area. the data information in the information area.
  • an embodiment of the present application provides an electronic device, the electronic device includes: one or more processors and a memory; the memory is coupled to the one or more processors, and the memory is used to store a computer Program code, the computer program code comprising computer instructions invoked by the one or more processors to cause the electronic device to perform the first aspect and any possible implementation thereof, or the second aspect and any possible implementation manner thereof, or the third aspect and any possible implementation manner thereof.
  • a system on a chip is provided, the system on chip is applied to an electronic device, and the system on chip includes one or more processors configured to invoke computer instructions to cause the electronic device to execute the first aspect and any possible implementation manner thereof, or the second aspect and any possible implementation manner thereof, or the third aspect and any possible implementation manner thereof.
  • the present application provides a computer program product that, when the computer program product runs on an electronic device, causes the electronic device to perform the first aspect and any possible implementation manner thereof, or the second aspect and any possible implementation manner thereof, or the third aspect and any possible implementation manner thereof.
  • the present application provides a computer-readable storage medium, the computer-readable storage medium comprising computer instructions, when the computer instructions are executed on an electronic device, the electronic device is made to perform the first aspect and any of the above.
  • FIG. 1 is a schematic flowchart of a data transmission method provided by an embodiment of the present application.
  • FIG. 2A is a schematic diagram of a scenario provided by an embodiment of the present application.
  • FIGS. 2B and 2C are schematic diagrams of displaying a first image provided by an embodiment of the present application.
  • FIG. 3 is a schematic diagram of a user performing a touch operation on the display screen of the electronic device 100 according to an embodiment of the present application;
  • FIG. 4A is a schematic diagram of an electronic device 100 provided by an embodiment of the present application.
  • 4B to 4D are schematic diagrams of a group of determination information regions provided by an embodiment of the present application.
  • FIG. 5A is a schematic diagram of an electronic device 200 provided by an embodiment of the present application.
  • 5B to 5D are schematic diagrams of a group of electronic devices 100 provided by embodiments of the present application.
  • 6A to 6B are schematic diagrams of a user ending a touch operation on the display screen of the electronic device 100 according to an embodiment of the present application;
  • FIG. 7 is a schematic diagram of an electronic device 200 provided by an embodiment of the present application.
  • FIG. 8 is a schematic diagram of a differential pyramid provided by an embodiment of the present application.
  • FIG. 9A is a schematic diagram of a user interface 202 provided by an embodiment of the present application.
  • FIG. 9B is a schematic diagram of a user interface 104 provided by an embodiment of the present application.
  • FIG. 9C is a schematic diagram of another user interface 202 provided by an embodiment of the present application.
  • 9D and 9E are schematic diagrams of a group of positional relationships provided by an embodiment of the present application.
  • FIG. 10 is a schematic flowchart of another data transmission method provided by an embodiment of the present application.
  • FIG. 11 is a schematic structural diagram of an electronic device 100 provided by an embodiment of the present application.
  • FIG. 12 is a software structural block diagram of an electronic device 100 provided by an embodiment of the present application.
  • first and second are only used for descriptive purposes, and should not be construed as implying or implying relative importance or implying the number of indicated technical features. Therefore, the features defined as “first” and “second” may explicitly or implicitly include one or more of the features. In the description of the embodiments of the present application, unless otherwise specified, the “multiple” The meaning is two or more.
  • the electronic device can process the image according to Optical Character Recognition (OCR) to obtain text information in the image; so that when the user wants to edit the text information in the image, there is no need to manually input the text information,
  • OCR Optical Character Recognition
  • the text information included in the image can be directly edited on the electronic device, which improves the efficiency of processing the text information.
  • OCR Optical Character Recognition refers to the process of analyzing and recognizing image files of text data to obtain text and layout information.
  • the first electronic device and the second electronic device are communicatively connected.
  • the first application in the first electronic device and the second application in the second electronic device can transmit data information to each other.
  • the user can view the image on the first electronic device, and the image includes text information; when the user wants to paste the text information in the image to the third application program on the second electronic device, the user's purpose can be achieved through the following steps:
  • the user first performs operation B1 on the first electronic device; the first electronic device detects the operation B1 (for example, the operation B1 may be a touch operation, a pressing operation, a voice input operation, etc.
  • the first electronic device processes the image according to optical character recognition to obtain text information in the image; after that, the user can perform operation B2 on the first electronic device (for example, a touch operation on the first electronic device, a pressing operation, voice input operation, etc.), in response to operation B2, the first electronic device sends text information to the second electronic device through the first application; the second application of the second electronic device receives the text information; The device performs operation B3 (for example, it may be a touch operation, pressing operation, voice input operation, etc. for the first electronic device), and in response to operation B3, the second electronic device pastes the text information in the second application to the third application in the user interface of the program.
  • operation B2 for example, a touch operation on the first electronic device, a pressing operation, voice input operation, etc.
  • the first electronic device and the second electronic device are communicatively connected.
  • the user can view the image on the first electronic device, and the image includes text information; when the user wants to paste the text information in the image to the user interface in the application program on the second electronic device, the user's Purpose:
  • the user first performs operation B1 on the first electronic device; the first electronic device detects operation B1 (for example, a touch operation, a pressing operation, a voice input operation, etc.
  • the first electronic device sends an image to the second electronic device; after the second electronic device receives the image, the user can perform operation B2 on the second electronic device (for example, a touch operation on the first electronic device, a pressing operation, voice input operation, etc.), in response to operation B2, the second electronic device processes the image according to optical character recognition to obtain text information in the image; after that, the user performs operation B3 for the second electronic device (for example, it may be for the first electronic device) touch operation of the device, pressing operation, voice input operation, etc.), the second electronic device pastes the text information into the user interface of the third application program in response to operation B3. It can be seen that, in some embodiments, when the user wants to paste the text information in the image stored in the first electronic device into the third application program in the second electronic device, it needs to go through a complicated operation process, resulting in The transmission efficiency of text information is low.
  • the following embodiments provide a data transmission method.
  • the method is applied to a communication system, the communication system includes a first electronic device 100 and a second electronic device 200, the first electronic device 100 and the second electronic device 200 are communicatively connected, and the first electronic device 100 is provided with a camera.
  • the method may include:
  • the first electronic device 100 displays the first image 101 .
  • the first image 101 may be a preview image acquired by the first electronic device 100 in real time through a camera.
  • FIG. 2A is a schematic diagram of a scenario provided by an embodiment of the present application.
  • the first electronic device 100 acquires the scene shown in FIG. 2A through the camera in real time, obtains the first image 101 , and displays the first image 101 on the display screen; it can be understood that in the first image 101
  • the image in is obtained by the first electronic device 100 in real time through the camera, and the first image 101 is the preview screen displayed on the first electronic device 100, that is, when the user moves the first electronic device 100, the first image 101 changes with changes with the movement of the first electronic device 100 .
  • FIG. 2A is a schematic diagram of a scenario provided by an embodiment of the present application.
  • the first electronic device 100 acquires the scene shown in FIG. 2A through the camera in real time, obtains the first image 101 , and displays the first image 101 on the display screen; it can be understood that in the first image 101
  • the image in is obtained
  • the first electronic device 100 displays the first image 101 on the display screen and also displays the second indicator 105 ,
  • the display position and shape of the second position indicating mark 105 on the display screen of the first electronic device 100 are preset. For example, in FIG. 2B , the position where the second position indicating mark 105 is located is in the center of the display screen, and the second The shape of the position indication mark 105 is a cross shape.
  • the first image 101 may be an image stored in the first electronic device 100 , and the user may open the first image 101 on the first electronic device 100 .
  • the first electronic device 100 detects a first user input.
  • the first user input may include one or more types of input, for example, the first user input may be: voice input, touch operation, pressing operation, and the like.
  • FIG. 3 is a user performing a touch operation on the display screen of the electronic device 100 according to an embodiment of the present application. schematic diagram.
  • the first electronic device 100 in response to the first user input, performs image processing on the first image 101 to obtain data information in the first image 101;
  • An electronic device 100 displays the second image 1041 and the first position indicator 1042 in layers to obtain a first user interface
  • the first position indicator 1042 is located on the top layer.
  • step S103 image processing is performed on the first image 101 to obtain data information in the first image 101, which may specifically include step S1031 or step S1032 or step S1033.
  • the first image 101 may be a preview image obtained by the first electronic device 100 in real time through the camera, or may be an image stored in the first electronic device 100; in the first image 101 If it is the preview image obtained by the first electronic device 100 through the camera in real time, the first electronic device 100 executes step S1031; if the first image 101 is an image stored in the first electronic device 100, the first electronic The device 100 performs step S1032 or 1033.
  • the first electronic device 100 determines the information area 103 where the second position indicator 105 is located, performs image processing on the first image, determines the information area 103 , and obtains data information in the information area 103 .
  • the data information “meeting report” is included in FIG. 2B
  • the second position indication mark 105 is located in the information area including “meeting report”, therefore, the first electronic device 100 determines that “meeting report” is included
  • the information area is the information area 103
  • FIG. 4A illustrates the information area 103 .
  • the first electronic device 100 determines an information area containing data information, and if the number of information areas containing data information is one, the information area is determined to be an information area 103, and image processing is performed on the first image 101 to obtain an information area Data information in 103.
  • the first electronic device 100 determines an information area containing data information, and if the number of information areas containing data information is multiple, then displays multiple information areas; after that, it detects that the user's information on one of the multiple information areas is area selection instruction; determine the information area 103 in the multiple information areas according to the selection instruction; perform image processing on the first image 101 to obtain the data information in the information area 103 .
  • the first electronic device 100 displays a first image 101, and the first image 101 includes an information area 103 and an information area 106; after that, as shown in FIG. 4C, the first image 101 The electronic device 100 displays the information area 103 and the information area 106; then, as shown in FIG. 4D, the first electronic device 100 detects the user's selection instruction for the information area 103, that is, the information area 103 is determined; after that, the first electronic device 100 Image processing may be performed on the first image 101 to obtain data information in the information area 103 .
  • the position of the first position indication mark 1042 in the user interface 104 may be preset.
  • the first position indication mark 1042 may be located in the center of the user interface 104 .
  • the first electronic device 100 displays the user interface
  • multiple layers are displayed in layers to obtain the user interface 104 that is finally displayed on the display screen;
  • the second image 1041 is a layer of layers
  • the first position indicator 1042 is a layer
  • the first electronic device 100 displays the layer on which the first position indicator 1042 is located above (or on top) the layer on which the second image 1041 is located, that is,
  • the first user interface 104 can be obtained; specifically, the first electronic device 100 can call the application programming interface to place the layer where the first position indicator 1042 is located on the layer where the second image 1041 is located; specifically,
  • the called application programming interface may be a layout application programming interface.
  • the data information may be represented in the form of pictures or text; the data information may be text information specifically; it may also be a picture of a specific object, for example, the data information may be a picture of a bird.
  • the first electronic device 100 performs image processing on the first image 101 to determine the information area 103 in the first image 101 .
  • performing image processing on the first image 101 may specifically refer to performing optical character recognition on the first image 101 .
  • the data information may specifically refer to text information included in the image; for example, in the case that the first image 101 includes text, after the first electronic device 100 performs optical character recognition on the first image 101, it may be determined that The area containing text in the first image 101 is the information area described above, and the first electronic device 100 can generate corresponding text information according to the text contained in the first image. For example, in the first image 101 shown in FIG. 3 , the first image 101 contains the words “meeting report”, then the optical character recognition process is performed on the first image 101, and it can be determined that the first image 101 is as shown in FIG. 4A .
  • the area 103 that is, the information area
  • containing the words "meeting report” can generate text information of the words "meeting report” at the same time; it should be noted that the generated text information is information that can be edited by the electronic device.
  • the user interface 104 may also be referred to as a first user interface; the user interface 202 of the second electronic device 200 may also be referred to as a second user interface.
  • the first position indication mark 1042 is located on the top layer, which means that the display content of the first position indication mark 1042 will not be blocked by the display content of the second image 1041 , and the display content of the first position indication mark 1042 can block the display of the second image 1041 content.
  • the second image 1041 may include part or all of the user interface 202 of the second electronic device 200 .
  • the first position indication mark 1042 may be a preset mark symbol, or the first position indication mark 1042 is the information area 103 in the first image 101 .
  • step S103 the user interface 202 of the second electronic device 200 is included in the second image 1041 , and the position of the first position indicator 1042 in the user interface 202 is where the user wants to insert the data information into the first position in the user interface 202; then step S105 is executed. If after step S103, the second image 1041 does not include the user interface 202, or the second image 1041 includes the user interface 202, but in the first user interface 104, the first position indicator 1042 is not in the user interface 202, or , the position of the first position indication mark 1042 in the user interface 202 is not the first position where the user wants to insert the data information into the user interface 202, then step S104 is executed first, and then step S105 is executed.
  • the first electronic device 100 detects a third user input, and in response to the third user input, the first electronic device 100 adjusts the display content in the second image 104, the adjusted second image 1041 includes the user interface 202, and The position of the first position indicator 1042 in the user interface 202 is the first position where the user wants to insert the data information into the user interface 202 .
  • the third user input is that the user moves the first electronic device 100; the user can move the first electronic device 100 (ie, adjust the shooting scene obtained by the first electronic device 100 through the camera), so that the first electronic device 100 passes the camera
  • the acquired second image 1041 includes the user interface 202 of the second electronic device 200 .
  • FIG. 5A is a schematic diagram of the second electronic device 200 provided by an embodiment of the present application.
  • FIG. 5A includes: a second electronic device 200 , a user interface 202 of the second electronic device 200 , an application 201 and a title bar 2011 in the application 201 .
  • the first position indication mark 1042 is a preset mark symbol, please refer to the first position indication mark 1042 shown in FIG. 5B; when the first position indication mark 1042 is the information area 103 in the first image 101, please refer to FIG. 4A , the information area 103 in FIG. 4A containing the text information “meeting report” can be regarded as the first position indication mark 1042 .
  • the user can move the first electronic device 100, so that the second image 1041 captured by the first electronic device 100 through the camera includes the user interface 202 of the second electronic device 200, and the first position indicates the position of the mark 1042 in the user interface 202 is the first position where the user wants to insert data information into the user interface 202; specifically, in the case where the first position indicator 1042 is shown in FIG. 5B , the first electronic device 100 displays the schematic diagram of the user interface 104 as shown in FIG. 5C; in the case where the first position indicator 1042 is shown in FIG. 4A, a schematic diagram of the first electronic device 100 displaying the user interface 104 is shown in FIG. 5D. As shown in FIGS. 5C and 5D , the first position indication mark 1042 or the information area 103 is located in the title bar 2011 .
  • the first electronic device 100 detects a second user input.
  • the second user input may include one or more types of input, for example, the second user input may be: voice input, touch operation, pressing operation, and the like.
  • the first user input is that the user maintains a touch operation on the display screen of the first electronic device 100
  • the second user input is that the first electronic device 100 detects that the user ends the display screen of the first electronic device 100 .
  • Execute a touch operation for example, in step S102, as shown in FIG. 3, the user touches the display screen of the electronic device 100, and maintains the touch operation on the display screen; when the user maintains the touch operation on the display screen
  • the first electronic device 100 performs steps S102 to S104; in step S105, as shown in FIG. 6A or FIG. 6B, the user ends the touch operation on the first electronic device 100, which is the second in this example.
  • step S105 User input; specifically, in the case where the user interface 104 is shown in FIG. 5C , please refer to FIG. 6A for an example description of step S105 ; in the case where the user interface 104 is shown in FIG. 5D , please refer to FIG. 6A for an example description of step S105 6B.
  • the first electronic device 100 in response to the second user input, sends a first data packet to the second electronic device 200, where the first data packet includes the second image 1041, the position information of the first position indication mark 1042, and the first data packet. Data information in image 101.
  • the data information in the first image 101 specifically refers to the data information obtained by performing image processing on the first image 101 .
  • the time point when the first electronic device 100 detects the second user input is the first time point; the location information of the first position indication mark 1042 in the first data packet may specifically represent the first position indication mark at the first time point
  • the position coordinates, the first coordinate system may specifically refer to the camera coordinate system of the first electronic device 100 .
  • the position information of the first position indication mark 1042 in the first data packet may specifically represent the position coordinates of the first position indication mark 1042 after a preset time period after the first time point. For example, if the preset time period is 1 second, then The position information specifically represents the position coordinates of the first position indication mark 1042 at the second time after the first time point.
  • the first electronic device 100 and the second electronic device 200 are directly connected, and the first electronic device 100 may directly send the first data packet to the second electronic device 200 .
  • the first electronic device 100 and the second electronic device 200 are indirectly connected, the first electronic device 100 is communicatively connected to the third electronic device, and the second electronic device 200 is communicatively connected to the third electronic device; the first electronic device 100 may send the first data packet to the second electronic device 200 through the third electronic device.
  • the first electronic device 100 is installed with the application program C1
  • the second electronic device 200 is installed with the application program C2
  • the first data packet sent by the first electronic device 100 to the second electronic device 200 may specifically be: an application program C1 sends the first data packet to application C2.
  • a message header may be added to the different data information.
  • the first data packet includes the position of the second image 1041 and the first position indication mark 1042 information, and the data information in the first image 101; corresponding to three types of data, namely image data, location data, and text data, wherein each data in the first data packet has a corresponding message header before, such as image data
  • image data header is included before
  • location data header is included before the location data
  • text message header is included before the text data.
  • the second electronic device 200 determines the corresponding data format according to the message header in the data packet, parses the data in the data packet according to the data format, and finally obtains the data in the data packet.
  • the data format corresponding to the image is determined according to the image data message header, and the data after the image data message header in the data packet is parsed according to the data format corresponding to the image to obtain the second image 1041 in the first data packet.
  • the second electronic device 200 inserts the data information in the first image 101 into the user interface of the application program 201 according to the first data packet.
  • the user interface 202 of the electronic device 200 in the embodiment of the present application includes the user interface of the application program 201. Therefore, inserting the data information in the first image 101 into the user interface of the application program 201 can be regarded as The data information in the first image 101 is inserted into the user interface 202 .
  • the position where the data information in the first image 101 is inserted is determined according to the position information of the first position indication mark 1042 . It can be seen that, in the embodiment of the present application, when the user wants to insert the text information in the first image 101 into the application program 201, the user can first perform the first user input; after that, the first electronic device 100 displays the first user input obtained through the camera.
  • the first electronic device 100 displays the second image 1041 and the first position indicator 1042 in layers to obtain the first user interface 104; the user can move the first electronic device 100 (that is, adjust the first electronic device 100 to obtain through the camera) Therefore, the displayed content in 1041 in the second image is changed), so that the user interface 202 of the second electronic device 200 is included in the second image 1041; the user determines the first position on the first electronic device 100
  • the indicator 1042 is located at the first position in the user interface 202 (the first position is the position where the user wants to insert the data information into the user interface 202)
  • the user performs a second user input, and after the second user input is responded to, the first position is
  • the second electronic device 100 can insert the data information in the first image 101 into the first position; for example, after the second electronic device 200 inserts the data information into the user interface of the application program 201 as shown in FIG.
  • the first position indicator 1042 (or may be referred to as the information area 103 ) is located in the title bar 2011 of the user interface 202 , therefore, the text information “Meeting Report” inserted in FIG. 7 is located in the title bar 2011 .
  • the embodiments of the present application are beneficial to simplify the process of inserting the data information viewed in the first electronic device 100 into the application program 201 of the second electronic device 200, and improve the efficiency of inserting data information.
  • step S107 may specifically include the following steps S11-S14:
  • the second electronic device 200 acquires the user interface 202 currently displayed on the display screen.
  • the user interface 202 displayed on the display screen may refer to the user interface 202 in FIG. 5A .
  • the second electronic device 200 determines matching feature points between the user interface 202 and the second image 1041 .
  • the second electronic device 200 may calculate the similarity between the first feature point in the user interface 202 and the second feature point in the second image 1041, and the similarity between the first feature point and the second feature point In the case that the degree of the first feature point and the second feature point meet the preset condition, it is determined that the first feature point and the second feature point are a set of matching feature points; wherein, the preset condition may be: the similarity between the first feature point and the second feature point is greater than the preset threshold value , or, the first feature point is the feature point with the highest similarity with the second feature point in the user interface 202 .
  • a feature point may specifically refer to a pixel.
  • the manner in which the second electronic device 200 determines that the first feature point and the second feature point are matching feature points may be determined by constructing an image pyramid, and may specifically be:
  • the second electronic device 200 processes the user interface 202, which specifically includes: first, the second electronic device 200 generates a grayscale image of the user interface 202, denoting I(x 1 , y 1 ) as the position coordinates in the user interface 202 as ( Pixel information of pixels of x 1 , y 1 ) (for example, the pixel information may include RGB values). Secondly, the second electronic device 200 constructs a Gaussian pyramid according to the pixel information of each pixel in the user interface 202; specifically, the second electronic device 200 obtains the Gaussian pyramid according to the pixel information I(x 1 , y 1 ) and the Gaussian function, wherein , the downsampling factor of the Gaussian function can be set to 2.
  • the second electronic device constructs a differential pyramid based on the Gaussian pyramid of the user interface 202 .
  • the second electronic device 200 applies a scale-invariant feature transform (SIFT) algorithm to determine the first feature point in the differential pyramid; for example, please refer to FIG. 8 , which is a schematic diagram of the differential pyramid.
  • SIFT scale-invariant feature transform
  • the three layers of images are image 2021, image 2022 and image 2023 respectively; image 2022 is adjacent to image 2021 and image 2023; the second electronic device 200 selects pixel T1 in image 2022, and then , compare the pixel T1 with the 26 pixels T2 in the image 2021, the image 2022 and the image 2023, if the pixel T1 is an extreme point, then determine that the pixel T1 is the first feature point; after that, the second electronic device 200 calculates according to the SIFT algorithm Obtain the position, scale and direction of the first feature point; and generate a feature vector of the first feature point according to the position, scale and direction of the first feature point;
  • the second electronic device 200 processes the second image 1041 , which specifically includes: first, the second electronic device 200 generates a grayscale image of the second image 1041 , denoting I(x 2 , y 2 ) as the position coordinates in the second image 1041 is the pixel information of the pixel of (x 2 , y 2 ). Secondly, the second electronic device 200 constructs a Gaussian pyramid according to the pixel information of each pixel in the second image 1041; specifically, the second electronic device 200 obtains the Gaussian pyramid according to the pixel information I(x 2 , y 2 ) and the Gaussian function calculation, Among them, the downsampling factor of the Gaussian function can be set to 2.
  • the second electronic device 200 constructs a differential pyramid according to the Gaussian pyramid of the second image 1041 .
  • the second electronic device 200 applies the SIFT algorithm to first determine the second feature point in the differential pyramid; then, calculates the position, scale and direction of the second feature point according to the SIFT algorithm; The location, scale and orientation generate a feature vector for the second feature point.
  • the second electronic device 200 calculates the similarity between the first feature point and the second feature point according to the feature vector of the first feature point and the feature vector of the second feature point; specifically, the second electronic device 200 can calculate the first feature point The Euclidean distance between the feature vector of the second feature point and the feature vector of the second feature point, when the Euclidean distance satisfies the preset condition, it is determined that the first feature point and the second feature point are a set of matching feature points;
  • the preset condition can be is: the Euclidean distance is less than or equal to the preset value, then it is determined that the first feature point and the second feature point are a set of matching feature points, or, the first feature point is the one with the smallest Euclidean distance from the second feature point in the user interface 202 feature points, the first feature point and the second feature point are determined as a set of matched feature points.
  • one feature point may represent one pixel.
  • the second electronic device 200 determines the first position in the user interface 202 according to the matching feature points between the user interface 202 and the second image 1041, and the position coordinates of the first position indicating mark 1042.
  • the user interface 202 includes feature points A1, A2, and A3, and the second image 1041 includes feature points A1', A2', and A3'; the feature points A1 and A1' are a set of matched features point, the feature point A2 and the feature point A2' are a set of matched feature points, and the feature point A3 and the feature point A3' are a set of matched feature points.
  • the second electronic device 200 can determine the position point A4 in the user interface 202 according to the position point A4', The position of the position point A4 relative to the feature points A1 , A2 and A3 is the same as the position of the position point A4 ′ relative to the feature points A1 ′, A2 ′ and A3 ′; the position point A4 is the first position in the user interface 202 . It should be noted that, in this embodiment of the present application, the second electronic device 200 may determine one or more sets of matching feature points, and determine the first position in the user interface 202 according to one or more sets of matching feature points .
  • FIG. 9A is a schematic diagram of the user interface 202
  • FIG. 9B which is a schematic diagram of the user interface 104 in the situation shown in FIG. 5D
  • the user interface 202 in FIG. 9A includes features Points A1, A2 and A3
  • FIG. 9B is a schematic diagram of the first electronic device stacking the second image 1041 and the first position indicator 1042; the second image 1041 includes feature points A1', A2' and A3' ; Wherein, feature point A1 and feature point A1' are a group of matching feature points, feature point A2 and feature point A2' are a group of matching feature points, A3 and feature point A3' are a group of matching feature points;
  • the position of a position indicator 1042 in the second image 1041 can be represented by a position point A4', that is, the relative position of the first position indicator 1042 and the second image 1041 can be represented by a position point A4' and feature points A1', A2'
  • the relative position of A3' and A3' is determined; when the second electronic device 200 obtains the relative positions of the position point A4' and the feature points A1', A2' and A3', as shown in FIG.
  • Position point A4 determines the user interface 202.
  • the second image 1041 is the same image in the first electronic device 100 and the second electronic device 200, and the data format is the same, the position coordinates of any pixel in the second image 1041 in the first electronic device 100 and The position coordinates in the second electronic device 200 are the same.
  • the second electronic device 200 when the second electronic device 200 receives the second image 1041 sent by the first electronic device 100, the second electronic device 100 can place the second image 1041 in the first coordinate system, and then can determine the Position coordinates of any point in the second image 1041 .
  • the second electronic device 200 can determine the position coordinates of the feature points A1 ′, A2 ′ and A3 ′ in the second image 1041 , since the first data packet contains the position coordinates of the first position indication mark 1042 , therefore, the position coordinates of A1', A2', A3' and A4' are all known.
  • A1 , A2 and A3 in the user interface 202 are known. Please refer to FIG.
  • the position coordinates of A1' are (Xa1', Ya1'), the position coordinates of A2' (Xa2', Ya2'), and the position coordinates of A4' (Xa4', Ya4') 9E
  • the position coordinates of A1 are (Xa1, Ya1), the position coordinates (Xa2, Ya2) of A2, if the first position in the user interface 202 is assumed to be A4, the position of A4
  • the coordinates are (Xa4, Ya4); referring to Figures 9D and 9E, it can be seen that the triangle formed by A1', A2' and A4' is similar to the triangle formed by A1, A2 and A4, and the following equations (1) (2) are obtained:
  • S14 The second electronic device 200 inserts the data information into the first position.
  • the second electronic device 200 first determines the application program 201 according to the first position; after that, the second electronic device invokes an application programming interface (Application Programming Interface, API) to insert data information into the user interface of the application program 201.
  • API Application Programming Interface
  • the following embodiment introduces another data transmission method provided by the embodiment of the present application.
  • the method is applied to a communication system, the communication system includes a first electronic device 100 and a second electronic device 200, the first electronic device 100 and the second electronic device 200 are communicatively connected, and the first electronic device 100 is provided with a camera.
  • the method may include:
  • the first electronic device 100 displays the first image 101 .
  • the related explanation of the first image 101 may refer to step S101, which will not be repeated here.
  • the display of the first image 101 by the first electronic device 100 may refer to FIG. 2B or FIG. 2C .
  • the first electronic device 100 shoots the scene shown in FIG. 2A in real time through the camera, obtains the first image 101 , and displays the first image 101 on the display screen;
  • the first image 101 is the preview screen displayed on the first electronic device 100 , that is, when the user moves the first electronic device 100 , the An image 101 changes as the first electronic device 100 moves.
  • the first electronic device 100 displays the first image 101 on the display screen and also displays the second position indication mark 105 , the display position and shape of the second position indicating mark 105 on the display screen of the first electronic device 100 are preset.
  • the position where the second position indicating mark 105 is located is in the center of the display screen, and the first The shape of the two position indicating marks 105 is a cross shape.
  • the first image 101 may be an image stored in the first electronic device 100 , and the user may open the first image 101 on the first electronic device 100 .
  • the first electronic device 100 detects a first user input.
  • step S102 For the explanation input by the first user, reference may be made to step S102, which will not be repeated here.
  • the detection of the first user input by the first electronic device 100 may be as shown in FIG. 3 .
  • the first electronic device 100 obtains the second image 1041 through real-time acquisition by the camera; the first electronic device 100 displays the second image 1041 and the first position indication mark 1042 in layers to obtain the user interface 104 ; and the first position indicator 1042 is located on the top layer; the second image 1041 includes the user interface of the second electronic device 200 .
  • the first position indication mark 1042 is a preset symbol mark of the first electronic device, for example, the first position indication mark 1042 shown in FIG. 5B may be a cross-shaped mark symbol. It should be noted that the position of the first position indication mark 1042 in the user interface 104 may be preset. For example, referring to FIG. 5B , the first position indication mark 1042 may be located in the center of the user interface 104 .
  • step S2031 may be further included after step S203:
  • the second image 1041 includes the user interface 202 of the second electronic device 200, and the position of the first position indication mark 1042 in the user interface 202 is where the user wants to insert data information into position in the user interface 202; then step S204 is executed. If after step S203, the second image 1041 does not include the user interface 202, or the second image 1041 includes the user interface 202, but in the first user interface 104, the first position indicator 1042 is not in the user interface 202, or , the position of the first position indication mark 1042 in the user interface 202 is not the position where the user wants to insert the data information into the user interface 202 , then step S2031 is executed first, and then step S204 is executed.
  • the first electronic device 100 detects a third user input, and in response to the third user input, the first electronic device 100 adjusts the display content in the second image 104, and the adjusted second image 1041 includes the user interface 202, and
  • the position of the first position indicator 1042 in the user interface 202 is the position where the user wants to insert the data information into the user interface 202 .
  • the second image 1041 includes part or all of the user interface of the second electronic device 200 .
  • FIG. 5A is a schematic diagram of a second electronic device 200 provided by an embodiment of the present application.
  • FIG. 5A includes: an electronic device 200 , an application 201 and a title bar 2011 in the application 201 .
  • the first position indication mark 1042 in FIG. 5B is a preset mark symbol.
  • the user can move the first electronic device 100, so that the second image 1041 captured by the first electronic device 100 through the camera includes the user interface of the second electronic device 200; specifically, the first position indicator 1042 is shown in FIG. 5B , a schematic diagram of the first electronic device 100 displaying the user interface 104 is shown in FIG. 5C .
  • the first position indication mark 1042 is located in the title bar 2011 .
  • the first electronic device 100 detects the second user input.
  • the second user input may include one or more types of input, for example, the second user input may be: voice input, touch operation, pressing operation, and the like.
  • the first user input is that the user presses the display screen of the first electronic device 100 for a long time
  • the second user input is that the first electronic device 100 detects that the user finishes performing a touch operation on the display screen of the first electronic device 100
  • the first user input is that the user touches the display screen of the electronic device 100; after that, the first electronic device 100 performs steps S202 to S203 in the process, the user keeps For the touch operation on the display screen of the electronic device 100 ; in step S204 , as shown in FIG. 6A , the user ends the touch operation on the first electronic device 100 , which is the second user input in this example.
  • the first electronic device 100 in response to the second user input, sends a first data packet to the second electronic device 200, where the first data packet includes the first image 101, the second image 1041, and the position of the first position indication mark 1042 information.
  • a specific representation of the data information included in the first data packet may be that the first data packet includes the first image 101 .
  • step S106 For an explanation of how the first electronic device 100 sends the first data packet to the second electronic device 200, reference may be made to the explanation of step S106.
  • the first image 101 may be a preview image acquired by the first electronic device 100 in real time through the camera, or may be an image stored in the first electronic device 100;
  • the first data packet further includes the position information of the second position indication mark 105 .
  • the second electronic device 200 performs image processing on the first image 101 to obtain data information in the first image 101 .
  • the second electronic device 200 performs image processing on the first image 101 to obtain the data information in the first image 101
  • the first electronic device 100 performs image processing on the first image 101 in step S103 to obtain the data in the first image 101 .
  • the process of the data information is the same, therefore, the explanation for step S103 can be referred to, and details are not repeated here.
  • it may include S2061, S2062 and S2063.
  • the second electronic device 200 executes step S2061 ; in the case that the first image 101 is an image stored in the first electronic device 100 , the second electronic device 200 executes step S2062 or 2063.
  • the second electronic device 200 determines the information area 103 where the second position indicator 105 is located, and performs image processing on the first image 101 to obtain data information in the information area 103 .
  • the second electronic device 200 determines an information area containing data information, if the number of information areas containing data information is one, then determines that the information area is the information area 103, and performs image processing on the first image 101 to obtain the information area Data information in 103.
  • the second electronic device 200 determines an information area containing data information, and if the number of information areas containing data information is multiple, displays the multiple information areas; after that, it detects that the user is not interested in one of the multiple information areas.
  • area selection instruction determine the information area 103 in the multiple information areas according to the selection instruction; perform image processing on the first image 101 to obtain the data information in the information area 103 .
  • the second electronic device 200 inserts the data information in the first image 101 into the user interface of the application program 201 according to the position information of the first position indication mark 1042 .
  • step S107 may specifically include steps: S11-S14; details are not repeated here.
  • FIG. 11 shows a schematic structural diagram of the electronic device 100. It should be noted that the electronic device 200 in this embodiment of the present application may have the same structure as the electronic device 100.
  • the electronic device 100 may be a cell phone, tablet, desktop, laptop, handheld computer, notebook, ultra-mobile personal computer (UMPC), netbook, as well as cellular phones, personal digital assistants (personal digital assistants) digital assistant (PDA), augmented reality (AR) devices, virtual reality (VR) devices, artificial intelligence (AI) devices, wearable devices, in-vehicle devices, smart home devices and/or Smart city equipment, the embodiment of the present application does not limit the specific type of the electronic equipment.
  • PDA personal digital assistants
  • AR augmented reality
  • VR virtual reality
  • AI artificial intelligence
  • 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 gyro 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 application 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 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 I2S interface and the 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 embodiments of the present application 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 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.
  • the wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), broadband 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 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 satellite system) -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
  • Beidou navigation satellite system beidou navigation satellite system, BDS
  • quasi-zenith satellite system quadsi 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 camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the 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 internal memory 121 may include one or more random access memories (RAM) and one or more non-volatile memories (NVM).
  • RAM random access memories
  • NVM non-volatile memories
  • Random access memory can include static random-access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double-rate synchronous dynamic Random access memory (double data rate synchronous dynamic random access memory, DDR SDRAM, such as fifth-generation DDR SDRAM is generally called DDR5 SDRAM), etc.;
  • SRAM static random-access memory
  • DRAM dynamic random access memory
  • SDRAM synchronous dynamic random access memory
  • DDR SDRAM double data rate synchronous dynamic random access memory
  • DDR SDRAM double data rate synchronous dynamic random access memory
  • DDR5 SDRAM fifth-generation DDR SDRAM
  • Non-volatile memory may include magnetic disk storage devices, flash memory.
  • Flash memory can be divided into NOR FLASH, NAND FLASH, 3D NAND FLASH, etc. according to the operating principle, and can include single-level memory cell (SLC), multi-level memory cell (multi-level memory cell, SLC) according to the level of storage cell potential.
  • cell, MLC multi-level memory cell
  • TLC triple-level cell
  • QLC quad-level cell
  • UFS universal flash storage
  • eMMC embedded multimedia memory card
  • the random access memory can be directly read and written by the processor 110, and can be used to store executable programs (eg, machine instructions) of an operating system or other running programs, and can also be used to store data of users and application programs.
  • executable programs eg, machine instructions
  • the random access memory can be directly read and written by the processor 110, and can be used to store executable programs (eg, machine instructions) of an operating system or other running programs, and can also be used to store data of users and application programs.
  • the non-volatile memory can also store executable programs and store data of user and application programs, etc., and can be loaded into the random access memory in advance for the processor 110 to directly read and write.
  • the external memory interface 120 can be used to connect an external non-volatile memory, so as to expand the storage capacity of the electronic device 100 .
  • the external non-volatile memory communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example, save music, video, etc. files in external non-volatile memory.
  • 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 near the microphone 170C through the 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 may be the USB interface 130, or may 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 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.
  • the electronic device 100 determines the intensity of the pressure according to the change in capacitance.
  • 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.
  • the instruction for viewing the short message is executed.
  • 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 unlocks and locks the 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 photos 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.
  • 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.
  • 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 vocal vibration bone block obtained by the 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 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 .
  • 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 for connecting 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 plurality of 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 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. 12 is a block diagram of the software structure of the electronic device 100 according to the embodiment of the present application.
  • 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 layer may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and short message.
  • 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 a window manager, a content provider, a view system, a telephony manager, a resource manager, a notification manager, 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 data may 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 that appear 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.
  • 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 control of the camera application icon as an example, the camera application calls the interface of the application framework layer to start the camera application, and then starts the camera driver by calling the kernel layer, and then starts the camera driver by calling the kernel layer.
  • the camera 193 captures still images or video.
  • Each functional unit in each of the embodiments of the embodiments of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium.
  • the computer software products are stored in a storage
  • the medium includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: flash memory, removable hard disk, read-only memory, random access memory, magnetic disk or optical disk and other media that can store program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

一种数据传输方法及一种电子设备,方法包括:第一电子设备(100)显示第一图像(101);第一电子设备(100)检测到第一用户输入;响应于第一用户输入,第一电子设备(100)显示第一用户界面(104),第一用户界面(104)中包括第一位置指示标记(1042)和通过摄像头获取到的第二图像(1041);在第二图像(1041)中包括第二用户界面(202),且第一位置指示标记(1042)位于第二用户界面(202)中的位置为第一位置时,第一电子设备(100)检测到第二用户输入;响应于第二用户输入,第一电子设备(100)向第二电子设备(200)发送第一数据包,第一数据包中包括第二图像(1041),数据信息和第一位置指示标记(1042)的位置信息;第二电子设备(200)根据第一数据包将数据信息插入到第二用户界面(202)中的第一位置处。实施本申请实施例有利于提升数据传输的效率。

Description

数据传输方法及电子设备
本申请要求于2021年02月08日提交中国专利局、申请号为202110182682.2、申请名称为“数据传输方法及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及电子技术领域,特别涉及数据传输方法及电子设备。
背景技术
随着电子技术的迅猛发展,电子设备的使用场景越来越多,大众使用电子设备的种类越来越多。当前人们在不同场景下根据需求在不同的设备之间进行切换,例如用户拥有手机和个人电脑;用户可以在手机和电脑上使用不同的功能,进而达到不同的目的。当前,用户在某些场景中需要手机和电脑之间进行协作,使得用户需要不断的切换使用设备,进而完成需要处理的事项。
发明内容
第一方面,本申请提供一种数据传输方法,应用于通信系统,所述通信系统包括第一电子设备和第二电子设备,所述第一电子设备和所述第二电子设备通信连接;所述第一电子设备安装有摄像头;所述方法包括:所述第一电子设备显示第一图像,所述第一图像中包括数据信息;所述第一电子设备检测到第一用户输入;响应于所述第一用户输入,所述第一电子设备显示第一用户界面,所述第一用户界面中包括第一位置指示标记和通过所述摄像头获取到的第二图像;在所述第二图像中包括第二用户界面,且所述第一位置指示标记位于所述第二用户界面中的位置为第一位置时,所述第一电子设备检测到第二用户输入,所述第二用户界面是指所述第二电子设备显示的用户界面;响应于所述第二用户输入,所述第一电子设备向所述第二电子设备发送第一数据包,所述第一数据包中包括所述第二图像,所述数据信息和所述第一位置指示标记的位置信息;所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处。
可见,本申请实施例中,用户想要将第一图像中的数据信息插入到第二电子设备中时,用户可以首先针对第一电子设备执行第一用户输入,其次,在第一位置指示标记在第二用户界面中的位置为第一位置时,针对第一电子设备执行第二用户输入,其次,第一电子设备向第二电子设备发送第一数据包,第二电子设备即可将数据信息插入到第二用户界面中的第一位置处。实时本申请实施例有利于简化从第一电子设备向第二电子设备传输数据信息的步骤,进而有利于提升数据传输的效率。
结合第一方面,在一种可能的实现方式中,在所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处方面,所述方法还包括:所述第二电子设备确定所述第二用户界面和所述第二图像中的匹配特征点;所述第二电子设备根据所述匹配特征点和所述第一位置指示标记的位置信息,确定出所述第二用户界面中的第一位置;所述第二电子设备将所述数据信息插入到所述第一位置处。
可见,本示例中,第二电子设备可以根据特征点确定出第二用户界面中的第一位置。
结合第一方面,在一种可能的实现方式中,所述第一电子设备检测到所述第二用户输入的时间点为第一时间点;所述第一位置指示标记的位置信息表示在所述第一时间点时所述第一位置指示标记在第一坐标系中的位置坐标。
结合第一方面,在一种可能的实现方式中,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到所述第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:所述第一电子设备根据所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一信息区域中的所述数据信息。
可见,本示例中,第一电子设备可以根据第二位置指示标记准确的从第一图像中确定出第一信息区域,进而从第一信息区域中得到用户想要插入到第二用户界面中的数据信息。
结合第一方面,在一种可能的实现方式中,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为一,则所述第一电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
可见,本示例中,在第一图像中只包括一个信息区域的情况下,第一电子设备针对该信息区域进行图像处理,得到用户想要插入到第二用户界面中的数据信息,提升了得到数据信息的效率。
结合第一方面,在一种可能的实现方式中,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第一电子设备显示两个或两个以上的所述信息区域;所述第一电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;所述第一电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所述第一信息区域;所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
可见,本示例中,在第一图像中包括多个信息区域的情况下,第一电子设备可以接收针对多个信息区域的选择指令,进而根据选择指令确定出第一信息区域,使得针对第一信息区域执行图像处理后得到的数据信息是用户想要插入到第二用户界面中的数据信息。
结合第一方面,在一种可能的实现方式中,所述第一数据包中包括的所述数据信息具体指的是针对所述第一图像进行图像处理后得到的数据信息。
结合第一方面,在一种可能的实现方式中,所述第一数据包中包括的所述数据信息由所述第一图像携带,所述第一数据包中包括所述第一图像。
结合第一方面,在一种可能的实现方式中,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到所述第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述第一数据包中还包括所述第二位置指示标记,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:所述第二电子设备根据 所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一信息区域中的所述数据信息。
可见,本示例中,第二电子设备可以根据第二位置指示标记准确的从第一图像中确定出第一信息区域,进而从第一信息区域中得到用户想要插入到第二用户界面中的数据信息。
结合第一方面,在一种可能的实现方式中,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为一,则所述第二电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
可见,本示例中,在第一图像中只包括一个信息区域的情况下,第二电子设备针对该信息区域进行图像处理,得到用户想要插入到第二用户界面中的数据信息,提升了得到数据信息的效率。
结合第一方面,在一种可能的实现方式中,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第二电子设备显示两个或两个以上的所述信息区域;所述第二电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;所述第二电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所述第一信息区域;所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
可见,本示例中,在第一图像中包括多个信息区域的情况下,第二电子设备可以接收针对多个信息区域的选择指令,进而根据选择指令确定出第一信息区域,使得针对第一信息区域执行图像处理后得到的数据信息是用户想要插入到第二用户界面中的数据信息。
结合第一方面,在一种可能的实现方式中,所述第一位置指示标记是所述第一图像中包括所述数据信息的第一信息区域。
结合第一方面,在一种可能的实现方式中,所述第一位置指示标记是预设置的标记符号。
结合第一方面,在一种可能的实现方式中,所述第一用户输入为针对所述第一电子设备的触控操作;所述第二用户输入为结束针对所述第一电子设备的所述触控操作。
第二方面,本申请提供一种数据传输方法,其特征在于,应用于第一电子设备,所述第一电子设备和第二电子设备通信连接;所述第一电子设备安装有摄像头;所述方法包括:所述第一电子设备显示第一图像,所述第一图像中包括数据信息;所述第一电子设备检测到第一用户输入;响应于所述第一用户输入,所述第一电子设备显示第一用户界面,所述第一用户界面中包括第一位置指示标记和通过所述摄像头获取到的第二图像;在所述第二图像中包括第二用户界面,且所述第一位置指示标记位于所述第二用户界面中的位置为第一位置时,所述第一电子设备检测到第二用户输入,所述第二用户界面是指所述第二电子设备显示的用户界面;响应于所述第二用户输入,所述第一电子设备向所述第二电子设备发送第一数据包,所述第一数据包中包括所述第二图像,所述数据信息和所述第一位置指示标记的位置信息。
结合第二方面,在一种可能的实现方式中,所述第一电子设备检测到所述第二用户输入的时间点为第一时间点;所述第一位置指示标记的位置信息表示在所述第一时间点时所述第一位置指示标记在第一坐标系中的位置坐标。
结合第二方面,在一种可能的实现方式中,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到所述第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:所述第一电子设备根据所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一信息区域中的所述数据信息。
结合第二方面,在一种可能的实现方式中,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为一,则所述第一电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
结合第二方面,在一种可能的实现方式中,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第一电子设备显示两个或两个以上的所述信息区域;所述第一电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;所述第一电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所述第一信息区域;所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
结合第二方面,在一种可能的实现方式中,所述第一数据包中包括的所述数据信息具体指的是针对所述第一图像进行图像处理后得到的数据信息。
第三方面,本申请提供一种数据传输方法,应用于第二电子设备,所述第二电子设备和第一电子设备通信连接;所述第一电子设备安装有摄像头;所述方法包括:所述第二电子设备接收所述第一电子设备发送的第一数据包,所述第一数据包中包括第二图像,数据信息和第一位置指示标记的位置信息;所述第二电子设备根据所述第一数据包将所述数据信息插入到第二用户界面中的第一位置处,所述第二用户界面是指所述第二电子设备显示的用户界面。
结合第三方面,在一种可能的实现方式中,所述第二电子设备根据所述第一数据包将所述数据信息插入到第二用户界面中的第一位置处,包括:所述第二电子设备确定所述第二用户界面和所述第二图像中的匹配特征点;所述第二电子设备根据所述匹配特征点和所述第一位置指示标记的位置信息,确定出所述第二用户界面中的第一位置;所述第二电子设备将所述数据信息插入到所述第一位置处。
结合第三方面,在一种可能的实现方式中,所述第一数据包中包括的所述数据信息由第一图像携带,所述第一数据包中包括所述第一图像。
结合第三方面,在一种可能的实现方式中,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述第一数据包中还包括所述第二位置指示标记,所述第二电子设备接收所述第一电子设备发送的第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到第二用户界面中的第一位置处之前,所述方法还包括:所述第二电子设备根据所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一 信息区域中的所述数据信息。
结合第三方面,在一种可能的实现方式中,所述第二电子设备接收所述第一电子设备发送的第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到第二用户界面中的第一位置处之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为一,则所述第二电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
结合第三方面,在一种可能的实现方式中,所述第二电子设备接收所述第一电子设备发送的第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到第二用户界面中的第一位置处之前,所述方法还包括:若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第二电子设备显示两个或两个以上的所述信息区域;所述第二电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;所述第二电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所述第一信息区域;所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
第四方面,本申请实施例提供一种电子设备,所述电子设备包括:一个或多个处理器和存储器;所述存储器与所述一个或多个处理器耦合,所述存储器用于存储计算机程序代码,所述计算机程序代码包括计算机指令,所述一个或多个处理器调用所述计算机指令以使得所述电子设备执行如第一方面及其任一种可能的实现方式,或第二方面及其任一种可能的实现方式,或第三方面及其任一种可能的实现方式。
第五方面,提供一种芯片系统,所述芯片系统应用于电子设备,所述芯片系统包括一个或多个处理器,所述处理器用于调用计算机指令以使得所述电子设备执行如第一方面及其任一种可的实现方式,或第二方面及其任一种可能的实现方式,或第三方面及其任一种可能的实现方式。
第六方面,本申请提供一种计算机程序产品,当所述计算机程序产品在电子设备上运行时,使得所述电子设备执行如第一方面及其任一种可能的实现方式,或第二方面及其任一种可能的实现方式,或第三方面及其任一种可能的实现方式。
第七方面,本申请提供一种计算机可读存储介质,该计算机可读存储介质包括计算机指令,当所述计算机指令在电子设备上运行时,使得所述电子设备执行如第一方面及其任一种可能的实现方式,或第二方面及其任一种可能的实现方式,或第三方面及其任一种可能的实现方式。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对本申请实施例中所需要使用的附图进行说明。
图1是本申请实施例提供的一种数据传输方法的流程示意图;
图2A是本申请实施例提供的一种场景示意图;
图2B和图2C是本申请实施例提供的一种显示第一图像的示意图;
图3为本申请实施例提供的用户针对电子设备100的显示屏执行触控操作的示意图;
图4A是本申请实施例提供的一种电子设备100的示意图;
图4B至图4D是本申请实施例提供的一组确定信息区域的示意图;
图5A是本申请实施例提供的一种电子设备200的示意图;
图5B至图5D是本申请实施例提供的一组电子设备100的示意图;
图6A至6B是本申请实施例提供的用户结束针对电子设备100的显示屏执行触控操作的示意图;
图7是本申请实施例提供的一种电子设备200的示意图;
图8是本申请实施例提供的一种差分金字塔的示意图;
图9A是本申请实施例提供的一种用户界面202的示意图;
图9B是本申请实施例提供的一种用户界面104的示意图;
图9C是本申请实施例提供的另一种用户界面202的示意图;
图9D和图9E是本申请实施例提供的一组位置关系的示意图;
图10是本申请实施例提供的另一种数据传输方法的流程示意图;
图11是本申请实施例提供的一种电子设备100的结构示意图;
图12是本申请实施例提供的一种电子设备100的软件结构框图。
具体实施方式
本申请以下实施例中所使用的术语只是为了描述特定实施例的目的,而并非旨在作为对本申请的限制。如在本申请的说明书和所附权利要求书中所使用的那样,单数表达形式“一个”、“一种”、“所述”、“上述”、“该”和“这一”旨在也包括复数表达形式,除非其上下文中明确地有相反指示。还应当理解,本申请中使用的术语“和/或”是指并包含一个或多个所列出项目的任何或所有可能组合。
以下,术语“第一”、“第二”仅用于描述目的,而不能理解为暗示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括一个或者更多个该特征,在本申请实施例的描述中,除非另有说明,“多个”的含义是两个或两个以上。
在一些实施例中,电子设备可以根据光学字符识别(Optical Character Recognition,OCR)针对图像进行处理,获取图像中的文本信息;使得用户想要编辑图像中的文本信息时,无需手动输入文本信息,可以在电子设备上直接编辑图像中包括的文本信息,提升了处理文本信息的效率。其中,光学字符识别是指对文本资料的图像文件进行分析识别处理,获取文字及版面信息的过程。
在一些实施例中,第一电子设备和第二电子设备通信连接。第一电子设备中的第一应用程序和第二电子设备中的第二应用程序相互之间可以传输数据信息。用户可以在第一电子设备上查看图像,图像中包括文本信息;当用户想要将图像中的文本信息粘贴至第二电子设备上的第三应用程序时,可以通过以下步骤实现用户的目的:用户首先针对第一电子设备执行操作B1;第一电子设备检测到操作B1(例如操作B1可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),响应于用户的操作B1,第一电子设备根据光学字符识别针对图像进行处理,得到图像中的文本信息;之后,用户可以针对第一电子设备执行操作B2(例如可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),响应于操作B2,第一电子设备通过第一应用程序向第二电子设备发送文本信息;第二电子设备的第二应用程序接收到文本信息;之后,用户针对第二电子设备执行操作B3(例如可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),响应于操作B3,第二电子设备将第二应用程序 中的文本信息粘贴至第三应用程序的用户界面中。可见,在一些实施例中,当用户想要将第一电子设备中存储的图像中的文本信息粘贴至第二电子设备中的第三应用程序中时,需要经过复杂的操作过程,导致设备之间文本信息的传输效率较低。
在一些实施例中,第一电子设备和第二电子设备通信连接。用户可以在第一电子设备上查看图像,图像中包括文本信息;当用户想要将图像中的文本信息粘贴至第二电子设备上的应用程序中的用户界面时,可以通过以下步骤实现用户的目的:用户首先针对第一电子设备进行执行操作B1;第一电子设备检测到操作B1(例如可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),响应于用户的操作B1,第一电子设备向第二电子设备发送图像;第二电子设备接收到图像之后,用户可以针对第二电子设备执行操作B2(例如可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),响应于操作B2,第二电子设备根据光学字符识别针对图像进行处理,得到图像中的文本信息;之后,用户针对第二电子设备执行操作B3(例如可以是针对第一电子设备的触控操作,按压操作,语音输入操作等),第二电子设备响应于操作B3,将文本信息粘贴至第三应用程序的用户界面中。可见,在一些实施例中,当用户想要将第一电子设备存储的图像中的文本信息粘贴至第二电子设备中的第三应用程序中时,需要经过复杂的操作过程,导致设备之间文本信息的传输效率较低。
下面实施例提供一种数据传输方法。该方法应用于通信系统,通信系统包括第一电子设备100和第二电子设备200,第一电子设备100和第二电子设备200通信连接,第一电子设备100设置有摄像头。如图1所示,该方法可以包括:
S101,第一电子设备100显示第一图像101。
在一些实施例中,第一图像101可以是第一电子设备100通过摄像头实时获取的预览画面。请参阅图2A,图2A是本申请实施例提供的一种场景示意图。如图2B所示,第一电子设备100通过摄像头针对图2A所示的场景实时获取,得到第一图像101,并在显示屏上显示第一图像101;可以理解的是,在第一图像101中的图像是第一电子设备100通过摄像头实时获取到的情况下,第一图像101是第一电子设备100上显示的预览画面,即在用户移动第一电子设备100时,第一图像101随着第一电子设备100的移动而变化。请参阅图2B,在第一图像101是第一电子设备100通过摄像头获取到的图像的情况下,第一电子设备100在显示屏上显示第一图像101的同时还显示第二指示标记105,第二位置指示标记105在第一电子设备100的显示屏上的显示位置和形状是预设置的,例如,图2B中,第二位置指示标记105所在的位置处于显示屏的中心,且第二位置指示标记105的形状为十字形状。
在一些实施例中,如图2C所示,第一图像101可以是存储在第一电子设备100中的图像,用户可以在第一电子设备100上打开第一图像101。
S102,第一电子设备100检测到第一用户输入。
在一些实施例中,第一用户输入可以是包括一种或多种类型的输入,例如第一用户输入可以是:语音输入,触控操作,按压操作等。
举例来说,在图2C所示的情况下,且第一用户输入为触控操作时,请参阅图3,图3为本申请实施例提供的用户针对电子设备100的显示屏执行触控操作的示意图。
S103,第一电子设备100响应于第一用户输入,针对第一图像101进行图像处理,得到第一图像101中的数据信息;并且,第一电子设备100通过摄像头采集得到第二图像1041,第一电子设备100层叠显示第二图像1041和第一位置指示标记1042,得到第一用户界面
104,第一位置指示标记1042位于顶层。
步骤S103中,针对第一图像101进行图像处理,得到第一图像101中的数据信息,具体可以包括步骤S1031或步骤S1032或步骤S1033。具体的,在步骤S101的解释说明中说明了第一图像101可以是第一电子设备100通过摄像头实时获取的预览画面,也可以是存储在第一电子设备100中的图像;在第一图像101是第一电子设备100通过摄像头实时获取到的预览画面的情况下,第一电子设备100执行步骤S1031;在第一图像101是存储在第一电子设备100中的图像的情况下,第一电子设备100执行步骤S1032或1033。
S1031,第一电子设备100确定出第二位置指示标记105所在的信息区域103,针对第一图像进行图像处理,确定出信息区域103,并得到信息区域103中的数据信息。
举例来说,请参阅图2B,图2B中包括数据信息“会议报告”,第二位置指示标记105位于包含“会议报告”的信息区域中,因此,第一电子设备100确定包含“会议报告”的信息区域为信息区域103,请参阅图4A,图4A示意了信息区域103。
S1032,第一电子设备100确定出包含数据信息的信息区域,若包含数据信息的信息区域的数量为一个,则确定该信息区域为信息区域103,针对第一图像101进行图像处理,得到信息区域103中的数据信息。
S1033,第一电子设备100确定出包含数据信息的信息区域,若包含数据信息的信息区域的数量为多个,则显示多个信息区域;之后,检测到用户对于多个信息区域中的一个信息区域的选择指令;根据选择指令确定出多个信息区域中的信息区域103;针对第一图像101进行图像处理,得到信息区域103中的数据信息。
举例来说,请参阅图4B,如图4B所示,第一电子设备100显示第一图像101,第一图像101中包括信息区域103和信息区域106;之后,如图4C所示,第一电子设备100显示信息区域103和信息区域106;之后,如图4D所示,第一电子设备100检测到用户对于信息区域103的选择指令,即确定出信息区域103;之后,第一电子设备100可以针对第一图像101进行图像处理,得到信息区域103中的数据信息。
需要说明的是,第一位置指示标记1042在用户界面104中的位置可以是预设置的,例如,参阅图5B,第一位置指示标记1042可以位于用户界面104的中心。
本申请实施例中,第一电子设备100显示用户界面时是层叠显示多张图层,得到最终显示到显示屏上的用户界面104的;本示例中,第二图像1041为一层图层,第一位置指示标记1042为一层图层,第一电子设备100将第一位置指示标记1042所在的图层置于第二图像1041所在的图层之上(或置于顶层)进行显示,即可得到第一用户界面104;具体的,第一电子设备100可以调用应用程序编程接口将第一位置指示标记1042所在的图层置于的第二图像1041所在的图层之上;具体的,在第一电子设备运行安卓操作系统TM的情况下,调用的应用程序编程接口可以是布局(layout)应用程序编程接口。
其中,数据信息的表现形式可以是图片或文字;数据信息具体可以是文本信息;也可以是某一特定物体的图片,例如数据信息可以是一只小鸟的图片。
在一些实施例中,第一电子设备100针对第一图像101进行图像处理,可以确定出第一图像101中的信息区域103。
其中,针对第一图像101进行图像处理可以具体指针对第一图像101进行光学字符识别。在一些实施例中,数据信息可以具体指图像中包括的文本信息;例如在第一图像101中包括文字的情况下,第一电子设备100针对第一图像101进行光学字符识别后,可以确定出第一图像101中包含文字的区域,即为上述说明的信息区域,同时第一电子设备100可以根据第一图像中包含的文字生成对应的文本信息。举例来说,如图3所示的第一图像101, 第一图像101中包含“会议报告”四个字,则针对第一图像101进行光学字符识别处理,可以确定出如图4A所示的包含“会议报告”四个字的区域103(即为信息区域),同时可以生成“会议报告”四个字的文本信息;需要说明的是,生成的文本信息为电子设备可以编辑的信息。
需要说明的是,本申请实施例中,用户界面104也可以被称为第一用户界面;第二电子设备200的用户界面202也可以被称为第二用户界面。
其中,第一位置指示标记1042位于顶层,表示第一位置指示标记1042的显示内容不会被第二图像1041的显示内容遮挡,第一位置指示标记1042的显示内容可以遮挡第二图像1041的显示内容。
需要说明的是,第二图像1041中可以包括第二电子设备200的用户界面202的部分或全部。
在一些实施例中,第一位置指示标记1042可以是预设置的标记符号,或者,第一位置指示标记1042为第一图像101中的信息区域103。
在一些实施例中,执行步骤S103之后,第二图像1041中包括第二电子设备200的用户界面202,且第一位置指示标记1042在用户界面202中的位置是用户想要将数据信息插入到用户界面202中的第一位置;则执行步骤S105。若步骤S103之后,第二图像1041中不包括用户界面202,或者,第二图像1041中包括用户界面202,但在第一用户界面104中,第一位置指示标记1042不在用户界面202中,或者,第一位置指示标记1042在用户界面202中的位置不是用户想要将数据信息插入到用户界面202中的第一位置,则首先执行步骤S104,之后再执行步骤S105。
S104,第一电子设备100检测到第三用户输入,响应于第三用户输入,第一电子设备100调整第二图像104中的显示内容,调整后的第二图像1041中包括用户界面202,且第一位置指示标记1042在用户界面202中的位置为用户想要将数据信息插入到用户界面202中的第一位置。
举例来说,第三用户输入为用户移动第一电子设备100;用户可以移动第一电子设备100(即调整第一电子设备100通过摄像头获取到的拍摄场景),使得第一电子设备100通过摄像头获取到的第二图像1041中包括第二电子设备200的用户界面202。
对于步骤S104,举例来说,请参阅图5A,图5A是本申请实施例提供的第二电子设备200的示意图。图5A中包括:第二电子设备200,第二电子设备200的用户界面202、应用程序201和应用程序201中的标题栏2011。第一位置指示标记1042为预设置的标记符号时,请参阅图5B所示的第一位置指示标记1042;第一位置指示标记1042为第一图像101中的信息区域103时,请参阅图4A,图4A中包含文本信息“会议报告”的信息区域103即可视为第一位置指示标记1042。用户可以移动第一电子设备100,使得第一电子设备100通过摄像头拍摄得到的第二图像1041中包括第二电子设备200的用户界面202,且第一位置指示标记1042在用户界面202中的位置为用户想要将数据信息插入到用户界面202中的第一位置;具体的,在第一位置指示标记1042如图5B所示的情况下,第一电子设备100显示用户界面104的示意图如图5C所示;在第一位置指示标记1042如图4A所示的情况下,第一电子设备100显示用户界面104的示意图如图5D所示。如图5C和图5D所示,第一位置指示标记1042或信息区域103位于标题栏2011中。
S105,第一电子设备100检测到第二用户输入。
在一些实施例中,第二用户输入可以是包括一种或多种类型的输入,例如第二用户输入 可以是:语音输入,触控操作,按压操作等。
在一些实施例中,第一用户输入为用户保持对于第一电子设备100的显示屏的触控操作,第二用户输入为第一电子设备100检测到用户结束对于第一电子设备100的显示屏执行触控操作;举例来说,在步骤S102,如图3所示,用户触控电子设备100的显示屏,并保持对于显示屏的触控操作;在用户保持对于显示屏的触控操作的过程中,第一电子设备100执行步骤S102~步骤S104;在步骤S105中,如图6A或图6B所示,用户结束对于第一电子设备100的触控操作,即为本示例中的第二用户输入;具体的,在用户界面104如图5C所示的情况下,步骤S105的示例说明请参阅图6A;在用户界面104如图5D所示的情况下,步骤S105的示例说明请参阅图6B。
S106,响应于第二用户输入,第一电子设备100向第二电子设备200发送第一数据包,第一数据包中包括第二图像1041、第一位置指示标记1042的位置信息、以及第一图像101中的数据信息。
需要说明的是,第一图像101中的数据信息具体指针对第一图像101进行图像处理后得到的数据信息。
其中,第一电子设备100检测到第二用户输入的时间点为第一时间点;第一数据包中第一位置指示标记1042的位置信息可以具体表示在第一时间点时第一位置指示标记1042在第一电子设备100构建的第一坐标系中的位置坐标;需要说明的是,第一电子设备100可以确定出第二图像1041中任意一个像素(位置点)在第一坐标系中的位置坐标,第一坐标系可以具体指第一电子设备100的相机坐标系。或者,第一数据包中第一位置指示标记1042的位置信息可以具体表示在第一时间点之后的预设时长后第一位置指示标记1042的位置坐标,例如,预设时长为1秒,则位置信息具体表示第一时间点的后1秒时第一位置指示标记1042的位置坐标。
在一些实施例中第一电子设备100和第二电子设备200直接连接,第一电子设备100可以直接将第一数据包发送至第二电子设备200。在一些实施例中,第一电子设备100和第二电子设备200间接连接,第一电子设备100和第三电子设备通信连接,第二电子设备200和第三电子设备通信连接;第一电子设备100可以通过第三电子设备将第一数据包发送至第二电子设备200。
在一些实施例中,第一电子设备100安装有应用程序C1,第二电子设备200安装有应用程序C2,第一电子设备100向第二电子设备200发送第一数据包具体可以是:应用程序C1向应用程序C2发送第一数据包。其中,第一数据包中在包含不同数据信息时可以在不同数据信息中添加消息头,具体的,在步骤S106中,第一数据包中包括第二图像1041、第一位置指示标记1042的位置信息、以及第一图像101中的数据信息;则分别对应三类数据,即图像数据,位置数据,和文本数据,其中第一数据包中每种数据之前都具有对应的消息头,例如图像数据之前包括图像数据消息头,位置数据之前包括位置消息头,文本数据之前包括文本消息头。第二电子设备200在接收到第一数据包之后,根据数据包中的消息头确定出对应的数据格式,根据数据格式解析数据包中的数据,最终得到数据包中的数据。例如根据图像数据消息头确定出图像对应的数据格式,根据图像对应的数据格式解析数据包中图像数据消息头之后的数据,得到第一数据包中的第二图像1041。
S107,第二电子设备200根据第一数据包中将第一图像101中的数据信息插入到应用程序201的用户界面中。
需要说明的是,本申请实施例中电子设备200的用户界面202是包含应用程序201的用 户界面的,因此,将第一图像101中的数据信息插入到应用程序201的用户界面中可以视为将第一图像101中的数据信息插入到用户界面202中。
其中,第一图像101中的数据信息插入的位置是根据第一位置指示标记1042的位置信息确定出的。可见,本申请实施例中,用户想要在应用程序201中插入第一图像101中的文本信息时,用户可以首先执行第一用户输入;之后,第一电子设备100显示通过摄像头获取到的第二图像1041;第一电子设备100层叠显示第二图像1041和第一位置指示标记1042,得到第一用户界面104;用户可以移动第一电子设备100(即调整了第一电子设备100通过摄像头获取到的拍摄场景,因此第二图像中1041中的显示内容发生了变化),使得第二图像1041中包括第二电子设备200的用户界面202;用户在第一电子设备100上确定出第一位置指示标记1042位于用户界面202中的第一位置时(第一位置是用户想要将数据信息插入到用户界面202中的位置),用户执行第二用户输入,响应于第二用户输入之后,第二电子设备100即可将第一图像101中的数据信息插入到第一位置处;举例来说,第二电子设备200将数据信息插入到应用程序201的用户界面后如图7所示,由于图5C和图5D中,第一位置指示标记1042(或可以称为信息区域103)位于用户界面202的标题栏2011中,因此,图7中插入的文本信息“会议报告”位于标题栏2011中。本申请实施例有利于简化将第一电子设备100中查看到的数据信息插入到第二电子设备200的应用程序201中的过程,提升了插入数据信息的效率。
在一些实施例中,步骤S107可以具体包括以下步骤S11~S14:
S11:第二电子设备200获取当前显示屏显示的用户界面202。
举例来说,显示屏显示的用户界面202可以参阅图5A中的用户界面202。
S12:第二电子设备200确定出用户界面202和第二图像1041之间的匹配特征点。
在一些实施例中,第二电子设备200可以计算出用户界面202中的第一特征点和第二图像1041中的第二特征点的相似度,在第一特征点和第二特征点的相似度满足预设条件的情况下,确定第一特征点和第二特征点为一组匹配特征点;其中,预设条件可以是:第一特征点和第二特征点的相似度大于预设阈值,或者,第一特征点为用户界面202中与第二特征点的相似度最高的特征点。
需要说明的是,本申请实施例中,一个特征点具体可以指一个像素。
在一些实施例中,第二电子设备200确定第一特征点和第二特征点为匹配特征点的方式可以是通过构建图像金字塔的方式确定出的,具体可以是:
第二电子设备200针对用户界面202进行处理,具体包括:首先,第二电子设备200生成用户界面202的灰度图像,记I(x 1,y 1)为在用户界面202中位置坐标为(x 1,y 1)的像素的像素信息(举例来说,像素信息可以包括RGB值)。其次,第二电子设备200根据用户界面202中每个像素的像素信息构建高斯金字塔;具体的,第二电子设备200根据像素信息I(x 1,y 1)和高斯函数计算得到高斯金字塔,其中,高斯函数的降采样因子可以设置为2。其次,第二电子设备根据用户界面202的高斯金字塔构建差分金字塔。其次,第二电子设备200应用尺度不变特征变换(Scale-invariant feature transform,SIFT)算法,确定出差分金字塔中的第一特征点;举例来说,请参阅图8,图8是差分金字塔中一组图像中的三层图像,三层图像分别为图像2021,图像2022和图像2023;图像2022与图像2021和图像2023相邻;第二电子设备200选定图像2022中的像素T1,之后,将像素T1与图像2021、图像2022和图像2023中26个像素T2进行比较,若像素T1为极值点,则确定像素T1为第一特征点;之后,第二电子设备200根据SIFT算法计算得到第一特征点的位置、所处尺度和方向;并根 据第一特征点的位置、所处尺度和方向生成第一特征点的特征向量;
第二电子设备200针对第二图像1041进行处理,具体包括:首先,第二电子设备200生成第二图像1041的灰度图像,记I(x 2,y 2)为第二图像1041中位置坐标为(x 2,y 2)的像素的像素信息。其次,第二电子设备200根据第二图像1041中每个像素的像素信息构建高斯金字塔;具体的,第二电子设备200根据像素信息I(x 2,y 2)和高斯函数计算得到高斯金字塔,其中,高斯函数的降采样因子可以设置为2。其次,第二电子设备200根据第二图像1041的高斯金字塔构建差分金字塔。其次,第二电子设备200应用SIFT算法,首先确定出差分金字塔中的第二特征点;之后,根据SIFT算法计算得到第二特征点的位置、所处尺度和方向;并根据第二特征点的位置、所处尺度和方向生成第二特征点的特征向量。
第二电子设备200根据第一特征点的特征向量和第二特征点的特征向量计算出第一特征点和第二特征点的相似度;具体的,第二电子设备200可以计算第一特征点的特征向量和第二特征点的特征向量之间的欧式距离,在欧式距离满足预设条件时确定出第一特征点和第二特征点为一组匹配特征点;具体的,预设条件可以是:欧式距离小于等于预设数值,则确定第一特征点和第二特征点为一组匹配特征点,或者,第一特征点是用户界面202中与第二特征点的欧氏距离最小的特征点,则确定第一特征点和第二特征点为一组匹配的特征点。
需要说明的是,本申请实施例中,一个特征点可以表示一个像素。
S13:第二电子设备200根据用户界面202和第二图像1041之间的匹配特征点,和,第一位置指示标记1042的位置坐标,确定出用户界面202中的第一位置。
在一些实施例中,用户界面202中包括特征点A1、A2和A3,第二图像1041中包括特征点A1'、A2'和A3';特征点A1和特征点A1'为一组匹配的特征点,特征点A2和特征点A2'为一组匹配的特征点,A3和特征点A3'为一组匹配的特征点。若用户界面104中第一位置指示标记1042在第一坐标系中的位置可以用位置点A4'表示,则第二电子设备200可以根据位置点A4'确定出用户界面202中的位置点A4,位置点A4相对于特征点A1、A2和A3的位置与位置点A4'相对于特征点A1'、A2'和A3'的位置相同;位置点A4即为用户界面202中的第一位置。需要说明的是,本申请实施例中,第二电子设备200可以确定出一组或多组匹配的特征点,并根据一组或多组匹配的特征点确定出用户界面202中的第一位置。
举例来说,请参阅图9A,图9A是用户界面202的示意图;请参阅图9B,图9B为用户界面104在如图5D所示的情况下的示意图;图9A中的用户界面202包括特征点A1、A2和A3;图9B中用户界面104是第一电子设备层叠显示第二图像1041和第一位置指示标记1042的示意图;第二图像1041中包括特征点A1'、A2'和A3';其中,特征点A1和特征点A1'为一组匹配的特征点,特征点A2和特征点A2'为一组匹配的特征点,A3和特征点A3'为一组匹配的特征点;第一位置指示标记1042在第二图像1041中的位置可以用位置点A4'表示,即第一位置指示标记1042和第二图像1041的相对位置可以用位置点A4'和特征点A1'、A2'和A3'的相对位置确定;第二电子设备200在得到位置点A4'和特征点A1'、A2'和A3'的相对位置的情况下,如图9C所示,确定出用户界面202中的位置点A4;位置点A4和特征点A1、A2和A3的相对位置,和,位置点A4'和特征点A1'、A2'和A3'的相对位置相同;位置点A4即表示第一位置。
其中,由于第二图像1041在第一电子设备100和第二电子设备200中是同一张图像,数据格式相同,因此第二图像1041中的任意一个像素在第一电子设备100中的位置坐标和在第二电子设备200中的位置坐标相同。本申请实施例中,第二电子设备200在接收到第一电子设备100发送的第二图像1041时,第二电子设备100可以将第二图像1041置于第一坐标系 中,进而可以确定出第二图像1041中任意一点的位置坐标。因此本申请实施例中,第二电子设备200可以确定出第二图像1041中特征点A1'、A2'和A3'的位置坐标,由于第一数据包中包含第一位置指示标记1042的位置坐标,因此,A1'、A2'、A3'和A4'的位置坐标均为已知的。在第一坐标系下,用户界面202中的A1、A2和A3是已知的。请参阅图9D,第一坐标系下:A1'的位置坐标为(Xa1',Ya1')、A2'的位置坐标(Xa2',Ya2')、A4'的位置坐标(Xa4',Ya4');请参阅图9E,在第一坐标系下:A1的位置坐标为(Xa1,Ya1)、A2的位置坐标(Xa2,Ya2),若假设用户界面202中的第一位置为A4,A4的位置坐标为(Xa4,Ya4);参阅图9D和图9E,可见A1'、A2'和A4'构成的三角形和A1、A2和A4构成的三角形相似,则有以下(1)(2)等式:
(1)(Xa4-Xa1)/(Xa4'-Xa1')=(Ya4-Ya1)/(Ya4'-Ya1')
(2)(Xa4-Xa2)/(Xa4'-Xa2')=(Ya4-Ya2)/(Ya4'-Ya2')
将等式(1)(2)转换,可得到等式(3)(4)。
(3)(Xa4-Xa1)*(Ya4'-Ya1')=(Xa4'-Xa1')*(Ya4-Ya1)
(4)(Xa4-Xa2)*(Ya4'-Ya2')=(Xa4'-Xa2')*(Ya4-Ya2)
由于两组等式且未知数仅包括Xa4,Ya4,因此可以解得Xa4和Ya4,因此,可以确定出第一位置A4的位置坐标(Xa4,Ya4)。
S14:第二电子设备200将数据信息插入到第一位置。
具体的,第二电子设备200首先根据第一位置确定出应用程序201;之后,第二电子设备调用应用程序编程接口(Application Programming Interface,API)将数据信息插入到应用程序201的用户界面中。需要说明的是,如步骤S106中的说明,在第一电子设备100安装有应用程序C1,第二电子设备200安装有应用程序C2的情况下,步骤S11至步骤S14可以由应用程序C2调用应用程序编程接口执行。
下面实施例介绍本申请实施例提供的另一种数据传输方法。该方法应用于通信系统,通信系统包括第一电子设备100和第二电子设备200,第一电子设备100和第二电子设备200通信连接,第一电子设备100设置有摄像头。如图10所示,该方法可以包括:
S201,第一电子设备100显示第一图像101。
其中,第一图像101的相关解释说明可以参阅步骤S101,此处不再赘述。举例来说,第一电子设备100显示第一图像101可以参阅图2B或图2C。
具体的,如图2B所示,第一电子设备100通过摄像头针对图2A所示的场景进行实时拍摄,得到第一图像101,并在显示屏上显示第一图像101;可以理解的是,在第一图像101中的图像是第一电子设备100通过摄像头实时获取到的情况下,第一图像101是第一电子设备100上显示的预览画面,即在用户移动第一电子设备100时,第一图像101随着第一电子设备100的移动而变化。请参阅图2B,在第一图像101是第一电子设备100通过摄像头获取到的图像的情况下,第一电子设备100在显示屏上显示第一图像101的同时还显示第二位置指示标记105,第二位置指示标记105在第一电子设备100的显示屏上的显示位置和形状是预设置的,例如,图2B中,第二位置指示标记105所在的位置处于显示屏的中心,且第二位置指示标记105的形状为十字形状。
在一些实施例中,如图2C所示,第一图像101可以是存储在第一电子设备100中的图像,用户可以在第一电子设备100上打开第一图像101。
S202,第一电子设备100检测到第一用户输入。
其中,第一用户输入的解释说明可以参阅步骤S102,此处不再赘述。举例来说,第一电子设备100检测到第一用户输入可以如图3所示。
S203,第一电子设备100响应于第一用户输入,第一电子设备100通过摄像头实时获取得到第二图像1041;第一电子设备100层叠显示第二图像1041和第一位置指示标记1042,得到用户界面104;,且第一位置指示标记1042位于顶层;第二图像1041中包括第二电子设备200的用户界面。
其中,第一位置指示标记1042为第一电子设备预设置的符号标记,例如图5B所示第一位置指示标记1042可以是十字形状的标记符号。需要说明的是,第一位置指示标记1042在用户界面104中的位置可以是预设置的,例如,参阅图5B,第一位置指示标记1042可以位于用户界面104的中心。
在一些实施例中,步骤S203之后还可以包括步骤S2031:
在一些实施例中,执行步骤S203之后,第二图像1041中包括第二电子设备200的用户界面202,且第一位置指示标记1042在用户界面202中的位置是用户想要将数据信息插入到用户界面202中的位置;则执行步骤S204。若步骤S203之后,第二图像1041中不包括用户界面202,或者,第二图像1041中包括用户界面202,但在第一用户界面104中,第一位置指示标记1042不在用户界面202中,或者,第一位置指示标记1042在用户界面202中的位置不是用户想要将数据信息插入到用户界面202中的位置,则执行首先执行步骤S2031,之后再执行步骤S204。
S2031,第一电子设备100检测到第三用户输入,响应于第三用户输入,第一电子设备100调整第二图像104中的显示内容,调整后的第二图像1041中包括用户界面202,且第一位置指示标记1042在用户界面202中的位置为用户想要将数据信息插入到用户界面202中的位置。需要说明的是,第二图像1041中包括第二电子设备200的部分或全部的用户界面。
举例来说,请参阅图5A,图5A是本申请实施例提供的第二电子设备200的示意图。图5A中包括:电子设备200,应用程序201和应用程序201中的标题栏2011。请参阅图5B,图5B中第一位置指示标记1042为预设置的标记符号。用户可以移动第一电子设备100,使得第一电子设备100通过摄像头拍摄得到的第二图像1041中包括第二电子设备200的用户界面;具体的,在第一位置指示标记1042如图5B所示的情况下,第一电子设备100显示用户界面104的示意图如图5C所示。图5C中,第一位置指示标记1042位于标题栏2011中。
S204,第一电子设备100检测到第二用户输入。
在一些实施例中,第二用户输入可以是包括一种或多种类型的输入,例如第二用户输入可以是:语音输入,触控操作,按压操作等。
在一些实施例中,第一用户输入为用户长按第一电子设备100的显示屏,第二用户输入为第一电子设备100检测到用户结束对于第一电子设备100的显示屏执行触控操作;举例来说,在步骤S202,如图3所示,第一用户输入为用户触控电子设备100的显示屏;之后,第一电子设备100在执行步骤S202~步骤S203的过程中,用户保持对于电子设备100的显示屏的触控操作;在步骤S204中,如图6A所示,用户结束对于第一电子设备100的触控操作,即为本示例中的第二用户输入。
S205,响应于第二用户输入,第一电子设备100向第二电子设备200发送第一数据包,第一数据包中包括第一图像101、第二图像1041、第一位置指示标记1042的位置信息。
需要说明的是,由于第一图像101中携带有数据信息,因此,在本申请实施例中,第一数据包中包括数据信息的具体表现形式可以是第一数据包中包括第一图像101。
具体的,第一电子设备100如何向第二电子设备200发送第一数据包的解释说明可以参阅步骤S106的解释说明。
需要说明的是,在步骤S201中的解释说明中说明了第一图像101可以是第一电子设备100通过摄像头实时获取的预览画面,也可以是存储在第一电子设备100中的图像;在第一图像101是第一电子设备100通过摄像头实时获取的预览画面的情况下,第一数据包中还包括第二位置指示标记105的位置信息。
S206,第二电子设备200针对第一图像101进行图像处理,得到第一图像101中的数据信息。
其中,第二电子设备200针对第一图像101进行图像处理,得到第一图像101中的数据信息与步骤S103中第一电子设备100针对第一图像101进行图像处理,得到第一图像101中的数据信息的过程相同,因此,可以参阅对于步骤S103的解释说明,此处不再赘述。具体的,可以包括S2061,S2062和S2063。在第一图像101是第一电子设备100通过摄像头实时获取的预览画面的情况下,第二电子设备200执行步骤S2061;在第一图像101是存储在第一电子设备100中的图像的情况下,第二电子设备200执行步骤S2062或2063。
S2061,第二电子设备200确定出第二位置指示标记105所在的信息区域103,针对第一图像101进行图像处理,得到信息区域103中的数据信息。
S2062,第二电子设备200确定出包含数据信息的信息区域,若包含数据信息的信息区域的数量为一个,则确定该信息区域为信息区域103,针对第一图像101进行图像处理,得到信息区域103中的数据信息。
S2063,第二电子设备200确定出包含数据信息的信息区域,若包含数据信息的信息区域的数量为多个,则显示多个信息区域;之后,检测到用户对于多个信息区域中的一个信息区域的选择指令;根据选择指令确定出多个信息区域中的信息区域103;针对第一图像101进行图像处理,得到信息区域103中的数据信息。
S207,第二电子设备200根据第一位置指示标记1042的位置信息将第一图像101中的数据信息插入到应用程序201的用户界面中。
其中,第二电子设备200更新应用程序201的用户界面的具体解释说明可以参阅步骤S107,具体可以包括步骤:S11~S14;此处不再赘述。
图11示出了电子设备100的结构示意图,需要说明的是本申请实施例中电子设备200可以与电子设备100具有相同的结构。
电子设备100可以是手机、平板电脑、桌面型计算机、膝上型计算机、手持计算机、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本,以及蜂窝电话、个人数字助理(personal digital assistant,PDA)、增强现实(augmented reality,AR)设备、虚拟现实(virtual reality,VR)设备、人工智能(artificial intelligence,AI)设备、可穿戴式设备、车载设备、智能家居设备和/或智慧城市设备,本申请实施例对该电子设备的具体类型不作特殊限制。
电子设备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为电子设备供电。
电子设备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的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。
内部存储器121可以包括一个或多个随机存取存储器(random access memory,RAM)和一个或多个非易失性存储器(non-volatile memory,NVM)。
随机存取存储器可以包括静态随机存储器(static random-access memory,SRAM)、动态随机存储器(dynamic random access memory,DRAM)、同步动态随机存储器(synchronous dynamic random access memory,SDRAM)、双倍速率同步动态随机存取存储器(double data rate synchronous dynamic random access memory,DDR SDRAM,例如第五代DDR SDRAM一般称为DDR5SDRAM)等;
非易失性存储器可以包括磁盘存储器件、快闪存储器(flash memory)。
快闪存储器按照运作原理划分可以包括NOR FLASH、NAND FLASH、3D NAND FLASH等,按照存储单元电位阶数划分可以包括单阶存储单元(single-level cell,SLC)、多阶存储单元(multi-level cell,MLC)、三阶储存单元(triple-level cell,TLC)、四阶储存单元(quad-level cell,QLC)等,按照存储规范划分可以包括通用闪存存储(英文:universal flash storage,UFS)、嵌入式多媒体存储卡(embedded multi media Card,eMMC)等。
随机存取存储器可以由处理器110直接进行读写,可以用于存储操作系统或其他正在运行中的程序的可执行程序(例如机器指令),还可以用于存储用户及应用程序的数据等。
非易失性存储器也可以存储可执行程序和存储用户及应用程序的数据等,可以提前加载到随机存取存储器中,用于处理器110直接进行读写。
外部存储器接口120可以用于连接外部的非易失性存储器,实现扩展电子设备100的存储能力。外部的非易失性存储器通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部的非易失性存储器中。
电子设备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)标准接口。
压力传感器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的用户设置以及功能控制有关的键信号输入。
马达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系统为例,示例性说明电子设备100的软件结构。
图12是本申请实施例的电子设备100的软件结构框图。
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。
应用程序层可以包括一系列应用程序包。
如图12所示,应用程序层可以包括相机,图库,日历,通话,地图,导航,WLAN,蓝牙,音乐,视频,短信息等应用程序。
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。
如图12所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。
窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。
电话管理器用于提供电子设备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绘图的绘图引擎。
内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。
下面结合捕获拍照场景,示例性说明电子设备100软件以及硬件的工作流程。
当触摸传感器180K接收到触摸操作,相应的硬件中断被发给内核层。内核层将触摸操作加工成原始输入事件(包括触摸坐标,触摸操作的时间戳等信息)。原始输入事件被存储在内核层。应用程序框架层从内核层获取原始输入事件,识别该输入事件所对应的控件。以该触摸操作是触摸单击操作,该单击操作所对应的控件为相机应用图标的控件为例,相机应用调用应用框架层的接口,启动相机应用,进而通过调用内核层启动摄像头驱动,通过摄像头193捕获静态图像或视频。
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请实施例各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:快闪存储器、移动硬盘、只读存储器、随机存取存储器、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (17)

  1. 一种数据传输方法,其特征在于,应用于通信系统,所述通信系统包括第一电子设备和第二电子设备,所述第一电子设备和所述第二电子设备通信连接;所述第一电子设备安装有摄像头;所述方法包括:
    所述第一电子设备显示第一图像,所述第一图像中包括数据信息;
    所述第一电子设备检测到第一用户输入;
    响应于所述第一用户输入,所述第一电子设备显示第一用户界面,所述第一用户界面中包括第一位置指示标记和通过所述摄像头获取到的第二图像;
    在所述第二图像中包括第二用户界面,且所述第一位置指示标记位于所述第二用户界面中的位置为第一位置时,所述第一电子设备检测到第二用户输入,所述第二用户界面是指所述第二电子设备显示的用户界面;
    响应于所述第二用户输入,所述第一电子设备向所述第二电子设备发送第一数据包,所述第一数据包中包括所述第二图像,所述数据信息和所述第一位置指示标记的位置信息;
    所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处。
  2. 根据权利要求1所述的方法,其特征在于,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处,包括:
    所述第二电子设备确定所述第二用户界面和所述第二图像中的匹配特征点;
    所述第二电子设备根据所述匹配特征点和所述第一位置指示标记的位置信息,确定出所述第二用户界面中的第一位置;
    所述第二电子设备将所述数据信息插入到所述第一位置处。
  3. 根据权利要求2所述的方法,其特征在于,所述第一电子设备检测到所述第二用户输入的时间点为第一时间点;所述第一位置指示标记的位置信息表示在所述第一时间点时所述第一位置指示标记在第一坐标系中的位置坐标。
  4. 根据权利要求1-3任一项所述的方法,其特征在于,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到所述第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:
    所述第一电子设备根据所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一信息区域中的所述数据信息。
  5. 根据权利要求1-3任一项所述的方法,其特征在于,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:
    若所述第一图像中包含的信息区域的数量为一,则所述第一电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
  6. 根据权利要求1-3任一项所述的方法,其特征在于,所述检测到第一用户输入之后,所述第一电子设备向所述第二电子设备发送第一数据包之前,所述方法还包括:
    若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第一电子设备显示两个或两个以上的所述信息区域;
    所述第一电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;
    所述第一电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所述第一信息区域;
    所述第一电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
  7. 根据权利要求4-6任一项所述的方法,其特征在于,所述第一数据包中包括的所述数据信息具体指的是针对所述第一图像进行图像处理后得到的数据信息。
  8. 根据权利要求1-3任一项所述的方法,其特征在于,所述第一数据包中包括的所述数据信息由所述第一图像携带,所述第一数据包中包括所述第一图像。
  9. 根据权利要求8所述的方法,其特征在于,所述第一图像是通过所述摄像头实时获取得到的;所述第一电子设备在显示所述第一图像的同时,还显示第二位置指示标记,所述第一电子设备在检测到所述第一用户输入时,所述第二位置指示标记位于所述第一图像中的第一信息区域中;所述第一数据包中还包括所述第二位置指示标记,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:
    所述第二电子设备根据所述第二位置指示标记针对所述第一图像进行图像处理,确定出所述第一信息区域,并得到所述第一信息区域中的所述数据信息。
  10. 根据权利要求8所述的方法,其特征在于,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:
    若所述第一图像中包含的信息区域的数量为一,则所述第二电子设备确定所述第一图像中包含的一个信息区域为第一信息区域,所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
  11. 根据权利要求8所述的方法,其特征在于,所述第一电子设备向所述第二电子设备发送第一数据包之后,所述第二电子设备根据所述第一数据包将所述数据信息插入到所述第二用户界面中的所述第一位置处之前,所述方法还包括:
    若所述第一图像中包含的信息区域的数量为两个或两个以上,则所述第二电子设备显示两个或两个以上的所述信息区域;
    所述第二电子设备检测到对于两个或两个以上的所述信息区域中的第一信息区域的选择指令;
    所述第二电子设备根据所述选择指令确定出所述两个或两个以上的所述信息区域中的所 述第一信息区域;
    所述第二电子设备针对所述第一图像进行图像处理,得到所述第一信息区域中的所述数据信息。
  12. 根据权利要求1-3任一项所述的方法,其特征在于,所述第一位置指示标记是所述第一图像中包括所述数据信息的第一信息区域。
  13. 根据权利要求1-3任一项所述的方法,其特征在于,所述第一位置指示标记是预设置的标记符号。
  14. 根据权利要求1-13任一项所述的方法,其特征在于,所述第一用户输入为针对所述第一电子设备的触控操作;所述第二用户输入为结束针对所述第一电子设备的所述触控操作。
  15. 一种电子设备,其特征在于,所述电子设备包括:一个或多个处理器和存储器;所述存储器与所述一个或多个处理器耦合,所述存储器用于存储计算机程序代码,所述计算机程序代码包括计算机指令,所述一个或多个处理器调用所述计算机指令以使得所述电子设备执行如权利要求1-14中任一项所述的方法。
  16. 一种包含指令的计算机程序产品,其特征在于,当所述计算机程序产品在电子设备上运行时,使得所述电子设备执行如权利要求1-14中任一项所述的方法。
  17. 一种计算机可读存储介质,包括指令,其特征在于,当所述指令在电子设备上运行时,使得所述电子设备执行如权利要求1-14中任一项所述的方法。
PCT/CN2022/071620 2021-02-08 2022-01-12 数据传输方法及电子设备 WO2022166550A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110182682.2A CN114942741B (zh) 2021-02-08 2021-02-08 数据传输方法及电子设备
CN202110182682.2 2021-02-08

Publications (1)

Publication Number Publication Date
WO2022166550A1 true WO2022166550A1 (zh) 2022-08-11

Family

ID=82740839

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/071620 WO2022166550A1 (zh) 2021-02-08 2022-01-12 数据传输方法及电子设备

Country Status (2)

Country Link
CN (1) CN114942741B (zh)
WO (1) WO2022166550A1 (zh)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1804858A (zh) * 2005-01-10 2006-07-19 赵国成 一种用于带摄像装置的移动终端上实现ocr功能的新型辅助定位技术
JP2008099179A (ja) * 2006-10-16 2008-04-24 Nec Corp リモコン装置およびリモコン信号パターンの変更方法
CN103491444A (zh) * 2012-06-14 2014-01-01 腾讯科技(深圳)有限公司 图像互动方法和系统以及对应的显示装置
CN105577888A (zh) * 2014-10-10 2016-05-11 广州杰赛科技股份有限公司 一种手机与电脑非接触的数据交互方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1804858A (zh) * 2005-01-10 2006-07-19 赵国成 一种用于带摄像装置的移动终端上实现ocr功能的新型辅助定位技术
JP2008099179A (ja) * 2006-10-16 2008-04-24 Nec Corp リモコン装置およびリモコン信号パターンの変更方法
CN103491444A (zh) * 2012-06-14 2014-01-01 腾讯科技(深圳)有限公司 图像互动方法和系统以及对应的显示装置
CN105577888A (zh) * 2014-10-10 2016-05-11 广州杰赛科技股份有限公司 一种手机与电脑非接触的数据交互方法

Also Published As

Publication number Publication date
CN114942741B (zh) 2023-08-22
CN114942741A (zh) 2022-08-26

Similar Documents

Publication Publication Date Title
CN113704014B (zh) 日志获取系统、方法、电子设备及存储介质
WO2020259452A1 (zh) 一种移动终端的全屏显示方法及设备
WO2021213164A1 (zh) 应用界面交互方法、电子设备和计算机可读存储介质
WO2022127787A1 (zh) 一种图像显示的方法及电子设备
CN111666119A (zh) Ui组件显示的方法及电子设备
WO2021013132A1 (zh) 输入方法及电子设备
WO2021082815A1 (zh) 一种显示要素的显示方法和电子设备
WO2021218429A1 (zh) 应用窗口的管理方法、终端设备及计算机可读存储介质
WO2022095744A1 (zh) Vr显示控制方法、电子设备及计算机可读存储介质
CN114140365A (zh) 基于事件帧的特征点匹配方法及电子设备
WO2022105702A1 (zh) 保存图像的方法及电子设备
WO2023179123A1 (zh) 蓝牙音频播放方法、电子设备及存储介质
CN116048831B (zh) 一种目标信号处理方法和电子设备
CN115022982B (zh) 多屏协同无感接入方法、电子设备及存储介质
WO2022095906A1 (zh) 一种按键映射方法、电子设备及系统
WO2022062902A1 (zh) 一种文件传输方法和电子设备
CN113380240B (zh) 语音交互方法和电子设备
CN113407300B (zh) 应用误杀评估方法及相关设备
WO2022033355A1 (zh) 一种邮件处理方法及电子设备
WO2022007757A1 (zh) 跨设备声纹注册方法、电子设备及存储介质
WO2021129453A1 (zh) 一种截屏方法及相关设备
WO2020233581A1 (zh) 一种测量高度的方法和电子设备
WO2022166550A1 (zh) 数据传输方法及电子设备
CN114003241A (zh) 应用程序的界面适配显示方法、系统、电子设备和介质
WO2022143891A1 (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: 22748829

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: 22748829

Country of ref document: EP

Kind code of ref document: A1