vintageJS

Vintage effects for your images with the HTML5 canvas element

vintageJS is a jQuery plugin that uses the html5 canvas element to add a great vintage look to your photos. vintageJS comes with three effect-presets and can be customized very easily.

Requirements

To use vintageJS you need the latest jQuery build from jquery.com, a browser that supports the HTML5 canvas element and the current version of vintageJS from github.

This jQuery-Plugin was tested and worked fine in the following browsers:

Usage

You need to load the jQuery Library, the vintageJS Library and the vintageJS stylesheet in the header of your html document:

<script src="src/jquery.js"></script>
<script src="src/vintage.js"></script>
<link rel="stylesheet" type="text/css" href="css/vintagejs.css" media="all" />
            

The next step is to add an event listener to the images to trigger the vintage-effect. For this example we will use the click event:

<script>
$(function () {
    $('img.vintage').click(function () {
        $(this).vintage();
    });
});
</script>
            

That's it! Now add images with the class "vintage" to your html and click on them to see the result.

Options

You can change the effect by adding options to the vintageJS call. There are three presets that you can use:

If you like to change the style to your own settings, here are the full options you can manipulate:

Here is how a custom call could look like (see the result by clicking on the image at the right side):

<script>
$(function () {
    $('img.vintage').click(function () {
        $(this).vintage({
            vignette: {
                black: 0.8,
                white: 0.2
            },
            noise: 20,
            screen: {
                red: 12,
                green: 75,
                blue: 153,
                strength: 0.3
            },
            desaturate: 0.05
        });
    });
});
</script>
            

Examples

Click on the images to see the default effect of vintageJS.

http://www.sxc.hu/photo/1340610

Source: http://www.sxc.hu/photo/1340610

http://www.sxc.hu/photo/1339386

Source: http://www.sxc.hu/photo/1339386

http://www.sxc.hu/photo/1340257

Source: http://www.sxc.hu/photo/1340257

http://www.sxc.hu/photo/1336482

Source: http://www.sxc.hu/photo/1336482

http://www.sxc.hu/photo/1281259

Source: http://www.sxc.hu/photo/1281259

http://www.sxc.hu/photo/1340317

Source: http://www.sxc.hu/photo/1340317