On nextgen gallery, we use [nggallery id=x] short tag on post/page to display our desired gallery. To display desired gallery on any place in a theme, we can use the following custom code:
$newnggShortcodes = new NextGEN_Shortcodes;
echo $newnggShortcodes->show_gallery( array("id"=>$key,"images"=>x,"template"=>"popular") );
Where $key is gallery id
x is number of gallery image to be displayed on that page
Popular is the template to display gallery (generally it will be inside nextgen-gallery\view\gallery.php), But you can create your own. For that creat copy of that gallery.php and rename it as gallery-{template name}.php. Here we are using template name as popular so the template file will be gallery-popular.php
Similarly for album we can use on theme file as
$newnggShortcodes = new NextGEN_Shortcodes;
echo $newnggShortcodes->show_album( array("id"=>$albums_id, "template"=>"extend") );
Here, $albums_id is id of album.
Template is same as above ie it uses nextgen-gallery\view\album-extend.php
or on post/page we can use [album id=x template=extend] or [album id=x template=compact] on content section
Similarly for single picture thumbnail we can use
$newnggShortcodes = new NextGEN_Shortcodes;
echo $newnggShortcodes->show_thumbs( array("id"=>$picture_id, "template"=>"") );
Here, $ picture _id is picture id.
Template is same as above ie it uses nextgen-gallery\view\imagebrowser.php by default. We can create own template same as above.
And for single picture we can use
$newnggShortcodes = new NextGEN_Shortcodes;
echo $newnggShortcodes->show_singlepic( array("id"=>$picture_id,"w" =>'',"h"=>"","mode"=>"","float"=>"","link"=>"","template"=>"") );
or on post/page we can use [singlepic id=x w=width h=height mode=web20|watermark float=left|right]on content section