================================================================================
Instructions for patch-based Image completion, Release 1.00
--------------------------------------------------------------------------------

Author: Pulak Purkait (pulak_r@isical.ac.in)
        [Used PatchMatch algorithm for nearest-neighbour search]
		PatchMatch : http://gfx.cs.princeton.edu/pubs/Barnes_2009_PAR/index.php
Date: October 10, 2012
**********************
Website for updates: http://www.isical.ac.in/~vlrg/?q=node/11


This code is provided as is, with no guarantees except that 
bugs are almost surely present.  Published reports of research 
using this code (or a modified version) should cite the 
article that describes the algorithm: 

[Purkait12] P. Purkait and B chanda, Digital Restoration of Damaged Mural images,
		    ICVGIP 2012, Decembar 2012.

Comments and bug reports are welcome.  Email to pulak_r@isical.ac.in, 
for any query or improvements.   

You are free to modify, extend or distribute this code, provided  
you cite the above article. 

=================================================================================

This is the MATLAB 2011b implementation of Purkait12. To make this code workable you 
must have PatchMatch executables available at 
http://gfx.cs.princeton.edu/pubs/Barnes_2009_PAR/index.php
*************************************************************************************************
Download the PatchMatch executables from the above website and replace patchmatch_main directory. 
*************************************************************************************************
This code is built on Linux system, for windows you need to make appropriate 
changes (minor, probably the directory paths). Run the .sh file 
(run_jvm_matlab_Sr_Topic.sh) on terminal. Check the Matlab installation path 
on the sh file. If everything goes fine then it would enter to the matlab 
terminal without any warning. 

We only share a demo program of main module of the algorithm. The remainning modules will 
come in the next Release. 

To start the code run following : 
[pulak@ecsu SR_Topic_Multi_Dict]$ ./run_matlab_PM.sh

To generate texture based on an exemplar image run 
>>Texture_synthesis

For inpainting run (Check you mask the image correctly, and its in the same directory as 
the original image with '-mask.png' extension.)
>>Patch_based_inpainting

If you are getting stuck anywhere put a mail on pulak_r@isical.ac.in. Best Wishes. 

========================================================================================

