C++ structure in pyroot

Is it possible to build a c++ style structure in pyroot and pass it to the c++ code?

For example,
I need the following structure an input in the following code.

struct ttt {
  int a; 
  float b; 
} test;

obj = ROOT.cpp_code(test)

Thanks

Maybe the PyROOT documentation can help?