More GLES fixes. ref_gl compiles without errors.