[osg-users] osgposter through Task Scheduler

Andreas Ekstrand andreas.ekstrand at remograph.com
Sun Jun 16 12:17:47 PDT 2019


I'm having problems with the osgposter example in Windows, or more 
precisely something similar I'm developing but the problem is easier to 
reproduce with osgposter. In my simple reproduction of the problem I'm 
trying to render an image automatically at computer startup by calling 
osgposter (inactive mode) from a Python script (os.system) activated as 
a task from Task Scheduler in Windows 10. But it seems to fail to fetch 
a valid OpenGL context. I have tried all rendering types in osgposter - 
fb, fbo, pbuffer and pbuffer-rtt.

The script works fine when started manually or when the task is set to 
start only when the user is logged on. But when activated as a task at 
computer startup whether user is logged on or not, it refuses to render 
anything. It just gets stuck in an infinite loop in the PosterPrinter 
class since FrameStamp::getFrameNumber() returns 0.

Before that, View::setUpViewInWindow results in the following messages 
SingleWindow::configure - GraphicsWindow has not been created successfully.
Viewer::realize() - No valid contexts found, setting up view across all 
SingleWindow::configure - GraphicsWindow has not been created successfully.
Viewer::realize() - failed to set up any windows

Does anyone know how to get this working without having to log on to a 
Windows user?  Should it work? I have a GeForce GT 710 with the latest 
drivers. Actually, I tried adding opengl32.dll from the Mesa3D library 
to the same folder as osgposter.exe to make it work when manually 
executed while logged on through Remote Desktop. It did the trick, but 
not when activated from Task Scheduler.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20190616/bff437bd/attachment.html>

More information about the osg-users mailing list