Finally got 2 peers talking to each other properly!
After what seems like an age banging my head against a brick wall, I’ve finally worked out why my peers couldn’t quite talk properly. I was attempting to return an NSImage as a distributed objects parameter. This worked fine if the object was distributed on the same physical machine, but as soon as I tried to send it to another peer, it just didn’t work and more strangely actually displayed the images on the bottom left hand corner of the senders window, very strange. Anyway, the fix (as always) was simple. I encoded the NSImage TIFFRepresentation as an NSData object and sent that over then decoded at the far side. This screenshot shows the results of that labour, most satisfying! Now onto building an app out of all these bits I’ve constructed…

On the left is this computer’s information and on the right is the received Peer information (the lock/unlock icons are just hard coded at the moment.
Filed under: pendulum sync | Leave a Comment
No Responses Yet to “Finally got 2 peers talking to each other properly!”