Disclosure of Invention
In view of the above situation, in order to overcome the disadvantages of the prior art, embodiments of the present invention provide a method and a system for sharing two-dimensional code information between a television terminal and a mobile terminal, which can effectively solve the problems in the prior art that a television two-dimensional code cannot be conveniently and quickly scanned and the two-dimensional code display timeliness, and improve the experience effect of a user in scanning the television two-dimensional code.
The embodiment of the invention adopts the following technical scheme:
a two-dimension code information sharing method between a television terminal and a mobile terminal comprises the following steps:
monitoring whether a two-dimensional code picture is displayed on a screen picture of the television terminal;
when the two-dimension code picture is displayed on the screen picture of the television terminal, acquiring the screen picture and extracting the two-dimension code picture from the screen picture; and
and sending the two-dimensional code picture to at least one mobile terminal establishing a connection relation with the television terminal.
Preferably, before the two-dimensional code picture is sent to a mobile terminal establishing a connection relationship with the television terminal, the method further includes:
sending wireless names corresponding to a plurality of mobile terminals to a specified mobile terminal through the television terminal; and
and receiving selection operation executed by a user, and feeding back the wireless name of at least one mobile terminal to the television terminal.
Preferably, the method further comprises:
analyzing the extracted two-dimensional code picture; and
and sending the analyzed information content to the mobile terminal.
Preferably, before the two-dimensional code picture is sent to a mobile terminal establishing a connection relationship with the television terminal, the method further includes:
storing the extracted two-dimensional code picture in a preset database;
receiving a first information instruction sent by the mobile terminal and displaying the two-dimensional code picture stored in the database on the screen of the television terminal according to the first information instruction; and
and receiving a second information instruction sent by the mobile terminal.
Preferably, the method further comprises:
extracting important information from the analyzed information content and displaying the important information under the two-dimensional code picture in the database.
A two-dimension code information sharing system between a television terminal and a mobile terminal comprises the television terminal and at least one mobile terminal, wherein the television terminal comprises:
the monitoring unit is used for monitoring whether a two-dimensional code picture is displayed on a screen picture of the television terminal;
the acquisition unit is used for acquiring the screen picture when the two-dimensional code picture is displayed on the screen picture of the television terminal;
the picture extraction unit is used for extracting the two-dimensional code picture from the screen picture; and
and the first sending unit is used for sending the two-dimensional code picture to at least one mobile terminal which establishes a connection relation with the television terminal.
Preferably, the television terminal further includes:
a second sending unit, configured to send wireless names corresponding to the plurality of mobile terminals to the specified mobile terminal;
the mobile terminal includes:
and the feedback unit is used for receiving selection operation executed by a user so as to feed back the wireless name of at least one mobile terminal to the television terminal.
Preferably, the television terminal further includes:
the analysis unit is used for analyzing the extracted two-dimensional code picture; and
and the third sending unit is used for sending the analyzed information content to the mobile terminal.
Preferably, the television terminal further includes:
the storage unit is used for storing the extracted two-dimensional code picture in a preset database;
a first receiving unit, configured to receive a first information instruction sent by the mobile terminal;
the first display unit is used for displaying the two-dimensional code pictures stored in the database on the screen picture of the television terminal by the first information instruction; and
and the second receiving unit is used for receiving a second information instruction sent by the mobile terminal.
Preferably, the television terminal further includes:
the information extraction unit is used for extracting important information from the analyzed information content; and
and the second display unit is used for displaying the important information under the two-dimensional code picture in the database.
The technical scheme provided by the embodiment of the invention has the following beneficial effects: by adopting the technical scheme of the invention, firstly, when a two-dimensional code picture is displayed on a screen of a television terminal, the screen is acquired and the two-dimensional code picture is extracted from the screen, and then the two-dimensional code picture is sent to at least one mobile terminal which establishes a connection relation with the television terminal, so that a user can directly scan the mobile terminal which receives the two-dimensional code picture through another mobile terminal, or the user can prompt the television terminal to send the two-dimensional code picture to the mobile terminal corresponding to a wireless signal selected by the user by executing selection operation on the appointed mobile terminal; secondly, the two-dimensional code can be analyzed through the television terminal and the analyzed information content can be sent to the mobile terminal, so that a user can directly check the information content corresponding to the two-dimensional code picture on the mobile terminal without executing scanning operation; thirdly, the two-dimension code picture displayed on the screen picture can be stored in a preset database, so that a user can call the conventional two-dimension code picture, and the problem of timeliness that the user cannot timely acquire the two-dimension code picture due to limited time for displaying the two-dimension code picture by a television is solved.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be obtained by a person skilled in the art without any inventive step based on the embodiments of the present invention, belong to the scope of the present invention.
In the following embodiments of the present invention, the mobile terminal includes, but is not limited to, a smart phone with a touch screen, a tablet computer, a netbook, a pda (portable Digital assistant), an intelligent wearable device, and the like.
Example one
Referring to fig. 1, fig. 1 is a flowchart illustrating a two-dimensional code information sharing method between a television terminal and a mobile terminal according to an embodiment of the present invention. Specifically, the embodiment provides a method for sharing two-dimensional code information between a television terminal and a mobile terminal, which includes the following steps:
step 101, monitoring whether a two-dimensional code picture is displayed on a screen picture of a television terminal;
when the two-dimension code picture is displayed on the screen picture of the television terminal, executing step 102, obtaining the screen picture and extracting the two-dimension code picture from the screen picture; and
and 103, sending the two-dimensional code picture to at least one mobile terminal establishing a connection relation with the television terminal.
In the specific implementation of step 101, the image data stream flowing into the main control CPU needs to be identified, that is, each static frame picture in the image data stream needs to be searched for a two-dimensional code picture.
It is known to those skilled in the art that the shape feature of a two-dimensional code generally includes three positioning points for determining the range of the two-dimensional code and ensuring that the two-dimensional code can be correctly recognized even if the two-dimensional code has a certain inclination. Therefore, in this embodiment, three anchor points are searched, so as to determine the existence of the two-dimensional code picture in the still frame picture. It should be noted that the position and the size of the two-dimensional code picture displayed in the still frame picture are not fixed, that is, the two-dimensional code picture can be displayed at any position and in any shape in the still frame picture, so that all areas in the still frame picture need to be searched in the searching process. The specific search method is as follows:
coordinate axes and three search boxes for covering three positioning points are established on the static frame picture, wherein the search boxes can be squares. The searching mode is that the screening is carried out from big to small in sequence. Specifically, the coordinates of the first search position of the three search frames are respectively given, wherein the coordinates of the first search position cover the static frame picture in the largest range. Then, controlling the three search frames to be respectively displayed at the coordinate positions corresponding to the three search frames, judging whether the three search frames are completely covered with positioning points or not, and if so, determining that a two-dimensional code picture exists on the current static frame picture; if not, the search continues. The mode of continuing searching is as follows: giving the coordinates of a second searching position, wherein the area covered by the coordinates of the second searching position is smaller than the area covered by the coordinates of the first searching position; similarly, the three search frames are controlled to be respectively displayed at the coordinate positions corresponding to the three search frames and judged, if the positioning points are not completely covered, the three search frames are simultaneously controlled to integrally move, because the coordinate coverage area of the second search position is slightly smaller than that of the previous search position, the static frame picture cannot be covered in the maximum range, the three search frames need to be simultaneously moved to cover the whole static frame picture, when the two-dimensional code picture is not judged to exist after the static frame picture is completely covered, the search is continued according to the second search mode, namely, the area covered by the coordinates of the search positions is continuously reduced until the minimum gap exists among the three search frames; and when the minimum gap exists among the three search frames and the whole static frame picture is covered by moving without completely covering the positioning points, the current static frame picture is considered to have no two-dimensional code picture, and thus the next static frame picture is subjected to two-dimensional code search.
Referring to fig. 2, fig. 2 is a schematic diagram illustrating an example of searching for an anchor point for the first time according to an embodiment of the present invention. As shown in the figure, it is assumed that the still frame picture in the present embodiment is square and has a side length of 10. Wherein the three search boxes are named S1, S2, and S3, respectively, wherein the coordinates of the search box S1 are given as (0, 10), (1, 9), (0, 9), i.e., the coordinates of the four vertices; coordinates given to the search box S2 are (9, 10), (10, 9), (9, 9); the coordinates of the search box S3 are given as (0, 1), (1, 0), (0, 0). After the three search frames are displayed at the given coordinate positions, the television terminal system judges whether the three search frames are completely covered with positioning points or not, and if the three search frames are completely covered, the two-dimensional code picture is determined to exist on the current static frame picture; if not, the second search is continued.
Referring to fig. 3, fig. 3 is a schematic diagram illustrating an example of searching for anchor points for the second time according to an embodiment of the present invention. As shown, keeping the coordinate position of the search box S1 unchanged, the coordinates given to the search box S2 are (8, 9), (9, 10), (9, 9), (8, 9); the coordinates of the search box S3 are given as (0, 2), (1, 1), (0, 1). That is, the search box S2 is shifted leftward by 1 length unit; the search box S3 is translated upward by 1 length unit, and after translation, the distances between the search boxes S1 and S2 and S1 and S3 are each shortened by 1 length unit; then, the television terminal system judges whether all the translated three search frames are covered by positioning points, and if all the three search frames are covered, the two-dimensional code picture is determined to exist on the current static frame picture; if not, the three search boxes are controlled to move integrally at the same time, and the specific moving mode is as follows: firstly controlling the three search frames to integrally translate by 1 length unit to the right, then judging, if the three search frames are judged not to be completely covered with the positioning points, then controlling the three search frames to integrally translate by 1 length unit to the lower part of the existing position, then judging, and if the three search frames are judged not to be completely covered with the positioning points, then controlling the three search frames to integrally translate by 1 length unit to the left part of the existing position.
It should be noted that, the above implementation process is only described in the first search and the second search, and in practical operation, if it is not determined at the second search that there is a two-dimensional code picture on the current still frame picture (i.e. all three search frames are covered with the positioning point), the search is continued, i.e. the search frames S2 and S3 are continued to be translated and judged, until the distance between the search frames S1 and S2 and S1 and S3 is the minimum gap, the translation is stopped, where the length of the minimum gap is not limited in this embodiment.
In step 102, the screen picture acquired by the television terminal system is a static frame picture on which the two-dimensional code picture is displayed, and the specific acquisition mode may be copying or capturing, and then the two-dimensional code picture is extracted from the acquired static frame picture.
The extraction method is preferably as follows: firstly, the coordinate position of the two-dimensional code picture in the static frame picture is judged, and then the area corresponding to the coordinate position is intercepted. For example, the coordinate positions of the two-dimensional code picture in the still frame picture are judged to be (0, 5), (2, 3), (0, 3); and intercepting the area corresponding to the coordinate position, wherein the intercepted picture is the two-dimensional code picture.
It should be noted that the searching method used in this embodiment can accurately determine whether there is a two-dimensional code picture on the still frame picture, and ensure that there is no unsearched area.
In step 103, the television terminal needs to establish a connection relationship with at least one mobile terminal, which may be a wireless connection, such as a bluetooth connection. And on the premise of establishing the connection relation, the television terminal sends the two-dimensional code picture extracted from the screen picture to the mobile terminal. After the two-dimension code picture is successfully sent, the mobile terminal receives the two-dimension code picture, and at the moment, a user can directly open the two-dimension code scanning function of another mobile terminal to scan the two-dimension code picture. Therefore, the phenomenon that a user needs to go to the front of the television to scan the two-dimensional code picture is avoided.
Further, in step 101 of this embodiment, if no two-dimensional code picture is displayed on the screen of the monitoring television terminal, the flow is directly ended.
Example two
Referring to fig. 4, fig. 4 is a flowchart illustrating a method for sending a wireless name between a television terminal and a mobile terminal according to a second embodiment of the present invention. Specifically, this embodiment is substantially the same as the first embodiment, except that in this embodiment, before sending the two-dimensional code picture to the mobile terminal that establishes a connection relationship with the television terminal, the method further includes:
step 201, sending wireless names corresponding to a plurality of mobile terminals to the appointed mobile terminals through the television terminal.
The wireless names corresponding to the plurality of mobile terminals may be connected with the television terminal in advance, and when the mobile terminals are successfully paired with the television terminal, the television terminal acquires and records the wireless names of the mobile terminals. For example, assuming that the wireless names corresponding to the plurality of mobile terminals recorded by the television terminal are a1, a2, and A3, respectively, in this step, the television terminal will send the wireless names a1, a2, and A3 to the designated mobile terminals, respectively.
Step 202, receiving a selection operation executed by a user, and feeding back a wireless name of at least one mobile terminal to the television terminal.
The user can select one or more of the received wireless names corresponding to the plurality of mobile terminals by operating the specified mobile terminals. For example, assuming that the wireless name selected by the user is a2, the specified mobile terminal will feed back the wireless name a2 to the television terminal.
Therefore, after the television terminal receives the wireless name sent by the appointed mobile terminal, the extracted two-dimensional code picture can be sent to the mobile terminal corresponding to the wireless name.
The effect achieved by the embodiment is as follows: the user can specify the object of the two-dimensional code picture to be sent by the television terminal by executing selection operation. For example, the television terminal can send the two-dimensional code picture to a mobile phone of a father of the user, so that the user can scan the two-dimensional code picture received by the mobile phone of the father by opening a two-dimensional code scanning function on the mobile phone of the user.
EXAMPLE III
Referring to fig. 5, fig. 5 is a flowchart illustrating a method for analyzing a picture between a television terminal and a mobile terminal according to a third embodiment of the present invention. Specifically, this embodiment is substantially the same as the first embodiment, except that in this embodiment, the method further includes:
step 301, analyzing the extracted two-dimensional code picture; and
and step 302, sending the analyzed information content to the mobile terminal.
If the analyzed information content is a website, sending the website to the mobile terminal and detecting the security of the website, and if the detection result is security, directly opening the website; if the analyzed information content is the content of characters, pictures, music and the like, the characters can be typed in a memorandum of the mobile terminal; storing pictures in an album of the mobile terminal; storing music in a music player of the mobile terminal, and so on.
Referring to fig. 6, fig. 6 is a flowchart illustrating a two-dimensional code information sharing method between a television terminal and a mobile terminal according to a third embodiment of the present invention. Specifically, in this embodiment, before sending the two-dimensional code picture to the mobile terminal that establishes a connection relationship with the television terminal, the method further includes:
and 303, storing the extracted two-dimension code picture in a preset database.
Step 304, receiving a first information instruction sent by the mobile terminal and displaying the two-dimensional code pictures stored in the database on the screen of the television terminal according to the first information instruction; and
step 305, receiving a second information instruction sent by the mobile terminal.
Since the display of the two-dimensional code on the television terminal is time-efficient, i.e. the display time is short, the present embodiment will solve this problem. In this embodiment, when the two-dimensional code picture is extracted from the screen image, the two-dimensional code picture is also stored in the database, so that a user can conveniently take out the two-dimensional code picture which is displayed on the television terminal in the past.
For example, a user can send the first information instruction to the television terminal through the mobile terminal, and when the television terminal receives the first information instruction, the database is controlled to be opened and displayed on the television terminal in real time, that is, all the past two-dimensional code pictures stored in the database can be displayed on the television terminal.
Therefore, the user can send the second information instruction to the television terminal, wherein the second information instruction specifically indicates the code number of the two-dimensional code picture selected by the user to the television terminal, namely the two-dimensional code pictures stored in the database all have one code number; and if the code number identified by the television terminal according to the second information instruction is 3, sending the two-dimensional code picture corresponding to the code number 3 to the mobile terminal. The second information instruction may include a code or a plurality of codes.
Further, in this embodiment, the method further includes:
and step 306, extracting important information from the analyzed information content and displaying the important information in the two-dimensional code picture in the database.
The important information may include a type to which the information content of the two-dimensional code picture belongs, and the type to which the information content of the two-dimensional code picture belongs includes advertisement, voting, bonus guessing, message leaving, and the like; alternatively, the important information may further include a television station, time, and the like corresponding to the two-dimensional code when the two-dimensional code is presented on the television terminal, or the important information may further include a validity period of the information content of the two-dimensional code, and the like, which will not be described in detail herein.
Therefore, when the database is opened, that is, the two-dimensional code pictures stored in the database are displayed on the television terminal, a user can determine whether to start the television terminal or not by observing important information corresponding to the two-dimensional code pictures.
The functions described in the method of the present embodiment, if implemented in the form of software functional units and sold or used as independent products, may be stored in a storage medium readable by a computing device. Based on such understanding, part of the contribution of the embodiments of the present invention to the prior art or part of the technical solution may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computing device (which may be a personal computer, a server, a mobile computing device, a network device, or the like) to execute all or part of the steps of the method described in the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
Example four
Referring to fig. 7, fig. 7 is a block diagram illustrating a two-dimensional code information sharing system between a television terminal and a mobile terminal according to a fourth embodiment of the present invention. Specifically, the present embodiment provides a two-dimensional code information sharing system 4 between a television terminal and a mobile terminal, including a television terminal 40 and at least one mobile terminal 41, where the television terminal includes:
a monitoring unit 401, configured to monitor whether a two-dimensional code picture is displayed on a screen of the television terminal 40;
an obtaining unit 402, configured to obtain the screen picture when it is monitored that the two-dimensional code picture is displayed on the screen picture of the television terminal 40;
a picture extracting unit 403, configured to extract the two-dimensional code picture from the screen picture; and
a first sending unit 404, configured to send the two-dimensional code picture to at least one mobile terminal 41 that establishes a connection relationship with the television terminal 40.
As a practical manner, in this embodiment, the television terminal 40 further includes:
a second transmitting unit 405 configured to transmit wireless names corresponding to the plurality of mobile terminals to the specified mobile terminal 41;
the mobile terminal 41 includes:
a feedback unit 406, configured to receive a selection operation performed by a user to feed back a wireless name of at least one mobile terminal to the television terminal.
As a practical manner, in this embodiment, the television terminal 40 further includes:
an analyzing unit 407, configured to analyze the extracted two-dimensional code picture; and
a third sending unit 408, configured to send the parsed information content to the mobile terminal 41.
As a practical manner, in this embodiment, the television terminal 40 further includes:
a storage unit 409, configured to store the extracted two-dimensional code image in a preset database;
a first receiving unit 410, configured to receive a first information instruction sent by the mobile terminal 41;
a first display unit 411, configured to display the two-dimensional code pictures stored in the database on the screen of the television terminal 40 by the first information instruction; and
a second receiving unit 412, configured to receive a second information instruction sent by the mobile terminal 41.
As a practical manner, in this embodiment, the television terminal 40 further includes:
an information extraction unit 413 for extracting important information from the analyzed information content; and
a second display unit 414, configured to display the important information under the two-dimensional code picture in the database.
It should be understood that, in the fourth embodiment, the specific implementation process of each unit described above may correspond to the description of the above method embodiments (embodiments one to three), and is not described in detail here.
In the system provided by the fourth embodiment, the television terminal is exemplified by only dividing the functional units, and in practical applications, the above-mentioned function may be distributed by different functional units according to needs, that is, the internal structure of the television terminal is divided into different functional units to complete all or part of the functions described above. In addition, the system and method embodiments provided by the above embodiments belong to the same concept, and specific implementation processes thereof are detailed in the method embodiments and will not be described herein again. The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
The invention can realize the following advantages:
according to the invention, firstly, when a two-dimensional code picture is displayed on a screen picture of a television terminal, the screen picture is acquired and the two-dimensional code picture is extracted from the screen picture, and then the two-dimensional code picture is sent to at least one mobile terminal which establishes a connection relation with the television terminal, so that a user can directly scan the mobile terminal which receives the two-dimensional code picture through another mobile terminal, or the user can prompt the television terminal to send the two-dimensional code picture to the mobile terminal corresponding to a wireless signal selected by the user by performing selection operation on a specified mobile terminal; secondly, the two-dimensional code can be analyzed through the television terminal and the analyzed information content can be sent to the mobile terminal, so that a user can directly check the information content corresponding to the two-dimensional code picture on the mobile terminal without executing scanning operation; thirdly, the two-dimension code picture displayed on the screen picture can be stored in a preset database, so that a user can call the conventional two-dimension code picture, and the problem of timeliness that the user cannot timely acquire the two-dimension code picture due to limited time for displaying the two-dimension code picture by a television is solved.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and the present invention shall be covered thereby. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.