Use the CURLOPT_HTTPHEADER option:
curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-Type: image/jpeg"));
So specify Content-Type headers specifically for file uploads, use:
$params = array('name'=>'@D:\globe.jpg;type=image/jpeg');
curl_setopt($ch, CURLOPT_POSTFIELDS, $params);