pgSphere uses GiST to create spherical indices. An index speeds up the execution time of operators <@, @, &&, #, =, and !=. You can create an index with the following spherical data types:
point (spoint)
circle (scircle)
line (sline)
ellipse (sellipse)
polygon (spoly)
path (spath)
coordinates range (sbox)
pgSphere uses GIN to create smoc indices. An index speeds up the execution time of operators <@, @>, &&, =, and <>.
The index works by casting all contained smocs to a fixed level, and for each pixel at that level, storing which smocs overlap with that pixel. This is especially beneficial for "overlaps" queries using the && operator. Two levels of granularity are provided: the default opclass smoc_gin_ops works on level 5 with a resolution of 12288 pixels, while the opclass smoc_gin_ops_fine works on level 8 with 786432 pixels. The downside of that approach is that storing large smocs like "all sky" (0/0-11) produces a large number of index entries.