Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

image2wbmp(3) [php man page]

IMAGE2WBMP(3)								 1							     IMAGE2WBMP(3)

image2wbmp - Output image to browser or file

SYNOPSIS
bool image2wbmp (resource $image, [string $filename], [int $threshold]) DESCRIPTION
image2wbmp(3) outputs or save a WBMP version of the given $image. PARAMETERS
o $ image -An image resource, returned by one of the image creation functions, such as imagecreatetruecolor(3). o $filename - Path to the saved file. If not given, the raw image stream will be output directly. o $threshold - Threshold value, between 0 and 255 (inclusive). RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 image2wbmp(3) example <?php $file = 'php.png'; $image = imagecreatefrompng($file); header('Content-Type: ' . image_type_to_mime_type(IMAGETYPE_WBMP)); image2wbmp($image); // output the stream directly imagedestroy($image); ?> NOTES
Note WBMP support is only available if PHP was compiled against GD-1.8 or later. SEE ALSO
imagewbmp(3). PHP Documentation Group IMAGE2WBMP(3)

Check Out this Related Man Page

IMAGEPNG(3)								 1							       IMAGEPNG(3)

imagepng - Output a PNG image to either the browser or a file

SYNOPSIS
bool imagepng (resource $image, [string $filename], [int $quality], [int $filters]) DESCRIPTION
Outputs or saves a PNG image from the given $image. PARAMETERS
o $ image -An image resource, returned by one of the image creation functions, such as imagecreatetruecolor(3). o $filename -The path to save the file to. If not set or NULL, the raw image stream will be outputted directly. Note NULL is invalid if the $quality and $filters arguments are not used. o $quality - Compression level: from 0 (no compression) to 9. o $filters - Allows reducing the PNG file size. It is a bitmask field which may be set to any combination of the PNG_FILTER_XXX constants. PNG_NO_FILTER or PNG_ALL_FILTERS may also be used to respectively disable or activate all filters. RETURN VALUES
Returns TRUE on success or FALSE on failure. CHANGELOG
+--------+--------------------------------+ |Version | | | | | | | Description | | | | +--------+--------------------------------+ | 5.1.3 | | | | | | | Added the $filters parameter. | | | | | 5.1.2 | | | | | | | Added the $quality parameter. | | | | +--------+--------------------------------+ EXAMPLES
<?php $im = imagecreatefrompng("test.png"); header('Content-Type: image/png'); imagepng($im); imagedestroy($im); ?> SEE ALSO
imagegif(3), imagewbmp(3), imagejpeg(3), imagetypes(3), imagesavealpha(3). PHP Documentation Group IMAGEPNG(3)
Man Page

5 More Discussions You Might Find Interesting

1. Post Here to Contact Site Administrators and Moderators

Unable to open uploaded image

Hi, I am unable to view/open the image I uploded in one of the forums. https://www.unix.com/showthread.php?t=37793&page=2&pp=20 Please help. enc. (2 Replies)
Discussion started by: encrypted
2 Replies

2. Linux

error while retrieving image using system imager

This is the error that I am getting while retrieving image from image server using system imager.... Listening on LPF/lo/<null> sending on Socket/fallback/fallback-net DHCPDISCOVER on lo to 255.255.255.255 port 67 interval 5 DHCPDISCOVER on lo to 255.255.255.255 port 67 interval5... (1 Reply)
Discussion started by: nitesh_tarbani
1 Replies

3. UNIX for Advanced & Expert Users

How to save as image from a web page

I used flot to create a graph and I would like to be able to save/export the graph as an image. In firefox on windows you can just ctl rt-click and you have a save as image feature (which I can automate with js) but...I need this to work on a linux browser. On linux in firefox I can print preview... (11 Replies)
Discussion started by: vincaStar
11 Replies

4. UNIX for Dummies Questions & Answers

openssl dgst cat header problem

I am trying to run an old script to modify an image file with a modified header to bypass the md5 check but it comes up with an error message. The image file is for use on a Expressgate SSD so that I can add sqx files to it. This is a link from where I got the script:-... (3 Replies)
Discussion started by: r1speedyrider
3 Replies

5. OS X (Apple)

Help with blobbing

I am pretty new to scripting and i was wondering if anyone could help me out. Here is the situation. I am trying to make an action folder that when an image is saved to it, the image is automatically moved to a folder based upon the first 4 or 5 integers of the name. image names come in a... (2 Replies)
Discussion started by: kailasgurung
2 Replies