Chromium Code Reviews| 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/gles2_cmd_decoder.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
| 6 | 6 |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <list> | 10 #include <list> |
| (...skipping 2835 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2846 } | 2846 } |
| 2847 | 2847 |
| 2848 // } // anonymous namespace | 2848 // } // anonymous namespace |
| 2849 | 2849 |
| 2850 bool GLES2DecoderImpl::MakeCurrent() { | 2850 bool GLES2DecoderImpl::MakeCurrent() { |
| 2851 if (!context_.get() || !context_->MakeCurrent(surface_.get())) | 2851 if (!context_.get() || !context_->MakeCurrent(surface_.get())) |
| 2852 return false; | 2852 return false; |
| 2853 | 2853 |
| 2854 if (WasContextLost()) { | 2854 if (WasContextLost()) { |
| 2855 LOG(ERROR) << " GLES2DecoderImpl: Context lost during MakeCurrent."; | 2855 LOG(ERROR) << " GLES2DecoderImpl: Context lost during MakeCurrent."; |
| 2856 | |
| 2857 // Some D3D drivers cannot recover from device lost in the GPU process | |
| 2858 // sandbox. Allow a new GPU process to launch. | |
| 2859 if (workarounds().exit_on_context_lost) { | |
| 2860 LOG(ERROR) << "Exiting GPU process because some drivers cannot reset" | |
| 2861 << " a D3D device in the Chrome GPU process sandbox."; | |
|
Ken Russell (switch to Gerrit)
2013/03/27 02:04:11
Consider changing this message to be either more g
| |
| 2862 exit(1); | |
| 2863 } | |
| 2864 | |
| 2856 return false; | 2865 return false; |
| 2857 } | 2866 } |
| 2858 | 2867 |
| 2859 ProcessFinishedAsyncTransfers(); | 2868 ProcessFinishedAsyncTransfers(); |
| 2860 if (workarounds().flush_on_context_switch) | 2869 if (workarounds().flush_on_context_switch) |
| 2861 glFlush(); | 2870 glFlush(); |
| 2862 | 2871 |
| 2863 return true; | 2872 return true; |
| 2864 } | 2873 } |
| 2865 | 2874 |
| (...skipping 7597 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 10463 return error::kNoError; | 10472 return error::kNoError; |
| 10464 } | 10473 } |
| 10465 | 10474 |
| 10466 // Include the auto-generated part of this file. We split this because it means | 10475 // Include the auto-generated part of this file. We split this because it means |
| 10467 // we can easily edit the non-auto generated parts right here in this file | 10476 // we can easily edit the non-auto generated parts right here in this file |
| 10468 // instead of having to edit some template or the code generator. | 10477 // instead of having to edit some template or the code generator. |
| 10469 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 10478 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
| 10470 | 10479 |
| 10471 } // namespace gles2 | 10480 } // namespace gles2 |
| 10472 } // namespace gpu | 10481 } // namespace gpu |
| OLD | NEW |