I am currently trying to get a screenshot of the fame of my movie with the circle I have drawn over the frame both in the screenshot. I have successfully gotten a frame of the movie using get movie frame and a screenshot of the circle I have drawn, but I am having trouble figuring out how to get them both in the same screenshot. The circle is in the back and the frame of movie is in the front. Is it possible to get screenshot of both buffers?
event.clearEvents()
circle= visual.Circle(win=mywin, units="pix",radius=15, fillColor=[-1,-1,-1], edges=128)
circle.pos = [Xpos[frame],Ypos[frame]]
circle.draw()
print ("Frame"), frame
print ("Resp"), resp[frame]
print ("Xpos"), Xpos[frame]
print ("Ypos"), Ypos[frame]
print ("xxxxx")
output = open("Encode_" + frameInfo[1] +"_to_"+frameInfo[2] + '.txt','w')
output.write("sequence ID:" + "\t" + frameInfo[0] + "\n")
for frame in range(int(frameInfo[1]),int(frameInfo[2])+1):
output.write(str(frame)+ "\t"+str(Xpos[frame])+ "\t"+str(Ypos[frame])+"\t"+str(resp[frame])+"\n")
#output.write(fnamelist2[tord[trial]] + "\t" + str(responses2[tord[trial]]) + "\t" + str(nmoves2[tord[trial]]) + "\n")
mywin.getMovieFrame(buffer='back')
file="screen"+str(frame)+".png"
print file
mywin.saveMovieFrames(file,clearFrames=False)
print frame
output.close()
mywin.close()
core.quit()