[DGD] Sparce Matrix
Kevin Carpenter
kevinc at kplace.monrou.com
Tue Apr 27 02:29:33 CEST 1999
Ludger -
What I'm looking to do is have nested sparse matrixes to store
the 3D coordinates of every object viewable at a given level in
the inheritance tree.
For instance, if I defined a "world" root node object, it would
contain a object pointer to the object, if it existed, whose lower
left-hand corner was at location X,Y,Z. That pointed to object
would contain dimensional information to define its size. Using
this, for instance, I could ensure that a town or dungeon is
completely mapable on paper, or could accurate represent room locations
in a split level home. Each container object would also contain
such a matrix to reference items stored in the container.
Does that help?
Kevin C.
balduin at uni-paderborn.de write:
>
> Hello Kevin!
>
> > Anybody have any suggestions on how to efficiently store and search
> > a large 3-D sparse matrix?
>
> What do you need ? An octree ? A grid ? Or what else ? If we talk
> about trees, do you want the indices of each node to be sparse ?
> Or is it sufficient, that the tree is sparse ?
> Depending on your exact problem nested arrays or nested mappings
> will fit best.
>
> If you just want to store a 3d map of uniform sized rooms, a nested
> mapping will probably suit your needs best. Just use one mapping
> along the x-axis, insert there a mapping along the y-axis and in each
> a mapping along z. If coords of rooms are not unique. You will have
> to store a list of rooms in this mapping.
>
> Ludger
> (balduin at uni-paderborn.de)
--
Kevin Carpenter
Kevin's Home Page: http://www.monrou.com/kevinc
(Expressing his comments from home in St. Louis, where this message originated)
List config page: http://list.imaginary.com/mailman/listinfo/dgd
More information about the DGD
mailing list