[vbox-dev] Guest os display image from vbox python API?
eyeofhell at me.com
Thu Jun 25 08:12:12 PDT 2009
In virtualbox API documentation it is listed that getFramebuffer()
takes more than one parameter. I have tried your example code on both
windows and ubuntu, beta1 and beta2. It's always 'invalid number of
parameters' error. What is a trick to run a code you have suggested?
Best, Grigory Petrov
On Jun 23, 2009, at 2:21 PM, Nikolay Igotti <Nikolay.Igotti at Sun.COM>
> Hi Grigory,
> Yes, it is possible, although in somewhat convoluted way, for
> example on Linux in vboxshell one can issue following command
> (assuming you started guest in not headless mode):
> vbox> guest nt4sp6 os.system('xwd -id '+str
> (console.display.getFramebuffer(0).winId)+'| xwdtopnm | pnmtopng
> > /tmp/Screenshot.png')
> It will take screen of the first display in guest called 'nt4sp6',
> although relying upon few external programs
> for image conversion. Similar approach can be taken on Windows.
> We're considering implementing more straightforward API in the future.
> Grigory Petrov wrote:
>> Is it possible to use Python API in order to get image of guest os
>> display? (complete display or part of display, with or without
>> guest additions, it doesn't matter). I can speculate that this can
>> be done somehow via getFramebuffer() method, but exact sequence is
>> unclear - it's no example available :(.
>> Best, Grigory
>> vbox-dev mailing list
>> vbox-dev at virtualbox.org
More information about the vbox-dev