Home
last modified time | relevance | path

Searched refs:std (Results 1 – 25 of 174) sorted by relevance

1234567

/cts/apps/CtsVerifier/include/colorchecker/
Dcolorcheckertest.h42 const std::vector<std::vector<Vec2f> >* getCheckerCenterAdd() const { in getCheckerCenterAdd()
43 std::vector<std::vector<Vec2f> >* returnPositions = in getCheckerCenterAdd()
44 new std::vector<std::vector<Vec2f> >( in getCheckerCenterAdd()
45 4, std::vector<Vec2f>(6, Vec2f(0.f, 0.f))); in getCheckerCenterAdd()
55 const std::vector<std::vector<float> >* getCheckerRadiusAdd() const { in getCheckerRadiusAdd()
56 std::vector<std::vector<float> >* returnRadius= in getCheckerRadiusAdd()
57 new std::vector<std::vector<float> >( in getCheckerRadiusAdd()
58 4, std::vector<float>(6, 0.f)); in getCheckerRadiusAdd()
80 void findCheckerBoards(std::vector<std::vector<int> > linesDir1,
81 std::vector<std::vector<int> > linesDir2);
[all …]
Dmeteringtest.h35 void addDataToList(const std::vector<Vec3f>* checkerColors) { in addDataToList()
44 const std::vector<bool>* getComparisonResults() const { in getComparisonResults()
49 bool isDarkerThan(const std::vector<Vec3f>* checkerColors1,
50 const std::vector<Vec3f>* checkerColors2) const;
51 bool isEquivalentTo(const std::vector<Vec3f>* checkerColors1,
52 const std::vector<Vec3f>* checkerColors2) const;
54 std::vector<std::vector<Vec3f> > mCheckerColors;
55 std::vector<bool> mComparisonResults;
Dautolocktest.h31 void addDataToList(const std::vector<Vec3f>* checkerColors) { in addDataToList()
40 const std::vector<bool>* getComparisonResults() const { in getComparisonResults()
45 bool IsBrighterThan(const std::vector<Vec3f>* colorCheckers1,
46 const std::vector<Vec3f>* colorCheckers2) const;
47 bool IsEquivalentTo(const std::vector<Vec3f>* colorCheckers1,
48 const std::vector<Vec3f>* colorCheckers2) const;
50 std::vector<std::vector<Vec3f> > mCheckerColors;
51 std::vector<bool> mComparisonResults;
Dexposurecompensationtest.h38 const std::vector<Vec3f>* checkerColors) { in addDataToList()
52 std::vector<std::vector<Vec3f> > mCheckerColors;
53 std::vector<Vec3i> mReferenceColors;
54 std::vector<float> mExposureValues;
/cts/tests/tests/binder_ndk/libbinder_ndk_test/
Ditest_impl.h52 ::ndk::ScopedAStatus GetName(std::string* _aidl_return) override { in GetName()
75 std::mutex mCachedMutex;
76 std::condition_variable mCachedCondition;
82 std::unique_lock<std::mutex> l(mCachedMutex); in CacheCallingInfoFromOneway()
92 std::unique_lock<std::mutex> l(mCachedMutex); in GiveMeMyCallingPidFromOneway()
100 std::unique_lock<std::mutex> l(mCachedMutex); in GiveMeMyCallingUidFromOneway()
165 const std::shared_ptr<IEmpty>& in_value, in RepeatInterface()
166 std::shared_ptr<IEmpty>* _aidl_return) override { in RepeatInterface()
171 const std::shared_ptr<IEmpty>& in_value, in RepeatNullableInterface()
172 std::shared_ptr<IEmpty>* _aidl_return) override { in RepeatNullableInterface()
[all …]
Dtest_native_aidl_client.cpp67 std::shared_ptr<MyTest> test = SharedRefBase::make<MyTest>(); in TEST_F()
75 bool res = std::is_same<FixedSize::fixed_size, std::true_type>::value; in TEST_F()
80 bool res = std::is_same<RegularPolygon::fixed_size, std::true_type>::value; in TEST_F()
85 std::shared_ptr<ITest> iface;
88 std::string expectedName;
104 std::string name; in TEST_P()
129 bool ReadFdToString(int fd, std::string* content) { in ReadFdToString()
138 std::string dumpToString(std::shared_ptr<ITest> itest, std::vector<const char*> args) { in dumpToString()
145 std::string ret; in dumpToString()
152 auto getCompatTest(std::shared_ptr<ITest> itest) { in getCompatTest()
[all …]
/cts/tests/tests/jni/libjnitest/
Dandroid_jni_cts_LinkerNamespacesTest.cpp51 static const std::string kSystemLibraryPath = "/system/" LIB_DIR;
52 static const std::string kVendorLibraryPath = "/vendor/" LIB_DIR;
53 static const std::string kProductLibraryPath = "/product/" LIB_DIR;
57 static const std::vector<std::string> kApexLibraryPaths = {
64 static const std::vector<std::regex> kSystemPathRegexes = {
65 std::regex("/system/lib(64)?"),
66 std::regex("/apex/com\\.android\\.[^/]*/lib(64)?"),
67std::regex("/system/(lib/arm|lib64/arm64)"), // when CTS runs in ARM ABI on non-ARM CPU. http://b/…
72 static const std::vector<std::string> kOtherLoadableLibrariesInSearchPaths = {
81 static const std::string kWebViewPlatSupportLib = "libwebviewchromium_plat_support.so";
[all …]
/cts/hostsidetests/securitybulletin/securityPatch/CVE-2020-0213/
Dpoc.cpp35 using std::chrono_literals::operator""ms;
42 void workDone(const std::shared_ptr<android::Codec2Client::Component> &component,
43 std::unique_ptr<C2Work> &work, std::list<uint64_t> &flushedIndices,
44 std::mutex &queueLock, std::condition_variable &queueCondition,
45 std::list<std::unique_ptr<C2Work>> &workQueue, bool &eos, bool &csd,
56 explicit LinearBuffer(const std::shared_ptr<C2LinearBlock> &block) in LinearBuffer()
59 explicit LinearBuffer(const std::shared_ptr<C2LinearBlock> &block, size_t size) in LinearBuffer()
70 const std::function<void(std::list<std::unique_ptr<C2Work>> &workItems)> fn = nullptr) in CodecListener()
72 virtual void onWorkDone(const std::weak_ptr<android::Codec2Client::Component> &comp, in onWorkDone()
73 std::list<std::unique_ptr<C2Work>> &workItems) override { in onWorkDone()
[all …]
/cts/tests/tests/view/jni/
Dandroid_view_cts_ChoreographerNativeTest.cpp43 using namespace std::chrono_literals;
45 static constexpr std::chrono::nanoseconds NOMINAL_VSYNC_PERIOD{16ms};
46 static constexpr std::chrono::nanoseconds DELAY_PERIOD{NOMINAL_VSYNC_PERIOD * 5};
47 static constexpr std::chrono::nanoseconds ZERO{std::chrono::nanoseconds::zero()};
56 static std::mutex gLock;
57 static std::set<int64_t> gSupportedRefreshPeriods;
60 std::string name;
62 std::chrono::nanoseconds frameTime{0LL};
67 std::string name;
69 std::chrono::nanoseconds vsyncPeriod{0LL};
[all …]
Dandroid_view_cts_InputDeviceKeyLayoutMapTest.cpp39 std::map<int, std::string> loadGenericKl(std::string genericKl) { in loadGenericKl()
40 std::map<int, std::string> result; in loadGenericKl()
41 std::istringstream ssFile(genericKl); in loadGenericKl()
43 for (std::string line; std::getline(ssFile, line);) { in loadGenericKl()
49 std::string type, code, label, flags; in loadGenericKl()
50 std::istringstream ssLine(line); in loadGenericKl()
68 result.emplace(std::stoi(code), label); in loadGenericKl()
79 std::map<int, std::string> map = loadGenericKl(keyLayout.c_str()); in android_view_cts_nativeLoadKeyLayout()
/cts/tests/tests/media/libaudiojni/
DGate.h63 std::unique_lock<std::mutex> l(mLock); in wait()
76 std::lock_guard<std::mutex> l(mLock); in closeGate()
84 std::lock_guard<std::mutex> l(mLock); in openGate()
97 std::lock_guard<std::mutex> l(mLock); in terminate()
106 std::lock_guard<std::mutex> l(mLock); in isOpen()
112 std::lock_guard<std::mutex> l(mLock); in waiters()
121 std::condition_variable mCondition;
122 std::mutex mLock;
/cts/tests/tests/libthermalndk/jni/
DNativeThermalTest.cpp40 using namespace std::chrono_literals;
45 std::mutex mMutex;
46 std::condition_variable mCv;
47 std::vector<AThermalStatus> mListenerStatus GUARDED_BY(mMutex);
58 std::lock_guard<std::mutex> guard(ctx->mMutex); in onStatusChange()
68 static inline jstring returnJString(JNIEnv *env, std::optional<std::string> result) { in returnJString()
76 static std::optional<std::string> testGetCurrentThermalStatus( in testGetCurrentThermalStatus()
97 return std::nullopt; in testGetCurrentThermalStatus()
104 static std::optional<std::string> testRegisterThermalStatusListener(JNIEnv *env, jobject obj) { in testRegisterThermalStatusListener()
106 std::unique_lock<std::mutex> lock(ctx.mMutex); in testRegisterThermalStatusListener()
[all …]
/cts/tests/tests/nativemedia/aaudio/jni/
Dtest_aaudio_callback.cpp61 using CbTestParams = std::tuple<aaudio_sharing_mode_t, int32_t,
95 static std::string getTestName(const ::testing::TestParamInfo<CbTestParams>& info) { in getTestName()
96 return std::string() in getTestName()
97 + sharingModeToString(std::get<PARAM_SHARING_MODE>(info.param)) in getTestName()
98 + "__" + std::to_string(std::get<PARAM_FRAMES_PER_CB>(info.param)) in getTestName()
99 + "__" + performanceModeToString(std::get<PARAM_PERF_MODE>(info.param)) in getTestName()
100 + "__" + allowMMapToString(std::get<PARAM_ALLOW_MMAP>(info.param)) in getTestName()
101 + "__" + audioFormatToString(std::get<PARAM_AUDIO_FORMAT>(info.param)) in getTestName()
113 std::atomic<aaudio_result_t> callbackError;
114 std::atomic<int32_t> callbackCount;
[all …]
Dtest_aaudio_stream_builder.cpp151 static std::string getTestName(const ::testing::TestParamInfo<int32_t>& info) { in getTestName()
152 return info.param >= 0 ? std::to_string(info.param) : "_" + std::to_string(-info.param); in getTestName()
187 static std::string getTestName(const ::testing::TestParamInfo<int32_t>& info) { in getTestName()
188 return info.param >= 0 ? std::to_string(info.param) : "_" + std::to_string(-info.param); in getTestName()
215 static std::string getTestName(const ::testing::TestParamInfo<aaudio_format_t>& info) { in getTestName()
216 return info.param >= 0 ? std::to_string(info.param) : "_" + std::to_string(-info.param); in getTestName()
249 static std::string getTestName(const ::testing::TestParamInfo<aaudio_sharing_mode_t>& info) { in getTestName()
250 return info.param >= 0 ? std::to_string(info.param) : "_" + std::to_string(-info.param); in getTestName()
277 static std::string getTestName(const ::testing::TestParamInfo<aaudio_direction_t>& info) { in getTestName()
278 return info.param >= 0 ? std::to_string(info.param) : "_" + std::to_string(-info.param); in getTestName()
[all …]
Dtest_aaudio.cpp32 using StreamTestParams = std::tuple<aaudio_sharing_mode_t, aaudio_performance_mode_t>;
42 static std::string getTestName(const ::testing::TestParamInfo<StreamTestParams>& info) { in getTestName()
43 return std::string() + sharingModeToString(std::get<PARAM_SHARING_MODE>(info.param)) + in getTestName()
44 "__" + performanceModeToString(std::get<PARAM_PERF_MODE>(info.param)); in getTestName()
171 maxLatencyNanos = std::max(maxLatencyNanos, latencyNanos); in testTimestamp()
172 minLatencyNanos = std::min(minLatencyNanos, latencyNanos); in testTimestamp()
191 std::unique_ptr<T> mHelper;
194 std::unique_ptr<int16_t[]> mShortData;
195 std::unique_ptr<float[]> mFloatData;
212 std::get<PARAM_SHARING_MODE>(GetParam()), in SetUp()
[all …]
/cts/suite/audio_quality/lib/src/task/
DTaskSave.cpp55 std::unique_ptr<std::vector<android::String8> > list(StringUtil::split(fileValue, ',')); in handleFile()
56 std::vector<android::String8>* listp = list.get(); in handleFile()
79 std::unique_ptr<std::list<TaskCase::BufferPair> > buffers( in handleFile()
81 std::list<TaskCase::BufferPair>* buffersp = buffers.get(); in handleFile()
86 std::list<TaskCase::BufferPair>::iterator it = buffersp->begin(); in handleFile()
87 std::list<TaskCase::BufferPair>::iterator end = buffersp->end(); in handleFile()
108 std::unique_ptr<std::vector<android::String8> > list(StringUtil::split(reportValue, ',')); in handleReport()
109 std::vector<android::String8>* listp = list.get(); in handleReport()
117 std::unique_ptr<std::list<TaskCase::ValuePair> > values( in handleReport()
119 std::list<TaskCase::ValuePair>* valuesp = values.get(); in handleReport()
[all …]
/cts/suite/audio_quality/lib/include/task/
DTaskProcess.h42 bool parseParams(std::vector<Param>& list, const char* str, bool isInput);
45 typedef std::unique_ptr<TaskCase::Value> UniqueValue;
46 typedef std::unique_ptr<android::sp<Buffer> > UniqueBuffer;
49 bool prepareParams(std::vector<TaskProcess::Param>& list,
51 std::unique_ptr<void_ptr[]>& ptrs,
52 std::unique_ptr<UniqueValue[]>& values,
53 std::unique_ptr<UniqueBuffer[]>& buffers,
86 std::vector<Param> mInput;
87 std::vector<Param> mOutput;
89 std::unique_ptr<SignalProcessingInterface> mSp;
/cts/hostsidetests/gputools/apps/jni/
Dandroid_gputools_cts_RootlessGpuDebug.cpp42 std::string initVulkan() { in initVulkan()
43 std::stringstream result; in initVulkan()
49 std::vector<VkExtensionProperties> properties(count); in initVulkan()
91 std::string initGLES() { in initGLES()
92 std::string result = ""; in initGLES()
107 std::string display_extensions = eglQueryString(EGL_NO_DISPLAY, EGL_EXTENSIONS); in initGLES()
108 if (display_extensions.find("EGL_ANDROID_GLES_layers") == std::string::npos) in initGLES()
115 result = "eglGetDisplay() returned error " + std::to_string(eglGetError()); in initGLES()
120 result = "eglInitialize() returned error " + std::to_string(eglGetError()); in initGLES()
126 "eglChooseConfig() returned error " + std::to_string(eglGetError()); in initGLES()
[all …]
/cts/hostsidetests/jvmti/base/jni/
Dredefine.cpp70 void PushRedefinition(std::string name, std::vector<unsigned char> data) { in PushRedefinition()
72 std::stack<std::vector<unsigned char>> stack; in PushRedefinition()
73 redefinitions_[name] = std::move(stack); in PushRedefinition()
75 redefinitions_[name].push(std::move(data)); in PushRedefinition()
78 bool RetrieveRedefinition(std::string name, /*out*/std::vector<unsigned char>* data) { in RetrieveRedefinition()
88 void PopRedefinition(std::string name) { in PopRedefinition()
100 std::unordered_map<std::string, std::stack<std::vector<unsigned char>>> redefinitions_;
117 std::string name_str(name); in CommonClassFileLoadHookRetransformable()
118 std::vector<unsigned char> dex_data; in CommonClassFileLoadHookRetransformable()
166 std::string name_str(name_chrs); in Java_android_jvmti_cts_JvmtiRedefineClassesTest_pushTransformationResult()
[all …]
Dtracking.cpp32 static std::string GetClassName(JNIEnv* jni_env, jclass cls) { in GetClassName()
41 static std::mutex gLock;
42 static std::string gCollection;
50 std::string object_klass_descriptor = GetClassName(jni_env, object_klass); in ObjectAllocated()
52 std::string object_klass_descriptor2 = GetClassName(jni_env, object_klass2.get()); in ObjectAllocated()
53 std::string result = android::base::StringPrintf("ObjectAllocated type %s/%s size %zu", in ObjectAllocated()
57 std::unique_lock<std::mutex> mu(gLock); in ObjectAllocated()
84 std::string result; in Java_android_jvmti_cts_JvmtiTrackingTest_getAndResetAllocationTrackingString()
86 std::unique_lock<std::mutex> mu(gLock); in Java_android_jvmti_cts_JvmtiTrackingTest_getAndResetAllocationTrackingString()
94 std::unique_lock<std::mutex> mu(gLock); in Java_android_jvmti_cts_JvmtiTrackingTest_getAndResetAllocationTrackingString()
/cts/common/device-side/nativetesthelper/jni/
Dgtest_wrapper.cpp69 std::string nativeName;
73 std::unordered_map<std::string, TestNameInfo> gNativeTestNames;
77 std::string registerAndMangleTestName(const std::string& nativeName) { in registerAndMangleTestName()
78 std::string mangledName = nativeName; in registerAndMangleTestName()
79 std::replace(mangledName.begin(), mangledName.end(), '.', '_'); in registerAndMangleTestName()
80 std::replace(mangledName.begin(), mangledName.end(), '/', '_'); in registerAndMangleTestName()
81 gNativeTestNames.insert(std::make_pair(mangledName, TestNameInfo{nativeName, false})); in registerAndMangleTestName()
86 jobject createTestDescription(JNIEnv* env, jstring className, const std::string& mangledName) { in createTestDescription()
93 std::ostringstream nativeNameStream; in createTestDescription()
95 std::string mangledName = registerAndMangleTestName(nativeNameStream.str()); in createTestDescription()
[all …]
/cts/hostsidetests/jvmti/attaching/app/jni/
Dcts_agent.cpp31 static std::mutex gVectorMutex;
32 static std::vector<std::string> gLoadedDescriptors;
34 static std::string GetClassName(jvmtiEnv* jenv, JNIEnv* jni_env, jclass klass) { in GetClassName()
46 std::string tmp(name); in GetClassName()
95 std::string name = GetClassName(jenv, jni_env, klass); in ClassPrepareCallback()
99 std::lock_guard<std::mutex> guard(gVectorMutex); in ClassPrepareCallback()
105 std::lock_guard<std::mutex> guard(gVectorMutex); in Java_android_jvmti_JvmtiActivity_didSeeLoadOf()
107 std::string tmp = str.c_str(); in Java_android_jvmti_JvmtiActivity_didSeeLoadOf()
108 bool found = std::find(gLoadedDescriptors.begin(), gLoadedDescriptors.end(), tmp) != in Java_android_jvmti_JvmtiActivity_didSeeLoadOf()
/cts/hostsidetests/graphics/gpuprofiling/app/
Dandroid_graphics_cts_GpuCounters.cpp57 std::string libDir = sizeof(void *) == 8 ? "lib64" : "lib"; in startCounterProducer()
58 std::string producerPath = "/vendor/" + libDir + "/libgpudataproducer.so"; in startCounterProducer()
87 volatile std::sig_atomic_t done = 0;
92 std::signal(SIGTERM, [](int /*signal*/) { in main()
96 std::thread dummy([&]() { in main()
102 std::this_thread::sleep_for(std::chrono::milliseconds(100)); in main()
/cts/tests/tests/nativemedia/resourceobserver/src/
DResourceObserverNativeTest.cpp41 static std::string toString(const MediaObservableParcel& observable) { in toString()
43 std::to_string(observable.value) + "}"; in toString()
55 std::vector<MediaObservableParcel> observables;
63 const std::vector<MediaObservableParcel>& observables) override { in onStatusChanged()
67 std::scoped_lock lock{mLock}; in onStatusChanged()
79 std::unique_lock lock{mLock}; in waitForEvent()
81 mCondition.wait_for(lock, std::chrono::microseconds(timeoutUs)); in waitForEvent()
90 std::mutex mLock;
91 std::condition_variable mCondition;
98 std::shared_ptr<IResourceObserverService> service = in testResourceObserver()
[all …]
/cts/suite/audio_quality/lib/include/
DReport.h51 typedef std::pair<android::String8, android::String8> StringPair;
52 void writeResult(std::list<StringPair>::const_iterator begin,
53 std::list<StringPair>::const_iterator end, bool passed);
57 std::list<StringPair> mPassedCases;
58 std::list<StringPair> mFailedCases;

1234567