/third_party/openssl/crypto/evp/ |
D | evp_rand.c | 54 EVP_RAND *rand = (EVP_RAND *)vrand; in evp_rand_up_ref() local 57 if (rand != NULL) in evp_rand_up_ref() 58 return CRYPTO_UP_REF(&rand->refcnt, &ref, rand->refcnt_lock); in evp_rand_up_ref() 64 EVP_RAND *rand = (EVP_RAND *)vrand; in evp_rand_free() local 67 if (rand == NULL) in evp_rand_free() 69 CRYPTO_DOWN_REF(&rand->refcnt, &ref, rand->refcnt_lock); in evp_rand_free() 72 OPENSSL_free(rand->type_name); in evp_rand_free() 73 ossl_provider_free(rand->prov); in evp_rand_free() 74 CRYPTO_THREAD_lock_free(rand->refcnt_lock); in evp_rand_free() 75 OPENSSL_free(rand); in evp_rand_free() [all …]
|
/third_party/node/deps/openssl/openssl/crypto/evp/ |
D | evp_rand.c | 54 EVP_RAND *rand = (EVP_RAND *)vrand; in evp_rand_up_ref() local 57 if (rand != NULL) in evp_rand_up_ref() 58 return CRYPTO_UP_REF(&rand->refcnt, &ref, rand->refcnt_lock); in evp_rand_up_ref() 64 EVP_RAND *rand = (EVP_RAND *)vrand; in evp_rand_free() local 67 if (rand == NULL) in evp_rand_free() 69 CRYPTO_DOWN_REF(&rand->refcnt, &ref, rand->refcnt_lock); in evp_rand_free() 72 OPENSSL_free(rand->type_name); in evp_rand_free() 73 ossl_provider_free(rand->prov); in evp_rand_free() 74 CRYPTO_THREAD_lock_free(rand->refcnt_lock); in evp_rand_free() 75 OPENSSL_free(rand); in evp_rand_free() [all …]
|
/third_party/skia/tools/ |
D | random_parse_path.cpp | 32 static void add_white(SkRandom* rand, SkString* atom) { in add_white() argument 37 int reps = rand->nextRangeU(0, 2); in add_white() 39 int index = rand->nextRangeU(0, (int) SK_ARRAY_COUNT(gWhiteSpace) - 1); in add_white() 46 static void add_comma(SkRandom* rand, SkString* atom) { in add_comma() argument 52 add_white(rand, atom); in add_comma() 53 if (rand->nextBool()) { in add_comma() 57 add_white(rand, atom); in add_comma() 61 static void add_some_white(SkRandom* rand, SkString* atom) { in add_some_white() argument 64 add_white(rand, atom); in add_some_white() 68 SkString MakeRandomParsePathPiece(SkRandom* rand) { in MakeRandomParsePathPiece() argument [all …]
|
/third_party/skia/gm/ |
D | beziers.cpp | 23 static SkPath rnd_quad(SkPaint* paint, SkRandom& rand) { in rnd_quad() argument 24 auto a = rand.nextRangeScalar(0,W), in rnd_quad() 25 b = rand.nextRangeScalar(0,H); in rnd_quad() 30 auto c = rand.nextRangeScalar(W/4, W), in rnd_quad() 31 d = rand.nextRangeScalar( 0, H), in rnd_quad() 32 e = rand.nextRangeScalar( 0, W), in rnd_quad() 33 f = rand.nextRangeScalar(H/4, H); in rnd_quad() 36 paint->setColor(rand.nextU()); in rnd_quad() 37 SkScalar width = rand.nextRangeScalar(1, 5); in rnd_quad() 44 static SkPath rnd_cubic(SkPaint* paint, SkRandom& rand) { in rnd_cubic() argument [all …]
|
D | manypaths.cpp | 22 static SkColor gen_color(SkRandom* rand) { in gen_color() argument 24 hsv[0] = rand->nextRangeF(0.0f, 360.0f); in gen_color() 25 hsv[1] = rand->nextRangeF(0.5f, 1.0f); in gen_color() 26 hsv[2] = rand->nextRangeF(0.5f, 1.0f); in gen_color() 52 SkRandom rand(1); in onDraw() local 57 SkScalar x = rand.nextF() * kWidth - 100; in onDraw() 58 SkScalar y = rand.nextF() * kHeight - 100; in onDraw() 59 SkScalar w = rand.nextF() * 200; in onDraw() 61 paint.setColor(gen_color(&rand)); in onDraw() 91 SkRandom rand(1); in onDraw() local
|
D | strokerects.cpp | 40 static void rnd_rect(SkRect* r, SkRandom& rand) { in rnd_rect() argument 41 SkScalar x = rand.nextUScalar1() * W; in rnd_rect() 42 SkScalar y = rand.nextUScalar1() * H; in rnd_rect() 43 SkScalar w = rand.nextUScalar1() * (W >> 2); in rnd_rect() 44 SkScalar h = rand.nextUScalar1() * (H >> 2); in rnd_rect() 45 SkScalar hoffset = rand.nextSScalar1(); in rnd_rect() 46 SkScalar woffset = rand.nextSScalar1(); in rnd_rect() 68 SkRandom rand; in onDraw() local 71 rnd_rect(&r, rand); in onDraw()
|
/third_party/skia/samplecode/ |
D | SampleHairCurves.cpp | 27 SkRandom rand; in onDrawContent() local 34 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 35 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 36 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 37 rand.nextUScalar1(), rand.nextUScalar1() in onDrawContent() 56 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 57 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 58 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 74 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() 75 rand.nextUScalar1(), rand.nextUScalar1(), in onDrawContent() [all …]
|
D | SampleClip.cpp | 22 SkRandom rand; in show_text() local 28 paint.setColor((SK_A32_MASK << SK_A32_SHIFT) | rand.nextU()); in show_text() 29 canvas->drawString("Hamburgefons", rand.nextSScalar1() * W, rand.nextSScalar1() * H + 20, in show_text() 35 SkRandom rand; in show_fill() local 42 r.setXYWH(rand.nextSScalar1() * W, rand.nextSScalar1() * H, in show_fill() 43 rand.nextUScalar1() * W, rand.nextUScalar1() * H); in show_fill() 44 paint.setColor(rand.nextU()); in show_fill() 47 r.setXYWH(rand.nextSScalar1() * W, rand.nextSScalar1() * H, in show_fill() 48 rand.nextUScalar1() * W, rand.nextUScalar1() * H); in show_fill() 49 paint.setColor(rand.nextU()); in show_fill() [all …]
|
/third_party/skia/bench/ |
D | StrokeBench.cpp | 56 static SkPoint rand_pt(SkRandom& rand) { in rand_pt() argument 57 return SkPoint::Make(rand.nextSScalar1() * X, rand.nextSScalar1() * Y); in rand_pt() 62 SkRandom rand; in line_path_maker() local 63 path.moveTo(rand_pt(rand)); in line_path_maker() 65 path.lineTo(rand_pt(rand)); in line_path_maker() 71 SkRandom rand; in quad_path_maker() local 72 path.moveTo(rand_pt(rand)); in quad_path_maker() 74 path.quadTo(rand_pt(rand), rand_pt(rand)); in quad_path_maker() 80 SkRandom rand; in conic_path_maker() local 81 path.moveTo(rand_pt(rand)); in conic_path_maker() [all …]
|
D | RTreeBench.cpp | 39 SkRandom rand; in onDraw() local 42 rects[i] = fProc(rand, i, NUM_BUILD_RECTS); in onDraw() 72 SkRandom rand; in onDelayedSetup() local 75 rects[i] = fProc(rand, i, NUM_QUERY_RECTS); in onDelayedSetup() 81 SkRandom rand; in onDraw() local 85 query.fLeft = rand.nextRangeF(0, GENERATE_EXTENTS); in onDraw() 86 query.fTop = rand.nextRangeF(0, GENERATE_EXTENTS); in onDraw() 87 query.fRight = query.fLeft + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/2); in onDraw() 88 query.fBottom = query.fTop + 1 + rand.nextRangeF(0, GENERATE_EXTENTS/2); in onDraw() 99 static inline SkRect make_XYordered_rects(SkRandom& rand, int index, int numRects) { in make_XYordered_rects() argument [all …]
|
D | TessellateBench.cpp | 47 SkRandom rand; in make_cubic_path() local 50 float x = std::ldexp(rand.nextF(), (i % maxPow2)) / 1e3f; in make_cubic_path() 58 SkRandom rand; in make_conic_path() local 62 const float x = std::ldexp(rand.nextF(), (i % 18)) / 1e3f; in make_conic_path() 63 const float w = std::ldexp(1 + rand.nextF(), j); in make_conic_path() 71 SkRandom rand; in make_quad_path() local 74 float x = std::ldexp(rand.nextF(), (i % maxPow2)) / 1e3f; in make_quad_path() 81 SkRandom rand; in make_line_path() local 84 float x = std::ldexp(rand.nextF(), (i % maxPow2)) / 1e3f; in make_line_path() 274 SkRandom rand; in make_motionmark_paths() local [all …]
|
D | PicturePlaybackBench.cpp | 54 SkRandom rand; in onDelayedSetup() local 56 SkScalar x = rand.nextRangeScalar(0, 1024), in onDelayedSetup() 57 y = rand.nextRangeScalar(0, 1024), in onDelayedSetup() 58 w = rand.nextRangeScalar(0, 128), in onDelayedSetup() 59 h = rand.nextRangeScalar(0, 128); in onDelayedSetup() 61 paint.setColor(rand.nextU()); in onDelayedSetup() 71 SkRandom rand; in onDraw() local 75 case kTiled: x = SkScalar(256 * rand.nextULessThan(4)); in onDraw() 76 y = SkScalar(256 * rand.nextULessThan(4)); in onDraw() 78 case kRandom: x = rand.nextRangeScalar(0, 768); in onDraw() [all …]
|
D | HairlinePathBench.cpp | 89 SkRandom rand; in makePath() local 98 int base1 = 2 * rand.nextULessThan(hSize); in makePath() 99 int base2 = 2 * rand.nextULessThan(hSize); in makePath() 100 int base3 = 2 * rand.nextULessThan(hSize); in makePath() 121 SkRandom rand; in makePath() local 130 int base1 = 2 * rand.nextULessThan(hSize); in makePath() 131 int base2 = 2 * rand.nextULessThan(hSize); in makePath() 132 int base3 = 2 * rand.nextULessThan(hSize); in makePath() 153 SkRandom rand; in makePath() local 163 int base1 = 2 * rand.nextULessThan(hSize); in makePath() [all …]
|
D | PathBench.cpp | 268 SkRandom rand (12); in makePath() local 271 path->quadTo(rand.nextUScalar1() * 640, rand.nextUScalar1() * 480, in makePath() 272 rand.nextUScalar1() * 640, rand.nextUScalar1() * 480); in makePath() 289 SkRandom rand; in makePath() local 290 path->moveTo(rand.nextUScalar1() * 640, rand.nextUScalar1() * 480); in makePath() 292 path->lineTo(rand.nextUScalar1() * 640, rand.nextUScalar1() * 480); in makePath() 677 SkRandom rand; in onDraw() local 682 SkScalar radius = rand.nextUScalar1() * 3; in onDraw() 683 r.fLeft = rand.nextUScalar1() * 300; in onDraw() 684 r.fTop = rand.nextUScalar1() * 300; in onDraw() [all …]
|
D | Matrix44Bench.cpp | 20 SkRandom rand; in M4Bench() local 23 v = rand.nextF(); in M4Bench() 160 SkRandom rand; in MapRectBench() local 165 fM = SkM44::Translate(rand.nextF(), rand.nextF()); in MapRectBench() 169 fM = SkM44::Scale(rand.nextF(), rand.nextF()); in MapRectBench() 170 fM.postTranslate(rand.nextF(), rand.nextF()); in MapRectBench() 190 fS = SkRect::MakeXYWH(10.f * rand.nextF(), 10.f * rand.nextF(), in MapRectBench() 191 150.f * rand.nextF(), 150.f * rand.nextF()); in MapRectBench()
|
/third_party/mesa3d/src/gallium/drivers/r600/ |
D | r600_test_dma.c | 161 switch (rand() % 4) { in generate_max_tex_side() 214 bool do_partial_copies = rand() & 1; in r600_test_dma() 220 bpp = 1 << (rand() % 5); in r600_test_dma() 224 max_tex_layers = rand() % 4 ? 1 : 5; in r600_test_dma() 226 tsrc.width0 = (rand() % max_tex_side_gen) + 1; in r600_test_dma() 227 tsrc.height0 = (rand() % max_tex_side_gen) + 1; in r600_test_dma() 228 tsrc.array_size = (rand() % max_tex_layers) + 1; in r600_test_dma() 231 if (rand() % 4 == 0) { in r600_test_dma() 241 max_tex_layers = rand() % 4 ? 1 : 5; in r600_test_dma() 244 tdst.width0 = (rand() % max_tex_side_gen) + 1; in r600_test_dma() [all …]
|
/third_party/node/deps/openssl/openssl/crypto/rand/ |
D | rand_lib.c | 298 EVP_RAND_CTX *rand; in RAND_status() local 306 if ((rand = RAND_get0_primary(NULL)) == NULL) in RAND_status() 308 return EVP_RAND_get_state(rand) == EVP_RAND_STATE_READY; in RAND_status() 328 EVP_RAND_CTX *rand; in RAND_priv_bytes_ex() local 340 rand = RAND_get0_private(ctx); in RAND_priv_bytes_ex() 341 if (rand != NULL) in RAND_priv_bytes_ex() 342 return EVP_RAND_generate(rand, buf, num, strength, 0, NULL, 0); in RAND_priv_bytes_ex() 357 EVP_RAND_CTX *rand; in RAND_bytes_ex() local 369 rand = RAND_get0_public(ctx); in RAND_bytes_ex() 370 if (rand != NULL) in RAND_bytes_ex() [all …]
|
/third_party/openssl/crypto/rand/ |
D | rand_lib.c | 298 EVP_RAND_CTX *rand; in RAND_status() local 306 if ((rand = RAND_get0_primary(NULL)) == NULL) in RAND_status() 308 return EVP_RAND_get_state(rand) == EVP_RAND_STATE_READY; in RAND_status() 328 EVP_RAND_CTX *rand; in RAND_priv_bytes_ex() local 340 rand = RAND_get0_private(ctx); in RAND_priv_bytes_ex() 341 if (rand != NULL) in RAND_priv_bytes_ex() 342 return EVP_RAND_generate(rand, buf, num, strength, 0, NULL, 0); in RAND_priv_bytes_ex() 357 EVP_RAND_CTX *rand; in RAND_bytes_ex() local 369 rand = RAND_get0_public(ctx); in RAND_bytes_ex() 370 if (rand != NULL) in RAND_bytes_ex() [all …]
|
/third_party/skia/tests/ |
D | WangsFormulaTest.cpp | 82 static void for_random_matrices(SkRandom* rand, std::function<void(const SkMatrix&)> f) { in for_random_matrices() argument 89 m.setScaleX(std::ldexp(1 + rand->nextF(), i)); in for_random_matrices() 92 m.setScaleY(std::ldexp(1 + rand->nextF(), j)); in for_random_matrices() 95 m.setScaleX(std::ldexp(1 + rand->nextF(), i)); in for_random_matrices() 96 m.setSkewX(std::ldexp(1 + rand->nextF(), (j + i) / 2)); in for_random_matrices() 97 m.setSkewY(std::ldexp(1 + rand->nextF(), (j + i) / 2)); in for_random_matrices() 98 m.setScaleY(std::ldexp(1 + rand->nextF(), j)); in for_random_matrices() 104 static void for_random_beziers(int numPoints, SkRandom* rand, in for_random_beziers() argument 111 pts[j].set(std::ldexp(1 + rand->nextF(), i), std::ldexp(1 + rand->nextF(), i)); in for_random_beziers() 256 SkRandom rand; in DEF_TEST() local [all …]
|
D | RTreeTest.cpp | 16 static SkRect random_rect(SkRandom& rand) { in random_rect() argument 19 rect.fLeft = rand.nextRangeF(0, 1000); in random_rect() 20 rect.fRight = rand.nextRangeF(0, 1000); in random_rect() 21 rect.fTop = rand.nextRangeF(0, 1000); in random_rect() 22 rect.fBottom = rand.nextRangeF(0, 1000); in random_rect() 46 static void run_queries(skiatest::Reporter* reporter, SkRandom& rand, SkRect rects[], in run_queries() argument 50 SkRect query = random_rect(rand); in run_queries() 73 SkRandom rand; in DEF_TEST() local 80 rects[j] = random_rect(rand); in DEF_TEST() 86 run_queries(reporter, rand, rects, rtree); in DEF_TEST()
|
D | DrawBitmapRectTest.cpp | 27 static void rand_matrix(SkMatrix* mat, SkRandom& rand, unsigned mask) { in rand_matrix() argument 30 mat->postTranslate(rand.nextSScalar1(), rand.nextSScalar1()); in rand_matrix() 33 mat->postScale(rand.nextSScalar1(), rand.nextSScalar1()); in rand_matrix() 36 mat->postRotate(rand.nextSScalar1() * 360); in rand_matrix() 39 mat->setPerspX(rand.nextSScalar1()); in rand_matrix() 40 mat->setPerspY(rand.nextSScalar1()); in rand_matrix() 44 static void rand_size(SkISize* size, SkRandom& rand) { in rand_size() argument 45 size->set(rand.nextU() & 0xFFFF, rand.nextU() & 0xFFFF); in rand_size() 52 SkRandom rand; in test_treatAsSprite() local 62 rand_matrix(&mat, rand, SkMatrix::kTranslate_Mask); in test_treatAsSprite() [all …]
|
/third_party/openh264/test/api/ |
D | ltr_test.cpp | 28 int32_t iIDRPeriod = (int32_t) pow (2.0f, (param_.iTemporalLayerNum - 1)) * ((rand() % 5) + 1); in TEST_P() 87 memset (buf_.data(), rand() % 256, frameSize); in TEST_P() 94 m_LTR_Recover_Request.iCurrentFrameNum = rand() % 2 == 1 ? -rand() % 10000 : rand() % 10000; in TEST_P() 95 m_LTR_Recover_Request.uiIDRPicId = rand() % 2 == 1 ? -rand() % 10000 : rand() % 10000; in TEST_P() 96 m_LTR_Recover_Request.iLastCorrectFrameNum = rand() % 2 == 1 ? -rand() % 10000 : rand() % 10000; in TEST_P() 98 …m_LTR_Marking_Feedback.uiFeedbackType = rand() % 2 == 1 ? LTR_MARKING_SUCCESS : LTR_MARKING_FAILED; in TEST_P() 99 m_LTR_Marking_Feedback.uiIDRPicId = rand() % 2 == 1 ? -rand() % 10000 : rand() % 10000; in TEST_P() 100 m_LTR_Marking_Feedback.iLTRFrameNum = rand() % 2 == 1 ? -rand() % 10000 : rand() % 10000; in TEST_P()
|
D | encode_options_test.cpp | 38 iRandValue = rand() % 256; in InitialEncDec() 45 param_.iPicWidth = WelsClip3 ((((rand() % MAX_WIDTH) >> 1) + 1) << 1, 2, MAX_WIDTH); in RandomParamExtCombination() 46 param_.iPicHeight = WelsClip3 ((((rand() % MAX_HEIGHT) >> 1) + 1) << 1, 2, MAX_HEIGHT); in RandomParamExtCombination() 48 param_.fMaxFrameRate = rand() % FRAME_RATE_RANGE + 0.5f; in RandomParamExtCombination() 49 param_.iUsageType = static_cast<EUsageType> (rand() % 2); in RandomParamExtCombination() 50 param_.iTemporalLayerNum = rand() % TEMPORAL_LAYER_NUM_RANGE; in RandomParamExtCombination() 51 param_.iSpatialLayerNum = rand() % SPATIAL_LAYER_NUM_RANGE; in RandomParamExtCombination() 53 param_.uiIntraPeriod = rand() - 1; in RandomParamExtCombination() 55 param_.iMultipleThreadIdc = rand(); in RandomParamExtCombination() 57 int iValue = rand() % 7; in RandomParamExtCombination() [all …]
|
/third_party/openh264/test/encoder/ |
D | EncUT_Sample.cpp | 28 pDec[i] = rand() % 256; \ 30 pEnc[i] = rand() % 256; \ 32 pDst[i] = rand() % 256; \ 46 int32_t iPredMode = rand() % 3; \ 57 pDec[i] = rand() % 256; \ 59 pEnc[i] = rand() % 256; \ 61 pDst[i] = rand() % 256; \ 88 pDecCb[i] = rand() % 256; \ 89 pDecCr[i] = rand() % 256; \ 92 pEncCb[i] = rand() % 256; \ [all …]
|
/third_party/skia/tests/graphite/ |
D | IntersectionTreeTest.cpp | 33 SkRandom rand; in DEF_GRAPHITE_TEST() local 38 Rect rect = Rect::XYWH(rand.nextRangeF(0, 500), in DEF_GRAPHITE_TEST() 39 rand.nextRangeF(0, 500), in DEF_GRAPHITE_TEST() 40 rand.nextRangeF(0, 70), in DEF_GRAPHITE_TEST() 41 rand.nextRangeF(0, 70)); in DEF_GRAPHITE_TEST() 52 Rect rect = Rect::XYWH(rand.nextRangeF(0, 500), in DEF_GRAPHITE_TEST() 53 rand.nextRangeF(0, 500), in DEF_GRAPHITE_TEST() 54 rand.nextRangeF(0, 200), in DEF_GRAPHITE_TEST() 55 rand.nextRangeF(0, 200)); in DEF_GRAPHITE_TEST()
|