Indexing by Shape of Image Databases Based on Extended Grid Files