I was using the pong tutorial from here: http://trevorappleton.blogspot.co.uk/2014/04/writing-pong-using-python-and-pygame.html as my basis. I made sure I had the 1.9.2a pygame version so I could get the get_view class, and then I tried to run
- Code: Select all
view = DISPLAYSURF.get_view('3')
My understanding was that that would give me three bytes for each pixel (R, G, and B values) and that I could do what I wanted with it. I can get it to run fine, but I cannot seem to access the bytes. I tried to write them to a file just to look at them and make sure they are doing what I wanted, but I can't seem to get that to do what I want.
At the end of the day, I want to pass the comma separated values on to an external module to process them, so if there is a better approach than what I am trying, I am all ears!!