Merge branch 'cairocanvas' into windows+cc
[ardour.git] / gtk2_ardour / video_image_frame.cc
index dffab96ab5fc7470a184b5bdfca6278a42e3c75d..ebcb9e6f96c8b9aabc52806b18b20075b404cdfe 100644 (file)
@@ -34,6 +34,7 @@
 
 using namespace std;
 using namespace ARDOUR;
+using namespace VideoUtils;
 
 static void freedata_cb (uint8_t *d, void* /*arg*/) {
        /* later this can be used with libharvid
@@ -209,8 +210,8 @@ http_get_thread (void *arg) {
        int timeout = 1000; // * 5ms -> 5sec
        char *res = NULL;
        do {
-               res=curl_http_get(url, &status);
-               if (status == 503) usleep(5000); // try-again
+               res=a3_curl_http_get(url, &status);
+               if (status == 503) Glib::usleep(5000); // try-again
        } while (status == 503 && --timeout > 0);
 
        if (status != 200 || !res) {
@@ -249,8 +250,8 @@ VideoImageFrame::http_download_done (char *data){
        }
 
        exposeimg();
-       /* don't request frames rapidly, wait after user has zoomed */
-       usleep(20000);
+       /* don't request frames too quickly, wait after user has zoomed */
+       Glib::usleep(40000);
 
        if (queued_request) {
                http_get_again(want_video_frame_number);