Exporting PNG from rhino

I’d suggest going the RhinoCommon route directly (i.e. don’t script the command):