I have read past questions and answers regarding this in Stackoverflow. But couldn\'t find more up to date solution. There were some libraries available to do this task.