OK I'm on to something, using
ctypes I was able to get my glTexImage2D calls to accept it (I haven't been able to get it to work quite right yet with distortion so I'm not sure if it's copying the data correctly yet, but that's another story).
Anyway I went back to PIL to take a look to see if I could get it to accept a
ctypes object. Based on this stackoverflow question I was able to get this code to run, but the image is partially corrupt as you can see, so something is going wrong.
Actually I just tested it some more and I realized that sometimes it comes out not as corrupt, so it may be that LeapMotion frees the memory before we use it or something...
Here is the code I'm working with right now:
leap_image = frame.images
imagedata = ctypes.cast(leap_image.data.cast().__long__(), ctypes.POINTER(leap_image.width*leap_image.height*ctypes.c_ubyte)).contents
image = PIL.Image.frombuffer("L", (leap_image.width, leap_image.height), imagedata, "raw", "L", 0, 1)