cURL / Mailing Lists / curl-library / Single Mail

curl-library

Control the download

From: Yoav Einav <yoave_at_qwilt.com>
Date: Wed, 21 Sep 2011 18:37:39 +0300

Hi,

 

Say I execute a GET request for a .flv from an http server, whereas I'm the
client.

I was wondering how can I change the GET request behavior, so I'll have
control of the response -

let's say for example:

1. Example 1: getting the file in chunks of 100KB (chunk by chunk).

2. Example 2: getting 1MB as fast as possible, and then continue in a
given download rate.

 

Notes:

. I've seen in the code the CURL_MAX_WRITE_SIZE MACRO (in curl.h
header file) that calls the maximum amount of data that can be passed to the
write callback.

. I'm using CURLOPT_WRITEFUNCTION option for a write callback
function

. Also using the CURLOPT_MAX_RECV_SPEED_LARGE option to control the
average download rate

 

BUT, I need better control of it, any advice?

 

Thanks

 

Yoav

 

 

 

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-09-21