Panda3D 1.10.0 render on exist window?

I’m using Panda3D 1.10,0 and trying to initialize it on an exist window as what I did with Panda3D 1.9.2. But it does render anything and output:

This is my code:

#include <QApplication>
#include <pandaSystem.h>
#include <pandaFramework.h>
void MainWindow::pressed()
{
    int argc = __argc;
    char **argv = __argv;
    PandaFramework framework;
    WindowFramework *window;
    framework.open_framework(argc, argv);
    WindowProperties prop;
    framework.get_default_window_props(prop);
    prop.set_parent_window((size_t)this->winId());
    window = framework.open_window(prop, 0);
    window->setup_trackball();
    Thread *current_thread = Thread::get_current_thread();
    while (framework.do_frame(current_thread) && this->isVisible())
    {
        QApplication::processEvents();
    }
}

Can someone help me on this?
Thanks

Did you mean to say “it doesn’t render anything”? Does that mean you get a grey window, or no sign of the Panda window at all?

I don’t believe that the SetForegroundWindow warning is consequential.

You may want to make sure that the origin of the window is appropriate, relative to its parent window. You can make sure of this using prop.set_origin(0, 0).

Which operating system are you testing this on?

oh fuck, i did forget that set_origin thing, it works, thanks :smiley:
btw i found some android stuff in the repository, is official android build coming?

Proof-of-concept support for C++ programs on Android has existed for a while, but nobody is working on it right now (to my knowledge).