Changing/Convert from UE4 coordinates to OpenGL coorinates

I am trying to convert from UE4 coordinates (Z up) to opengl coorinates (Y up) but I cant seem to get around it.

I do this Matrix transforming from X+ right, Y+ up, Z- deep to Y+ right, Z+ up, X+ deep [mat = M]

 0  1  0  0
 0  0  1  0
-1  0  0  0
 0  0  0  1 

But I end up getting the wrong result and also the rotation....

I get ActorTranfrom from (T) = this->GetTransform()

then FTransform R = T * M

Then I do the R - ToMatrixWithScale() - then get send it to OpenGL backend.

But the orientation is wrong... What am I doing wrong ?