A method to extract shapes of bubble polyhedra from three-dimensional nuclear magnetic resonance image data of foam has been developed, The method consists of four steps: first, to compute series of maximum intensity projection images from the three-dimensional NMR image data of foam to visualize the network structure of the bubble edges; second, to measure the three-dimensional coordinates of vertices of the bubble polyhedra interactively on a CRT using the series of MIP images to obtain polyhedral edges; third, to construct polyhedral faces from the assembly of the edge data; and fourth, to construct bubble polyhedra from the assembly of the face data, The algorithm for construction of polygons and polyhedra is based on the selection of polygons or polyhedra from an enormous number of possible combinations of edges or faces under some simple selection rules, Since the computation time for the selection increased exponentially with the number of the edge data, a 'partial volume sweeping' method in which a cubic region which could accommodate any bubble polyhedron was swept over the three-dimensional image area, was developed to reduce the computation time, By using this method, it was demonstrated that the shapes of many bubble polyhedra could be extracted automatically from the assembly of the edge data within a practical computation time. (C) 1997 by John Wiley & Sons, Ltd,