gltrace_egl.cpp revision f132ac35d82a2960542619fb3fb91d22ab256dc7
1/* 2 * Copyright 2011, The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17#include <cutils/log.h> 18 19#include "gltrace.pb.h" 20#include "gltrace_context.h" 21#include "gltrace_fixup.h" 22#include "gltrace_transport.h" 23 24namespace android { 25namespace gltrace { 26 27void GLTrace_eglSwapBuffers(void *dpy, void *draw) { 28 GLMessage glmessage; 29 GLTraceContext *glContext = getGLTraceContext(); 30 31 glmessage.set_context_id(1); 32 glmessage.set_function(GLMessage::eglSwapBuffers); 33 34 // read FB0 since that is what is displayed on the screen 35 fixup_addFBContents(&glmessage, FB0); 36 traceGLMessage(&glmessage); 37} 38 39}; 40}; 41