CN103327042B - A kind of by batch picture uploading to the method for network album and a kind of client - Google Patents

A kind of by batch picture uploading to the method for network album and a kind of client Download PDF

Info

Publication number
CN103327042B
CN103327042B CN201210075724.3A CN201210075724A CN103327042B CN 103327042 B CN103327042 B CN 103327042B CN 201210075724 A CN201210075724 A CN 201210075724A CN 103327042 B CN103327042 B CN 103327042B
Authority
CN
China
Prior art keywords
picture
thread
compression
uploading
uploaded
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.)
Active
Application number
CN201210075724.3A
Other languages
Chinese (zh)
Other versions
CN103327042A (en
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.)
Tencent Technology Shenzhen Co Ltd
Tencent Cloud Computing Beijing Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201210075724.3A priority Critical patent/CN103327042B/en
Publication of CN103327042A publication Critical patent/CN103327042A/en
Application granted granted Critical
Publication of CN103327042B publication Critical patent/CN103327042B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a kind of by the method for batch picture uploading to network album, comprising: when client receives batch picture uploading instruction, start M simultaneously and compress thread and N number ofly upload thread, M and N is positive integer; Compression thread is treated each width picture uploaded and is carried out compression process respectively, and joins in an image cache pond by the picture after process; Upload thread each width picture joined in image cache pond is uploaded in network album respectively.The present invention discloses a kind of client.Apply method and apparatus of the present invention, the uplink time of picture can be shortened.

Description

A kind of by batch picture uploading to the method for network album and a kind of client
Technical field
The present invention relates to network technology, particularly a kind of by batch picture uploading to the method for network album and a kind of client.
Background technology
Network album refer to a kind of support user by local picture uploading in the server of network side picture preserve scheme.
Along with popularizing of network album, everybody more and more likes the picture (as photo) oneself liked to upload in network album, thus is shared with the good friend etc. of oneself.
Along with the continuous lifting of camera pixel etc., picture volume is increasing, and most of network album provider is in order to save the memory space of server, capital requires that client is by before in picture uploading to server, first picture is compressed, to reduce the volume of picture under the prerequisite keeping certain definition.
And in actual applications, user once can upload several pictures usually, namely carry out batch picture uploading, Fig. 1 is existing by the process schematic of batch picture uploading to network album.As shown in Figure 1, first client is compressed picture A, and uploads in network album by network, afterwards, picture B is compressed, and uploads in network album, in addition by network, picture C is compressed, and uploads in network album by network, the like.
But certain problem can be there is in actual applications in aforesaid way:
For picture A, can find out, for being uploaded in network album, need through two subprocess, one is compression subprocess, one is upload subprocess, as a rule, the time that compression subprocess consumes is roughly 1: 1 with the ratio uploading the time that subprocess consumes, if client performance is bad, the time that compression subprocess consumes even can be greater than the time of uploading subprocess and consuming, that is, although the mode uploaded again after compressing picture can save the memory space of server, but also extend the uplink time of picture.
Summary of the invention
In view of this, main purpose of the present invention is to provide a kind of by the method for batch picture uploading to network album, can shorten the uplink time of picture.
Another object of the present invention is to provide a kind of client, the uplink time of picture can be shortened.
For achieving the above object, technical scheme of the present invention is achieved in that
By the method for batch picture uploading to network album, comprising:
When client receives batch picture uploading instruction, start M simultaneously and compress thread and N number ofly upload thread, described M and N is positive integer;
Described compression thread is treated each width picture uploaded and is carried out compression process respectively, and joins in an image cache pond by the picture after process;
The each width picture joined in described image cache pond uploads in network album by described thread of uploading respectively.
A kind of client, comprising:
Described receiver module, for after receiving the instruction of batch picture uploading, notifies that described processing module performs self function;
Described processing module, for after the notice receiving described receiver module, start M simultaneously and compress thread and N number ofly upload thread, described M and N is positive integer; Wherein, described compression thread is used for carrying out compression process respectively to each width picture to be uploaded, and by process after picture join in an image cache pond, described in upload thread for being uploaded to respectively in network album by each width picture joined in described image cache pond.
Visible, adopt technical scheme of the present invention, when needs carry out batch picture uploading, client can start M compression thread simultaneously and N number ofly upload thread, compress thread and upload thread and carry out parallel processing, namely compress thread treat each width picture uploaded carry out respectively compression process, and the picture after process is joined in image cache pond, simultaneously, upload thread each width picture joined in image cache pond is uploaded in network album respectively, that is, while picture being carried out to compression process, namely processed good picture is being uploaded, while uploading processed good picture, untreated picture is being carried out to compression process again, thus shorten the uplink time of picture widely.
Accompanying drawing explanation
Fig. 1 is existing by the process schematic of batch picture uploading to network album.
Fig. 2 is that the present invention is by the flow chart of batch picture uploading to the embodiment of the method for network album.
Fig. 3 is when the value of M and N is 1, according to mode of the present invention by the process schematic of batch picture uploading to network album.
Fig. 4 is the composition structural representation of client embodiment of the present invention.
Embodiment
For problems of the prior art, propose a kind of by the scheme of batch picture uploading to network album in the present invention, the uplink time of picture can be shortened.
For make technical scheme of the present invention clearly, understand, to develop simultaneously embodiment referring to accompanying drawing, scheme of the present invention be described in further detail.
Fig. 2 is that the present invention is by the flow chart of batch picture uploading to the embodiment of the method for network album.As shown in Figure 2, comprising:
Step 21: when client receives batch picture uploading instruction, start M simultaneously and compress thread and N number ofly upload thread, M and N is positive integer.
When user needs to carry out batch picture uploading, corresponding instruction can be sent to used client, as clicked a certain button on human-computer interaction interface, after client receiving instruction, starting M simultaneously and compress thread and N number ofly upload thread.
M and N is positive integer, and concrete value all can be decided according to the actual requirements, and the value of M with N can be identical, also can be different.
Step 22: compression thread is treated each width picture uploaded and carried out compression process respectively, and joins in an image cache pond by the picture after process; Upload thread each width picture joined in image cache pond is uploaded in network album respectively.
In this step, under the prerequisite keeping certain definition, compression thread is treated each width picture uploaded and is carried out compression process respectively, and is joined in image cache pond by the picture after process.
Mention, most of network album provider, in order to save the memory space of server, all can require that client is by before in picture uploading to server, first compresses picture, to reduce the volume of picture under the prerequisite keeping certain definition before.
Usually, server can issue an index to client, for illustration of the volume requirement of the every width picture after uploading, such as can not more than 0.5M, so, client can according to the volume of each width picture to be uploaded, determine to adopt which kind of compress mode voluntarily, such as Lossless Compression mode, or lossy compression method mode, or the mode that Lossless Compression and lossy compression method combine.
Lossless Compression refers to and adopts certain algorithm to represent the data message of repetition, and picture can reduce completely, can not affect image content, and picture detail also can not be made to have loss; Lossy compression method then has certain change to picture, more monochrome information is remained when preserving picture, and form and aspect and the information of colorimetric purity and the pixel of surrounding are merged, the ratio merged is different, the ratio of compression is also different, because amount of information decreases, therefore compression ratio can be very high, but picture quality also can correspondingly decline.
Compared to Lossless Compression, lossy compression method can reduce picture volume better.
In actual applications, for each width picture to be uploaded, can, respectively by the difference between the picture volume comparing its actual volume and server requirement, determine flexibly to adopt Lossless Compression mode or lossy compression method mode, or both modes of combining.
How to carry out Lossless Compression and lossy compression method is prior art.
The space size in image cache pond also can be decided according to the actual requirements, and is not restricted in the present invention.
In addition, when carrying out compression process to each width picture to be uploaded, usually can follow certain order, specifically follow which kind of order and be not restricted, can be preset by user.
Such as, each width picture to be uploaded to be when user once travels the photo of shooting, so then can carry out compression process by the order after arriving first to each photos according to shooting time.
While compression thread carries out compression process, upload thread and each width picture joined in image cache pond is uploaded in network album respectively.
Usually, upload thread each width picture joined in image cache pond to be uploaded in network album respectively by the order after arriving first according to the joining day.
Further, upload thread after often uploading in a width picture to network album, uploaded picture to be about to and to delete from image cache pond, to save the memory space in image cache pond.
Visible, in embodiment illustrated in fig. 1, when needs carry out batch picture uploading, client can start M compression thread simultaneously and N number ofly upload thread, compress thread and upload thread and carry out parallel processing, namely compress thread treat each width picture uploaded carry out respectively compression process, and the picture after process is joined in image cache pond, simultaneously, upload thread each width picture joined in image cache pond is uploaded in network album respectively, that is, while picture being carried out to compression process, namely processed good picture is being uploaded, while uploading processed good picture, untreated picture is being carried out to compression process again, thus shorten the uplink time of picture widely.
In theory, the value of M and N is larger, more can shorten the uplink time of picture, but the value of M and N is larger, and the load of client is also larger, therefore, needs the value determining M and N according to actual conditions.
Usually, in actual applications, the value of M and N is 1, Fig. 3 and is when the value of M and N is 1, according to mode of the present invention by the process schematic of batch picture uploading to network album.As shown in Figure 3, thread a (compression thread) is respectively to picture A, picture B and picture C etc. carry out compression process, and the picture after process is joined in image cache pond, simultaneously, thread b (uploading thread) is respectively by the picture A after process, picture B, picture C etc. uploads in network album by network, and, in order to save the memory space in image cache pond, thread b is after uploading in network album by picture A, picture A can be deleted from image cache pond, equally, after picture B is uploaded in network album, picture B can be deleted from image cache pond, after picture C is uploaded in network album, picture C can be deleted from image cache pond, the like.
If one or two the value in M and N is not 1, value as M is 2, the value of N is 1, and supposes that 2 compression threads are respectively thread a and thread b, so, can while compression process being carried out to picture A by thread a, carry out compression by thread b to picture B to process, afterwards, by thread a, compression is carried out to picture C and process, carry out compression by thread b to picture D to process simultaneously, the like.
So far, the introduction about the inventive method embodiment is namely completed.
Based on above-mentioned introduction, Fig. 4 is the composition structural representation of client embodiment of the present invention.As shown in Figure 4, comprising:
Receiver module, for after receiving the instruction of batch picture uploading, notification handler module performs self function;
Processing module, for after receiving the notice of receiver module, start M simultaneously and compress thread and N number ofly upload thread, M and N is positive integer; Wherein, compression thread is used for carrying out compression process respectively to each width picture to be uploaded, and is joined in an image cache pond by the picture after process, uploads thread for being uploaded to respectively in network album by each width picture joined in image cache pond.
The specific works flow process of client shown in Fig. 4 is as follows:
After receiver module receives the batch picture uploading instruction of user, notice Executive Module performs self function; After Executive Module receives the notice of receiver module, start M simultaneously and compress thread and N number ofly upload thread; For each width picture to be uploaded, under the prerequisite keeping certain definition, M compression thread carries out compression process to it respectively according to predefined procedure, compress mode can be: the mode that lossy compression method mode, Lossless Compression mode, lossy compression method and Lossless Compression combine, and joins in image cache pond by the picture after every width process; Meanwhile, the each width picture joined in image cache pond was uploaded in network album by the order after arriving first according to the joining day by N number of thread of uploading respectively, and, uploading thread can after often uploading in a width picture to network album, be about to uploaded picture delete from image cache pond, to save the memory space in image cache pond.
The concrete value of M and N all can be decided according to the actual requirements, and usually, the value of M and N is 1.
Client shown in Fig. 4 can refer to PC or mobile terminal etc.
Visible, in embodiment illustrated in fig. 4, when needs carry out batch picture uploading, client can start M compression thread simultaneously and N number ofly upload thread, compress thread and upload thread and carry out parallel processing, namely compress thread treat each width picture uploaded carry out respectively compression process, and the picture after process is joined in image cache pond, simultaneously, upload thread each width picture joined in image cache pond is uploaded in network album respectively, that is, while picture being carried out to compression process, namely processed good picture is being uploaded, while uploading processed good picture, untreated picture is being carried out to compression process again, thus shorten the uplink time of picture widely.
And scheme of the present invention has the scope of application widely, such as, for the network album in the communal space in social networks, when batch picture uploaded wherein by needs, scheme of the present invention can be adopted.
In addition, for user, after adopting scheme of the present invention, only need choose each width picture to be uploaded and send the instruction of batch picture uploading, subsequent treatment all can be completed by client and server automatically, convenient quick again.
Therefore, scheme of the present invention is applicable to universal and promotes very much, has broad application prospects.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, within the spirit and principles in the present invention all, any amendment made, equivalent replacement, improvement etc., all should be included within the scope of protection of the invention.

Claims (8)

1., by the method for batch picture uploading to network album, it is characterized in that, comprising:
When client receives batch picture uploading instruction, start M simultaneously and compress thread and N number ofly upload thread, described M and N is positive integer;
Described compression thread is treated each width picture uploaded and is carried out compression process respectively, and joins in an image cache pond by the picture after process;
The each width picture joined in described image cache pond uploads in network album by described thread of uploading respectively.
2. method according to claim 1, is characterized in that, the method comprises further:
Uploaded picture, after often uploading in a width picture to described network album, is deleted by described thread of uploading from described image cache pond.
3. method according to claim 1 and 2, is characterized in that, the mode of described compression comprises: the mode that lossy compression method mode, Lossless Compression mode and lossy compression method and Lossless Compression combine one of them.
4. method according to claim 1 and 2, is characterized in that, the value of described M and N is 1.
5. a client, is characterized in that, comprising: receiver module and processing module;
Described receiver module, for after receiving the instruction of batch picture uploading, notifies that described processing module performs self function;
Described processing module, for after the notice receiving described receiver module, start M simultaneously and compress thread and N number ofly upload thread, described M and N is positive integer; Wherein, described compression thread is used for carrying out compression process respectively to each width picture to be uploaded, and by process after picture join in an image cache pond, described in upload thread for being uploaded to respectively in network album by each width picture joined in described image cache pond.
6. client according to claim 5, is characterized in that, described in upload thread and be further used for,
After often uploading in a width picture to described network album, uploaded picture is deleted from described image cache pond.
7. the client according to claim 5 or 6, is characterized in that, the mode of described compression comprises: the mode that lossy compression method mode, Lossless Compression mode and lossy compression method and Lossless Compression combine one of them.
8. the client according to claim 5 or 6, is characterized in that, the value of described M and N is 1.
CN201210075724.3A 2012-03-21 2012-03-21 A kind of by batch picture uploading to the method for network album and a kind of client Active CN103327042B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210075724.3A CN103327042B (en) 2012-03-21 2012-03-21 A kind of by batch picture uploading to the method for network album and a kind of client

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210075724.3A CN103327042B (en) 2012-03-21 2012-03-21 A kind of by batch picture uploading to the method for network album and a kind of client

Publications (2)

Publication Number Publication Date
CN103327042A CN103327042A (en) 2013-09-25
CN103327042B true CN103327042B (en) 2015-12-16

Family

ID=49195572

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210075724.3A Active CN103327042B (en) 2012-03-21 2012-03-21 A kind of by batch picture uploading to the method for network album and a kind of client

Country Status (1)

Country Link
CN (1) CN103327042B (en)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105760408B (en) 2014-12-19 2020-04-28 华为终端有限公司 Picture sharing method and device and terminal equipment
CN106302581A (en) * 2015-05-21 2017-01-04 阿里巴巴集团控股有限公司 The introduction method of batch data and system
CN105162863A (en) * 2015-09-01 2015-12-16 北京皮尔布莱尼软件有限公司 Picture uploading device and method and computing equipment
CN105204740A (en) * 2015-09-23 2015-12-30 惠州Tcl移动通信有限公司 Manual focal length adjusting method and system for mobile terminal
CN105138253A (en) * 2015-09-30 2015-12-09 深圳市创想天空科技股份有限公司 Method and device for batch processing of pictures
CN105426569A (en) * 2015-10-27 2016-03-23 云南电网有限责任公司 Rule-driven automatic generation and update method for distribution network single line diagram
CN105897500A (en) * 2015-12-09 2016-08-24 乐视网信息技术(北京)股份有限公司 Picture processing method and device
CN106326070A (en) * 2016-08-29 2017-01-11 天脉聚源(北京)传媒科技有限公司 Method and device for uploading pictures
CN106126127A (en) * 2016-08-29 2016-11-16 天脉聚源(北京)传媒科技有限公司 A kind of method and device of uploading pictures
CN106998487A (en) * 2017-04-27 2017-08-01 努比亚技术有限公司 image processing method, device and mobile terminal
CN111447219B (en) * 2020-03-26 2023-02-03 深圳平安医疗健康科技服务有限公司 Image display method and device, storage medium and computer equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101098311A (en) * 2006-06-29 2008-01-02 腾讯科技(深圳)有限公司 Picture live transmission method and device in instant communication
CN101808182A (en) * 2010-02-05 2010-08-18 腾讯科技(深圳)有限公司 Method, terminal and system for uploading pictures
CN101860621A (en) * 2010-06-07 2010-10-13 中兴通讯股份有限公司 Mobile terminal file uploading method and mobile terminal

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101098311A (en) * 2006-06-29 2008-01-02 腾讯科技(深圳)有限公司 Picture live transmission method and device in instant communication
CN101808182A (en) * 2010-02-05 2010-08-18 腾讯科技(深圳)有限公司 Method, terminal and system for uploading pictures
CN101860621A (en) * 2010-06-07 2010-10-13 中兴通讯股份有限公司 Mobile terminal file uploading method and mobile terminal

Also Published As

Publication number Publication date
CN103327042A (en) 2013-09-25

Similar Documents

Publication Publication Date Title
CN103327042B (en) A kind of by batch picture uploading to the method for network album and a kind of client
US9344735B2 (en) Progressive shape based encoding of video content within a swarm environment
JP2018505571A (en) Image compression method / apparatus and server
US9667982B2 (en) Techniques for transform based transcoding
WO2013185237A1 (en) Methods and systems for automatically and efficiently categorizing, transmitting, and managing multimedia contents
CN105469381B (en) Information processing method and terminal
CN105049949A (en) Coding method of instant video and electronic equipment
CN105763761A (en) Image data transmission method and device
WO2017101126A1 (en) Method and system for data storage of surveillance system
CN102708192A (en) Method, system and device for sharing documents
Jo et al. Efficient Computation Offloading in Mobile Cloud Computing for Video Streaming Over 5G.
US20210250626A1 (en) Interruptible Video Transcoding
US20230353747A1 (en) Storage of evc decoder configuration information
US9489659B1 (en) Progressive sharing during a collaboration session
US20140009563A1 (en) Non-video codecs with video conferencing
US11032345B2 (en) Client side data stream processing
CN103428529A (en) Coding transmission method for medium cloud video data
Nightingale et al. Deriving video content type from HEVC bitstream semantics
US10448009B1 (en) Determining sample adaptive offset filter parameters
CN115174774A (en) Depth image compression method, device, equipment and storage medium
CN115190352A (en) Video data storage method and device, computer readable storage medium and electronic equipment
CN103686208A (en) Video cloud computing transmitting method
US10477215B2 (en) Systems and methods for variable compression of media content based on media properties
Kufa et al. Quality comparison of 360° 8K images compressed by conventional and deep learning algorithms
Zhu Overlapping boundary based multimedia slice transcoding method and its system for medical video and traffic video

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20200821

Address after: 518057 Nanshan District science and technology zone, Guangdong, Zhejiang Province, science and technology in the Tencent Building on the 1st floor of the 35 layer

Co-patentee after: TENCENT CLOUD COMPUTING (BEIJING) Co.,Ltd.

Patentee after: TENCENT TECHNOLOGY (SHENZHEN) Co.,Ltd.

Address before: Shenzhen Futian District City, Guangdong province 518044 Zhenxing Road, SEG Science Park 2 East Room 403

Patentee before: TENCENT TECHNOLOGY (SHENZHEN) Co.,Ltd.

TR01 Transfer of patent right