OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "gpu/command_buffer/service/context_state.h" | 5 #include "gpu/command_buffer/service/context_state.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <cmath> | 9 #include <cmath> |
10 | 10 |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 | 215 |
216 ContextState::ContextState(FeatureInfo* feature_info, | 216 ContextState::ContextState(FeatureInfo* feature_info, |
217 ErrorStateClient* error_state_client, | 217 ErrorStateClient* error_state_client, |
218 Logger* logger) | 218 Logger* logger) |
219 : active_texture_unit(0), | 219 : active_texture_unit(0), |
220 bound_renderbuffer_valid(false), | 220 bound_renderbuffer_valid(false), |
221 pack_reverse_row_order(false), | 221 pack_reverse_row_order(false), |
222 ignore_cached_state(false), | 222 ignore_cached_state(false), |
223 fbo_binding_for_scissor_workaround_dirty(false), | 223 fbo_binding_for_scissor_workaround_dirty(false), |
224 framebuffer_srgb_(false), | 224 framebuffer_srgb_(false), |
225 max_vertex_attribs_(0), | |
226 feature_info_(feature_info), | 225 feature_info_(feature_info), |
227 error_state_(ErrorState::Create(error_state_client, logger)) { | 226 error_state_(ErrorState::Create(error_state_client, logger)) { |
228 Initialize(); | 227 Initialize(); |
229 } | 228 } |
230 | 229 |
231 ContextState::~ContextState() { | 230 ContextState::~ContextState() { |
232 } | 231 } |
233 | 232 |
234 void ContextState::RestoreTextureUnitBindings( | 233 void ContextState::RestoreTextureUnitBindings( |
235 GLuint unit, const ContextState* prev_state) const { | 234 GLuint unit, const ContextState* prev_state) const { |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
703 UpdateUnpackParameters(); | 702 UpdateUnpackParameters(); |
704 } | 703 } |
705 | 704 |
706 // Include the auto-generated part of this file. We split this because it means | 705 // Include the auto-generated part of this file. We split this because it means |
707 // we can easily edit the non-auto generated parts right here in this file | 706 // we can easily edit the non-auto generated parts right here in this file |
708 // instead of having to edit some template or the code generator. | 707 // instead of having to edit some template or the code generator. |
709 #include "gpu/command_buffer/service/context_state_impl_autogen.h" | 708 #include "gpu/command_buffer/service/context_state_impl_autogen.h" |
710 | 709 |
711 } // namespace gles2 | 710 } // namespace gles2 |
712 } // namespace gpu | 711 } // namespace gpu |
OLD | NEW |