I am looking for creating a visual representation of a tree data structure in iOS . The data stored in the node tree is an image and label, and node can contain up to 6 children.
I currently have a collection view with a custom layout, where I programmatically compute the x and y of each node when I cross my home tree.
This solution works, but simple. As I create more functionality, I expect it to fall apart.
I considered creating an image after the tree was built, and just using the image, but I plan to implement some kind of branching / crashing on the branches. I also need a way to zoom in and out throughout the tree, which doesn't seem very easy when browsing through collections.
Is there a better solution?
source share