OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 877 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
888 | 888 |
889 MatlabEngine::MatlabEngine() | 889 MatlabEngine::MatlabEngine() |
890 : | 890 : |
891 _critSect(CriticalSectionWrapper::CreateCriticalSection()), | 891 _critSect(CriticalSectionWrapper::CreateCriticalSection()), |
892 _eventPtr(NULL), | 892 _eventPtr(NULL), |
893 _running(false), | 893 _running(false), |
894 _numPlots(0) | 894 _numPlots(0) |
895 { | 895 { |
896 _eventPtr = EventWrapper::Create(); | 896 _eventPtr = EventWrapper::Create(); |
897 | 897 |
898 _plotThread = ThreadWrapper::CreateThread(MatlabEngine::PlotThread, this, | 898 _plotThread = PlatformThread::CreateThread(MatlabEngine::PlotThread, this, |
899 kLowPriority, "MatlabPlot"); | 899 kLowPriority, "MatlabPlot"); |
900 _running = true; | 900 _running = true; |
901 _plotThread->Start(); | 901 _plotThread->Start(); |
902 } | 902 } |
903 | 903 |
904 MatlabEngine::~MatlabEngine() | 904 MatlabEngine::~MatlabEngine() |
905 { | 905 { |
906 _critSect->Enter(); | 906 _critSect->Enter(); |
907 | 907 |
908 if (_plotThread) | 908 if (_plotThread) |
909 { | 909 { |
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1046 { | 1046 { |
1047 engClose(ep); | 1047 engClose(ep); |
1048 ep = NULL; | 1048 ep = NULL; |
1049 } | 1049 } |
1050 | 1050 |
1051 return (true); | 1051 return (true); |
1052 | 1052 |
1053 } | 1053 } |
1054 | 1054 |
1055 #endif // MATLAB | 1055 #endif // MATLAB |
OLD | NEW |