Implementation of shape_query and bb_query functions
Merge pull request #13 from nskrypnik/master

Looks good to me thanks Niko!