2 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
4 // Licensed under the Flora License, Version 1.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
8 // http://floralicense.org/license/
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.
17 #include "test-gl-abstraction.h"
22 TestGlAbstraction::TestGlAbstraction()
27 TestGlAbstraction::~TestGlAbstraction() {}
29 void TestGlAbstraction::Initialize()
32 mCompileStatus = GL_TRUE;
33 mLinkStatus = GL_TRUE;
35 mGetAttribLocationResult = 0;
37 mGetStringResult = NULL;
40 mIsFramebufferResult = 0;
42 mIsRenderbufferResult = 0;
45 mVertexAttribArrayChanged = false;
47 mCheckFramebufferStatusResult = 0;
48 mNumBinaryFormats = 1;
50 mProgramBinaryLength = 0;
52 mLastAutoTextureIdUsed = 0;
54 mLastShaderIdUsed = 0;
55 mLastProgramIdUsed = 0;
56 mLastUniformIdUsed = 0;
57 mLastShaderCompiled = 0;
59 mLastBlendEquationRgb = 0;
60 mLastBlendEquationAlpha = 0;
61 mLastBlendFuncSrcRgb = 0;
62 mLastBlendFuncDstRgb = 0;
63 mLastBlendFuncSrcAlpha = 0;
64 mLastBlendFuncDstAlpha = 0;
67 mProgramUniforms1i.clear();
68 mProgramUniforms1f.clear();
69 mProgramUniforms2f.clear();
70 mProgramUniforms3f.clear();
71 mProgramUniforms4f.clear();
76 bool BlendEnabled(const Dali::TraceCallStack& callStack)
78 std::stringstream out;
80 bool blendEnabled = callStack.FindMethodAndParams("Enable", out.str());
84 bool BlendDisabled(const Dali::TraceCallStack& callStack)
86 std::stringstream out;
88 bool blendEnabled = callStack.FindMethodAndParams("Disable", out.str());