SDL & openGL on the same surface


Apologies in advance as I imagine this has been covered before but
searching round I cant find anything specific so I thought I’d ask:

Can I use SDL 2D-drawing functions and openGL 3d stuff on the same surface,
and if so how? I am trying to draw the actual game using openGL on the
main part of the screen (bounded off by glViewport) and display health,
scores, etc using SDL on the right hand side but my calls to SDL_FillRect
seem to have no effect, Im presuming this is to do with the fact that
buffering works differently under openGL to normal SDL. Can anyone point
me in the right direction on this?