Apply custom css class while rendering an image Here I want to add an attribute for custom css class, is this possible using field_view_value, field_menu_image is my image's machine name

$image = field_get_items('node',node_load($nid, NULL, TRUE), 'field_menu_image');                         
$output=field_view_value('node', node_load($nid, NULL, TRUE), 'field_menu_image',$image[0]);
print render ($output);
field_view_value returns a renderable array so you should be able to just do.

$image = field_get_items('node',node_load($nid, NULL, TRUE), 'field_menu_image');                         
$output=field_view_value('node', node_load($nid, NULL, TRUE), 'field_menu_image',$image[0]);
$output['#item']["attributes"]["class"] = array('test');
print render ($output);