I’ve made gradient images using PHP GD horizontal and vertical but how can you get images like these.

These are example images for the Emulate Gradient Fill PHP class
EDIT:
I want to know how to make these from scratch, the website is an example
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
From the site documentation:
So in the function you set the direction to diamond etc, try out the different ones on your own to see how they display.
EDIT
To make them from scratch, well the easiest way is look at the source code of that script: http://planetozh.com/download/gd-gradient-fill.php from there you should be able to rummage through it and get the proper commands for it. Given it is only 240 lines of code it should be trivial to read through it.