Hey Leute!  
 
Folgender Code:
	
wenn ich die Funktion mit 
	
aufrufe, ist die BG-Farbe immer Schwarz, obwohl ich ja Weiss gesetzt habe - Warum? Ich habe schon diverses versucht (überall weiss reingesetzt, transparenz entfernt) - ergebnislos. Der Hintergrund ist immer schwarz.
GD-Version: bundled (2.0.28 compatible)
FreeType Version: 2.1.7
PHP API: 20041225
PHP Extension: 20050922
(sry bin nicht so der profi, was braucht ihr noch für angaben?)
Gruss fletschge
					 
 Folgender Code:
PHP-Code:
	
	
function draw_circle ($x_position, $y_position, $image_height, $image_width, $ellipse_height, $ellipse_width)
{
    // create the image        
    $image = imagecreatetruecolor($image_height, $image_width);
    
    // set the colors
    $image_color = array();
    $image_color['white'] = imagecolorallocate($image, 255, 255, 255);
    $image_color['transparent'] = imagecolortransparent($image, $image_color['white']);
    $image_color['ellipse'] = imagecolorallocate($image, 200, 200, 200);
    
    
    // fill the image with white (bg)
    imagefill($image, 0, 0, $image_color['transparent']);
    // draw the ellipse
    imageellipse($image, $x_position, $y_position, $ellipse_width, $ellipse_height, $image_color['ellipse']);
    
    
    return $image;
} 
PHP-Code:
	
	
imagepng(draw_circle(50,50,500,500,60,60)); 
GD-Version: bundled (2.0.28 compatible)
FreeType Version: 2.1.7
PHP API: 20041225
PHP Extension: 20050922
(sry bin nicht so der profi, was braucht ihr noch für angaben?)
Gruss fletschge
 
          
 
  
							
						
Kommentar