sample.html
<html>
<body>
<img src="./gazou.php">
</body>
</html>

gazou.php
<?php
require_once(関数ファイル);
rotate('roteta.jpg');
//出力処理
?>