PHP Classes

File: demo1_rotation.php

Recommend this page to a friend!
  Classes of Jakob Riedle   Imagedit Pro   demo1_rotation.php   Download  
File: demo1_rotation.php
Role: Example script
Content type: text/plain
Description: Demo 1: Rotation
Class: Imagedit Pro
Image manipulation operations and face detection
Author: By
Last change:
Date: 13 years ago
Size: 368 bytes
 

Contents

Class file image Download
<?php
   
include("class.imagedit.php");
    function
getImage($url)
    {
       
$image = new imagedit($url);
       
$angle = rand( -180 , 180 );
       
$image->rotate( $angle );
       
        return
$image->getPNG();
    }
?>
<body style="background: yellow;">
    <h1>Imagedit Demo 1: Rotation</h1>
    <img src="data:image/png;base64,<?=base64_encode(getImage("test.png"))?>"></img>
</body>