Hmm, in general, that looks about right–assuming that by “something like” you mean you are not actually using render and base.win, since render is a global that refers to the already-existing 3-d scene graph, and base.win refers to your main window.
If you’re creating an offscreen buffer, it should look something like this: