CN105263134A - Image transmission method and mobile equipment - Google Patents

Image transmission method and mobile equipment Download PDF

Info

Publication number
CN105263134A
CN105263134A CN201510650308.5A CN201510650308A CN105263134A CN 105263134 A CN105263134 A CN 105263134A CN 201510650308 A CN201510650308 A CN 201510650308A CN 105263134 A CN105263134 A CN 105263134A
Authority
CN
China
Prior art keywords
image
mobile device
configuration information
address
preview
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN201510650308.5A
Other languages
Chinese (zh)
Inventor
秦万麟
李伟
卢宗敏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huizhou TCL Mobile Communication Co Ltd
Original Assignee
Huizhou TCL Mobile Communication Co Ltd
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 Huizhou TCL Mobile Communication Co Ltd filed Critical Huizhou TCL Mobile Communication Co Ltd
Priority to CN201510650308.5A priority Critical patent/CN105263134A/en
Publication of CN105263134A publication Critical patent/CN105263134A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/22Processing or transfer of terminal data, e.g. status or physical capabilities
    • H04W8/24Transfer of terminal data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Databases & Information Systems (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses an image transmission method and mobile equipment. The method comprises the steps that first mobile equipment acts as a server to carry out IP address configuration; an access request sent by second mobile equipment which acts as a client, and communication connection with the second mobile equipment is established through a static IP address; configuration information of a preview image is sent to the second mobile equipment; and an image captured by using a camera is sent to the second mobile equipment, and the second mobile equipment is enabled to display the image according to the configuration information of the preview image. Image sharing and preview image storage can be carried out in real time between the mobile equipment by using the image transmission method disclosed by the invention.

Description

A kind of image transfer method and mobile device
Technical field
The present invention relates to mobile communication technology field, particularly relate to a kind of image transfer method and mobile device.
Background technology
Along with the development of Internet technology especially development of Mobile Internet technology, the activity such as user can use the mode connecting Internets such as 2G, 3G, 4G or wifi to carry out transfer of data by mobile device, share.Further, along with the hardware configuration of mobile device is more and more higher, the ability of other device request of concurrent processing multiple stage has been possessed.
Summary of the invention
The technical problem that the present invention mainly solves is to provide a kind of image transfer method and mobile device, can by preview to image be sent to other mobile devices of mutually communication connection in real time, be convenient to images share.
For solving the problems of the technologies described above, the technical scheme that the present invention adopts is: a kind of image transfer method, and be applied between mobile device and carry out image transmitting, described method comprises: the first mobile device carries out IP address configuration as server; Receive the access request of the second mobile device transmission as client, established a communications link by described static ip address and described second mobile device; Send the configuration information of preview image to described second mobile device; And the image utilizing camera to catch is sent to described second mobile device, make described second mobile device show described image according to the configuration information of described preview image.
For solving the problems of the technologies described above, another technical solution used in the present invention is: a kind of image transfer method, be applied between mobile device and carry out image transmitting, described method comprises: the second mobile device sends access request, to establish a communications link with described first mobile device as client to the first mobile device as server; Receive the configuration information of the preview image that described first mobile device sends; And resolve the image that described first mobile device sends, and according to the configuration information drawing image of described preview image.
For solving the problems of the technologies described above, another technical solution used in the present invention is: a kind of mobile device, comprising: configuration module, for configuration of IP address; Communication module, for receiving the access request of the second mobile device transmission as client, is established a communications link by described static ip address and described second mobile device; And send the configuration information of preview image to described second mobile device; And image processing module, for utilizing camera to catch image, and control described communication module described image is sent to described second mobile device, make described second mobile device show described image according to the configuration information of described preview image.
For solving the problems of the technologies described above, another technical solution used in the present invention is: a kind of mobile device, comprising: communication module, for sending access request, to establish a communications link with described first mobile device to the first mobile device as server; And receive the configuration information of the preview image that described first mobile device sends; And image processing module, resolve for the image sent described first mobile device, and according to the configuration information drawing image of described preview image.
The invention has the beneficial effects as follows: a kind of image transfer method provided by the invention and mobile device, first mobile device as server by camera preview to Image Real-time Transmission to other second mobile devices connecting this server, to carry out images share in real time.Further, other the second equipment can be taken pictures to the image of preview in this locality, video recording etc., preserves the image that the first mobile device as server is caught in real time.
Accompanying drawing explanation
Fig. 1 is the flow chart of a kind of image transfer method in first embodiment of the invention;
Fig. 2 is the modular structure schematic diagram that the first mobile device in embodiment of the present invention and the second mobile device carry out image transmitting;
Fig. 3 is the principle schematic that the first mobile device in embodiment of the present invention and the second mobile device carry out image transmitting;
Fig. 4 is the flow chart of a kind of image transfer method in second embodiment of the invention;
Fig. 5 is the flow chart of a kind of image transfer method in third embodiment of the invention;
Fig. 6 is the structural representation of a kind of mobile device in first embodiment of the invention;
Fig. 7 is the structural representation of a kind of mobile device in second embodiment of the invention;
Fig. 8 is the structural representation of a kind of mobile device in third embodiment of the invention.
Embodiment
First explanation is explained to prior art noun relevant in embodiment of the present invention.
Refer to Fig. 1, be the flow chart of a kind of image transfer method in first embodiment of the invention, the image transfer method shown in this execution mode is applied to the first mobile device as server, comprising:
Step S10, the first mobile device carries out IP address configuration as server.
Particularly, dynamic IP addressing is configured to static ip address by the media access control address MAC binding of route by the first mobile device.
Further, the MAC of the first mobile device binding local area network (LAN) route, is configured to static ip address by dynamic IP addressing.
In step slo, in advance dynamic IP addressing being configured to static ip address, in order to ensure the address of the first mobile device as server and the stability of port, like this, in image transmitting process, just can ensureing that IP address can not change.
Step S11, is received the access request of the second mobile device transmission as client, is established a communications link by static ip address and the second mobile device.
After network ip address has configured, the second mobile device as client has initiated access request by ICP/IP protocol, establishes a communications link with the first mobile device.
In the present embodiment, the first mobile device and the second mobile device can be the equipment of identical type, e.g., and smart mobile phone; Also can be dissimilar equipment, e.g., a side be smart mobile phone, and the opposing party is panel computer.
Further, first mobile device can be established a communications link by ICP/IP protocol and at least one the second mobile device, and, as mentioned above, the static ip address that what the first mobile device was pre-configured is in local area network (LAN), therefore, the communication connection between the first mobile device and the second mobile device is that local area network (LAN) connects.
Step S12, sends configuration information to the second mobile device of preview image.
Wherein, the configuration information of this preview image comprises the size of preview image, width and height.In advance this configuration information is transferred to the second mobile device, enable the second mobile device read whole image once according to this configuration information, improve performance and display efficiency.
Step S13, the image of catching utilizing camera is sent to the second mobile device, makes the second mobile device according to the configuration information display image of preview image.
Particularly, the image that the first mobile device utilizes camera to catch, carries out binary coding to the image of catching, and to be sent to the second mobile device, makes the second mobile device according to the configuration information display image of preview image.
In step s 13, the first mobile device carries out binary coding by needing each two field picture of preview, and to guarantee to be transmitted by ICP/IP protocol, and the binary image encoder being sent to the second mobile device is yuv format.
Please refer to Fig. 2 and Fig. 3, be the smart mobile phone of android operating system for the first mobile device and the second mobile device, image transfer method as above is described.
During the preparatory stage, the first mobile device needs the MAC of the router of local area network (LAN) to be bound into staticip address by " Peanut " account.After having configured, the second mobile device in local area network (LAN) initiates TCP/IP request, establishes a communications link with the first mobile device.Then, the first mobile device converts the getpreviewsize of acquisition to JansonObject, sends to the second mobile device, and to realize the transmission of the configuration information of preview image, the second mobile device goes out concrete previewszie according to protocol analysis.First server performs camerapreview (unlatching preview), catches every frame binary system picture stream and sends to the second mobile device.Second mobile device performs GetYUVStream, and by internal conversion getRGBstream, performs cache with this stream of buffer memory simultaneously, then perform drawcachestream constantly, to show the preview image that the first mobile device captures in real time.
Above scheme, the first mobile device as server by camera preview to Image Real-time Transmission to other second mobile devices connecting this server, to carry out images share in real time.Can be applicable to the scenes such as video monitoring, visual telephone, video conference.
Refer to Fig. 4, be the flow chart of a kind of image transfer method in second embodiment of the invention, the image transfer method shown in this execution mode is applied to the second mobile device as client, comprising:
Step S20, the second mobile device sends access request, to establish a communications link with the first mobile device as client to the first mobile device as server.
Wherein, after the first mobile device configuration network IP address completes, the second mobile device as client initiates access request by ICP/IP protocol, establishes a communications link with the first mobile device.
In the present embodiment, the first mobile device and the second mobile device can be the equipment of identical type, e.g., and smart mobile phone; Also can be dissimilar equipment, e.g., a side be smart mobile phone, and the opposing party is panel computer.
Step S21, receives the configuration information of the preview image that the first mobile device sends.
Wherein, the configuration information of this preview image comprises the size of preview image, width and height.This second mobile device, after acquisition configuration information, resolves to obtain the size of image, width and elevation information to this configuration information.
Step S22, resolves the image that the first mobile device sends, and according to the configuration information drawing image of preview image.
Particularly, the binary picture of the second mobile device to the yuv format that the first mobile device sends is decoded, and converts yuv format to rgb format, and according to the configuration information drawing image of preview image.
Refer to Fig. 5, be the flow chart of a kind of image transfer method in third embodiment of the invention, the image transfer method shown in this execution mode, relative to the image transfer method shown in Fig. 4, also comprises the steps:
Step S33, the first image control instruction of response user input, to catch the image of current drafting.
Further, send the second image control instruction to the first mobile device, make the first mobile device resolve the second image control instruction to process accordingly current image of catching.
First image control instruction as above and the second image control instruction are for taking pictures or record a video instruction.First mobile device and the second mobile device all can respond corresponding image control instruction, perform corresponding process, e.g., take pictures to the image of current drafting, and by the Image Saving of acquisition in this locality.
Please again consult Fig. 2 and Fig. 3 simultaneously, be still the smart mobile phone of android operating system for the first mobile device and the second mobile device, image transfer method as above is described.
During the preparatory stage, the first mobile device needs the MAC of the router of local area network (LAN) to be bound into staticip address by " Peanut " account.After having configured, the second mobile device in local area network (LAN) initiates TCP/IP request, establishes a communications link with the first mobile device.Then, the first mobile device converts the getpreviewsize of acquisition to JansonObject, sends to the second mobile device, and to realize the transmission of the configuration information of preview image, the second mobile device goes out concrete previewszie according to protocol analysis.First server performs camerapreview (unlatching preview), catches every frame binary system picture stream and sends to the second mobile device.Second mobile device performs GetYUVStream, and by internal conversion getRGBstream, performs cache with this stream of buffer memory simultaneously, then perform drawcachestream constantly, to show the preview image that the first mobile device captures in real time.
Further, the second mobile device, when drawing preview image, can also carry out local operation, e.g., take pictures, and be saved to this locality.Meanwhile, the second mobile device also can be initiated new TCP/IP request and be sent ControlStream to the first mobile device, and the first mobile device parses Control word string and decides it and take pictures or video recording behavior.
Other steps in Fig. 5 refer to Fig. 4 and corresponding explanatory note thereof.
Refer to Fig. 6, for the structural representation of a kind of mobile device in first embodiment of the invention, mobile device 40 shown in this execution mode is first mobile devices as server, and this equipment 40 comprises configuration module 41, communication module 42 and image processing module 43.
This configuration module 41 is for configuration of IP address.
Particularly, dynamic IP addressing is configured to static ip address by the media access control address MAC binding of route by this configuration module 41.
Further, this configuration module 41 binds the MAC of local area network (LAN) route, and dynamic IP addressing is configured to static ip address.
This communication module 42, for receiving the access request of the second mobile device transmission as client, is established a communications link by static ip address and the second mobile device; And send configuration information to the second mobile device of preview image.
Wherein, the configuration information of this preview image comprises the size of preview image, width and height.
This image processing module 43 catches image for utilizing camera, and controls communication module 42 image is sent to the second mobile device, makes the second mobile device according to the configuration information display image of preview image.
Particularly, the image that this image processing module 43 utilizes camera to catch, carries out binary coding to the image of catching, and to be sent to the second mobile device, makes the second mobile device according to the configuration information display image of preview image.
Further, this image processing module 43 carries out binary coding by needing each two field picture of preview, and the binary image encoder being sent to the second mobile device is yuv format.
Refer to Fig. 7, be the structural representation of a kind of mobile device in second embodiment of the invention, the mobile device 50 shown in this execution mode is second mobile devices as client, and this equipment 50 comprises communication module 51 and image processing module 52.
This communication module 51 is for sending access request, to establish a communications link with the first mobile device to the first mobile device as server; And receive the configuration information of the preview image that the first mobile device sends.
Wherein, after the first mobile device configuration network IP address completes, this communication module 51 as the second mobile device of client initiates access request by ICP/IP protocol, establishes a communications link with the first mobile device.
Wherein, the configuration information of this preview image comprises the size of preview image, width and height.
This image processing module 52 is resolved for the image sent the first mobile device, and according to the configuration information drawing image of preview image.
Particularly, the binary picture of this image processing module 52 to the yuv format that the first mobile device sends is decoded, and converts yuv format to rgb format, and according to the configuration information drawing image of preview image.
Further, this image processing module 52 also for respond user input the first image control instruction, to catch the image of current drafting.
Refer to Fig. 8, be the structural representation of a kind of mobile device in third embodiment of the invention, the mobile device shown in this execution mode, relative to the mobile device shown in Fig. 7, also comprises control module 63.
This control module 63, for sending the second image control instruction to the first mobile device, makes the first mobile device resolve the second image control instruction to process accordingly current image of catching.
First image control instruction as above and the second image control instruction are for taking pictures or record a video instruction.First mobile device and the second mobile device all can respond corresponding image control instruction, perform corresponding process, e.g., take pictures to the image of current drafting, and by the Image Saving of acquisition in this locality.
Other modules in Fig. 8 refer to Fig. 7 and corresponding explanatory note thereof.
A kind of image transfer method provided by the invention and mobile device, the first mobile device as server by camera preview to Image Real-time Transmission to other second mobile devices connecting this server, to carry out images share in real time.Further, other the second equipment can be taken pictures to the image of preview in this locality, video recording etc., preserves the image that the first mobile device as server is caught in real time.
The foregoing is only embodiments of the present invention; not thereby the scope of the claims of the present invention is limited; every utilize specification of the present invention and accompanying drawing content to do equivalent structure or equivalent flow process conversion; or be directly or indirectly used in other relevant technical fields, be all in like manner included in scope of patent protection of the present invention.

Claims (10)

1. an image transfer method, be applied between mobile device and carry out image transmitting, it is characterized in that, described method comprises:
First mobile device carries out IP address configuration as server;
Receive the access request of the second mobile device transmission as client, established a communications link by described static ip address and described second mobile device;
Send the configuration information of preview image to described second mobile device; And
The image of catching utilizing camera is sent to described second mobile device, makes described second mobile device show described image according to the configuration information of described preview image.
2. image transfer method according to claim 1, is characterized in that, the step that media access control address to be configured to static ip address as server by described first mobile device is specially:
Dynamic IP addressing is configured to static ip address by the media access control address binding of route by described first mobile device.
3. image transfer method according to claim 1, it is characterized in that, described the image utilizing camera to catch is sent to described second mobile device, the step making described second mobile device show described image according to the configuration information of described preview image is specially:
Utilize the image that described camera is caught, binary coding is carried out to the image of catching, to be sent to described second mobile device, make described second mobile device show described image according to the configuration information of described preview image.
4. image transfer method according to claim 1, it is characterized in that, described the image utilizing camera to catch is sent to described second mobile device, the step making described second mobile device show described image according to the configuration information of described preview image is specially:
The image of catching utilizing camera is sent to described second mobile device by ICP/IP protocol, makes described second mobile device show described image according to the configuration information of described preview image.
5. an image transfer method, be applied between mobile device and carry out image transmitting, it is characterized in that, described method comprises:
Second mobile device sends access request, to establish a communications link with described first mobile device as client to the first mobile device as server;
Receive the configuration information of the preview image that described first mobile device sends; And
The image that described first mobile device sends is resolved, and according to the configuration information drawing image of described preview image.
6. image transfer method according to claim 5, is characterized in that, also comprises:
First image control instruction of response user input, to catch the image of current drafting.
7. image transfer method according to claim 5, is characterized in that, also comprises:
Send the second image control instruction to described first mobile device, make described first mobile device resolve described second image control instruction to process accordingly current image of catching.
8. image transfer method according to claim 5, is characterized in that, the described image to described first mobile device transmission is resolved, and is specially according to the step of the configuration information drawing image of described preview image:
The binary picture of yuv format that described first mobile device sends is decoded, converts yuv format to rgb format, and according to the configuration information drawing image of described preview image.
9. a mobile device, is characterized in that, described equipment comprises:
Configuration module, for configuration of IP address;
Communication module, for receiving the access request of the second mobile device transmission as client, is established a communications link by described static ip address and described second mobile device; And send the configuration information of preview image to described second mobile device; And
Image processing module, for utilizing camera to catch image, and controls described communication module described image is sent to described second mobile device, make described second mobile device show described image according to the configuration information of described preview image.
10. a mobile device, is characterized in that, described equipment comprises:
Communication module, for sending access request, to establish a communications link with described first mobile device to the first mobile device as server; And receive the configuration information of the preview image that described first mobile device sends; And
Image processing module, resolves for the image sent described first mobile device, and according to the configuration information drawing image of described preview image.
CN201510650308.5A 2015-10-08 2015-10-08 Image transmission method and mobile equipment Pending CN105263134A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510650308.5A CN105263134A (en) 2015-10-08 2015-10-08 Image transmission method and mobile equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510650308.5A CN105263134A (en) 2015-10-08 2015-10-08 Image transmission method and mobile equipment

Publications (1)

Publication Number Publication Date
CN105263134A true CN105263134A (en) 2016-01-20

Family

ID=55102602

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510650308.5A Pending CN105263134A (en) 2015-10-08 2015-10-08 Image transmission method and mobile equipment

Country Status (1)

Country Link
CN (1) CN105263134A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107360430A (en) * 2017-07-07 2017-11-17 Tcl移动通信科技(宁波)有限公司 A kind of data transmission method of multi-screen interactive, mobile terminal and storage device
WO2023236115A1 (en) * 2022-06-08 2023-12-14 北京小米移动软件有限公司 Image processing method and apparatus, and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1917644A (en) * 2006-09-15 2007-02-21 中辉世纪传媒发展有限公司 Digital broadcast television system, set top box, and method for playing programms
CN101547342A (en) * 2008-12-31 2009-09-30 深圳创维-Rgb电子有限公司 System and method for audio-video monitoring based on WLAN
CN102547474A (en) * 2011-11-24 2012-07-04 杭州世导通讯有限公司 System and method for realizing video monitoring by fusion of extended extensible markup language (XML)-based messaging and presence protocol (XMPP) and routing table maintenance protocol (RMTP)
CN104184944A (en) * 2014-08-15 2014-12-03 小米科技有限责任公司 Method and device for obtaining multimedia data streams
CN104349202A (en) * 2013-07-26 2015-02-11 腾讯科技(深圳)有限公司 Video acquisition method and device thereof

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1917644A (en) * 2006-09-15 2007-02-21 中辉世纪传媒发展有限公司 Digital broadcast television system, set top box, and method for playing programms
CN101547342A (en) * 2008-12-31 2009-09-30 深圳创维-Rgb电子有限公司 System and method for audio-video monitoring based on WLAN
CN102547474A (en) * 2011-11-24 2012-07-04 杭州世导通讯有限公司 System and method for realizing video monitoring by fusion of extended extensible markup language (XML)-based messaging and presence protocol (XMPP) and routing table maintenance protocol (RMTP)
CN104349202A (en) * 2013-07-26 2015-02-11 腾讯科技(深圳)有限公司 Video acquisition method and device thereof
CN104184944A (en) * 2014-08-15 2014-12-03 小米科技有限责任公司 Method and device for obtaining multimedia data streams

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107360430A (en) * 2017-07-07 2017-11-17 Tcl移动通信科技(宁波)有限公司 A kind of data transmission method of multi-screen interactive, mobile terminal and storage device
WO2023236115A1 (en) * 2022-06-08 2023-12-14 北京小米移动软件有限公司 Image processing method and apparatus, and storage medium

Similar Documents

Publication Publication Date Title
EP3229476B1 (en) Method and apparatus for playing media stream on web browser
EP3275162B1 (en) Systems and techniques for web communication
US9172907B2 (en) Method and apparatus for dynamically adjusting aspect ratio of images during a video call
CN111294399B (en) Data transmission method and device
EP3032838A1 (en) Message processing method, device, gateway, set-top box and internet protocol television system
CN103348657B (en) Flow media playing method, equipment and system
WO2018166415A1 (en) Cloud storage system, media data storage method and system
CN109085950B (en) Multi-screen interaction method and device based on electronic whiteboard and electronic whiteboard
US20150319205A1 (en) Method for Transferring Media Stream and User Equipment
CN106357697A (en) Multi-terminal page synchronizing method based on WebSocket attribute synchronization
CN102761456A (en) Method, device and system for acquiring performance parameters of browser of mobile terminal
US20180014063A1 (en) Method and Apparatus for Accessing a Terminal Device Camera to a Target Device
WO2016086755A1 (en) Packet processing method and transparent proxy server
CN114666306B (en) WebRTC network connection establishment method, server, electronic device and computer readable storage medium
EP3399713B1 (en) Device, system, and method to perform real-time communication
CN106911732A (en) A kind of website visiting accelerating method and device
CN111385068B (en) Data transmission method, device, electronic equipment and communication system
CN105263134A (en) Image transmission method and mobile equipment
EP3079328B1 (en) Media resource sharing method, shared server and shared system
CN111818010B (en) Data transmission method and device, electronic equipment and storage medium
CN110659080B (en) Page display method and device, electronic equipment and storage medium
US10291882B2 (en) Call processing method and gateway
WO2016154831A1 (en) Method and device for realizing transmission control protocol (tcp) transmission
CN105230074B (en) Video cache switching handling method, device and system
CN108833434B (en) Method for realizing cross-network video call system based on IP bidirectional network set top box

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20160120

RJ01 Rejection of invention patent application after publication