.htaccess
======================
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_REFERER} !^http://(www.)?owllab.com.*$ [NC]
RewriteRule .(jpg|jpeg|png|gif)$ - [NC,F]
</IfModule>
======================
or more simple solution!
======================
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST}@@%{HTTP_REFERER} !([^.@].(?:(?:co|or|gv|ac).)?[a-z]{2,7})@@https?://.(\1)/.*
RewriteRule .*.(jpe?g|png|gif|txt|pdf|zip) - [NC,F]
</IfModule>
======================
Response
PHP test for regex
======================
<?
//$tmp = "www.domain.com@@http://domain.com/dir1/test.php?pg=main&q=qqq";
$tmp = $_SERVER['HTTP_HOST']."@@".$_SERVER['HTTP_REFERER'];
echo $tmp;
echo "<br>";
echo preg_match("/([^@]*.(?:(?:co|or|gv|ac).)?[a-z]{2,7})@@https?:\/\/.*(\1)\/.*/", $tmp, $results);
print_r($results);
echo preg_last_error();
?>
======================