Category “Programming”

Jul 17
2010

33
Comments
delicious bookmark counter button with total bookmark count

del.icio.us needs no introduction, and if you still do not use delicious bookmarking service, there is something obviously missing in your life! Delicious is a famous social bookmarking site that has achieved rapid popularity and growth ever since it was being purchased by Yahoo Inc in 2005. Delicious is my all-time favorite bookmarking service. Many features have contributed to this, including the website’s simple interface, human-readable URL scheme, a novel domain name, a simple REST-like API, and RSS feeds for web syndication. Hence I was really particular about placing a delicious badge in my blog from the very beginning.

As part of my recent blog redesign I’ve searched many places for a nice looking delicious bookmark button which can also display the total bookmark count just like the tweetmeme button. I wanted a button that blends along with other bookmarking buttons such as twitter, digg, facebook etc. A significant amount of my time was spent on googling and browsing through the wordpress plugin directory, but I never found what I wanted.

So finally, I’ve decided to create my own wordpress plugin. After going through some beginner level tutorials on wordpress plugin development nuts and bolts, I have created what I exactly wanted. I am really really happy, that I have become the proud owner of a wordpress plugin :-)
Read the rest of this entry »

The DRY Principle in web design

Posted By: Deepu Balan on Thursday, 17 June, 2010
Jun 17
2010

6
Comments
Don't repeat yourself principle in web design

The DRY (Don’t Repeat Yourself) is a software development principle, which has been formulated by Andy Hunt and Dave Thomas in their book The Pragmatic Programmer. The DRY code philosophy is stated as “Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.” A system’s knowledge is far broader than just its code. It refers to database schemas, test plans, the build system, even documentation. In simple words DRY principle is a software design theory that stresses the importance of not duplicating code.

Every software programmer these days uses a variety of design principles and design patterns in their day to day programming tasks. It helps them improve the quality, performance and maintainability of the software system by avoiding code redundancy.

DRY principle in CSS coding

Unlike software programming web design lacks formal principles or theories of its own. Knowing and understanding certain software principles can really benefit you as a web designer / developer. Here, by incorporating DRY principle in web design, especially in CSS coding can really enhance our web design experience.

Avoiding code duplication is one of the basic principles of CSS coding from the start. To write clean and optimized CSS code is the key to develop faster loading and less bandwidth-burning websites. In the case of a website with 50000 monthly hits, if you can save 5 KB by optimizing the CSS file, you will eventually save more than 2.5 GB bandwidth a year. The result can be really overwhelming for heavy traffic generating websites. Read the rest of this entry »

POV-Ray : The Power of Ray Tracing

Posted By: Deepu Balan on Sunday, 3 January, 2010
Jan 3
2010

15
Comments
Have a look at the below photograph of a busy city, Just click on it and open the larger version and see the details.

The Wet Bird - by Gilles Tran (2001)

Would you believe me if I tell you that it’s an artificial graphic created with the help of a computer program, by applying millions and even billions of complex mathematical calculations? Believe me it’s pure mathematics which rules over creativity and in-born talents like ability to paint, draw or sculpt. This wonderful mathematical model is called Ray-Tracing.

What is Ray-Tracing?

Ray-tracing is a method of creating visual art in which a description of an object or scene is mathematically converted into a picture. In more specific terms, ray-tracing is the process of mathematically generating near-photorealistic images from a given description of a scene via geometrical modeling of light rays.
One of the most important factors which I believe about computer based ray-tracing over traditional art forms is that it does not require in-born talents like drawing or painting skills which in some cases requires years of hard work to master, but here it places the burden on a computer program called POV-Ray.

So, what is POV-Ray?

The Persistence of Vision Raytracer, or POV-Ray, is a high-quality, freely available ray-tracing software package that is available for Windows, Mac and UNIX platforms. Yes of course, it’s free! If you’re a programmer interested in POV-Ray, you can even pick up a copy of the source code without charge. POV-Ray is definitely one of the most commonly used ray-tracing software to date, because of its relative ease of use and powerful features.

Instead of calling it a software, POV-Ray is more of a rendering engine, which means it takes a file as an input and gives the output after rendering it without much help in the way of a user interface.
Describing scenes to POV-Ray is fairly simple. We give POV-Ray, a file containing a description of every object in the scene, written in the POV-Ray language (Click Here to see a sample piece of POV-Ray code). Each object’s description consists of:

1. What type of object you want (one of POV-Ray’s simple objects or one you’ve created yourself); and
2. Various attributes of the object (its color, how it reflects light, etc).

POV-Ray takes this file and generates a picture, which you can then view.

Some more samples

Please go through some amazing ray-traced images  created with POV-Ray. Click on these images to view it’s larger version.

Glasses - created by Gilles Tran

The Kitchen" by Jaime Vives Piqueres (2005)

Read the rest of this entry »


Copyright © 2010 Deepu Balan, All rights Reserved

Design by Deepu Balan, Powered By Wordpress