Home
last modified time | relevance | path

Searched refs:rounding (Results 1 - 25 of 113) sorted by relevance

12345

/third_party/decimal.js/test/modules/
H A DtoNearest.js11 rounding: 4,
141 Decimal.rounding = 0;
144 Decimal.rounding = 1;
193 Decimal.rounding = 0;
195 Decimal.rounding = 1;
197 Decimal.rounding = 2;
199 Decimal.rounding = 3;
201 Decimal.rounding = 4;
203 Decimal.rounding = 5;
205 Decimal.rounding
[all...]
H A Dconfig.js18 rounding {number} [0, 8]
39 rounding: 4,
49 t(Decimal.rounding === 4);
59 rounding : 4,
69 t(Decimal.rounding === 4);
127 // rounding
131 T.assertEqual(expected, Decimal.rounding);
134 t(4, {rounding: void 0});
135 t(0, {rounding: 0});
136 t(1, {rounding
[all...]
H A DtoSD.js15 rounding: 7,
45 Decimal.rounding = 0;
48 Decimal.rounding = 1;
51 Decimal.rounding = 2;
54 Decimal.rounding = 3;
57 Decimal.rounding = 4;
60 Decimal.rounding = 5;
63 Decimal.rounding = 6;
66 Decimal.rounding = 7;
69 Decimal.rounding
[all...]
H A Dclone.js11 rounding: 4,
113 rounding: 2,
120 t(Decimal.rounding === 2);
128 t(D1.rounding === 4);
133 D2 = Decimal.clone({ defaults: true, rounding: 5 });
136 t(D2.rounding === 5);
142 t(D3.rounding === 2);
H A DtoFixed.js15 rounding: 4,
110 Decimal.rounding = 0;
154 Decimal.rounding = 1;
195 Decimal.rounding = 2;
238 Decimal.rounding = 3;
281 Decimal.rounding = 4;
324 Decimal.rounding = 5;
362 Decimal.rounding = 6;
406 Decimal.rounding = 4;
513 Decimal.rounding
[all...]
H A DtoExponential.js15 rounding: 4,
110 Decimal.rounding = 0;
161 Decimal.rounding = 1;
213 Decimal.rounding = 2;
261 Decimal.rounding = 3;
316 Decimal.rounding = 4;
369 Decimal.rounding = 5;
422 Decimal.rounding = 6;
471 Decimal.rounding = 4;
H A DtoPrecision.js15 rounding: 4,
107 Decimal.rounding = 0;
175 Decimal.rounding = 1;
235 Decimal.rounding = 2;
288 Decimal.rounding = 3;
344 Decimal.rounding = 4;
389 Decimal.rounding = 5;
444 Decimal.rounding = 6;
/third_party/rust/crates/minimal-lexical/tests/
H A Drounding_tests.rs2 use minimal_lexical::rounding;
10 rounding::round::<f64, _>(&mut fp, |f, s| { in round_test()
21 rounding::round::<f64, _>(&mut fp, |f, s| { in round_test()
35 rounding::round::<f64, _>(&mut fp, |f, s| { in round_test()
36 rounding::round_nearest_tie_even(f, s, |is_odd, is_halfway, is_above| { in round_test()
48 rounding::round::<f64, _>(&mut fp, |f, s| { in round_test()
49 rounding::round_nearest_tie_even(f, s, |is_odd, is_halfway, is_above| { in round_test()
61 rounding::round::<f64, _>(&mut fp, rounding::round_down); in round_test()
/third_party/FreeBSD/contrib/gdtoa/
H A Dstrtord.c73 strtord_l(s, sp, rounding, d, locale) CONST char *s; char **sp; int rounding; in strtord_l()
76 strtord_l(CONST char *s, char **sp, int rounding, double *d, locale_t locale)
86 if (rounding != FPI_Round_near) {
88 fpi1.rounding = rounding;
/third_party/icu/icu4j/main/classes/core/src/com/ibm/icu/number/
H A DNumberPropertyMapper.java171 Precision rounding = null; in oldToNew()
173 rounding = Precision.constructCurrency(currencyUsage).withCurrency(currency); in oldToNew()
176 rounding = Precision.constructFraction(minFrac, maxFrac); in oldToNew()
181 rounding = Precision.constructIncrement(roundingIncrement); in oldToNew()
190 rounding = Precision.constructSignificant(minSig, maxSig); in oldToNew()
192 rounding = Precision.constructFraction(minFrac, maxFrac); in oldToNew()
194 rounding = Precision.constructCurrency(currencyUsage); in oldToNew()
196 if (rounding != null) { in oldToNew()
197 rounding = rounding in oldToNew()
[all...]
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/number/
H A DNumberPropertyMapper.java172 Precision rounding = null; in oldToNew()
174 rounding = Precision.constructCurrency(currencyUsage).withCurrency(currency); in oldToNew()
177 rounding = Precision.constructFraction(minFrac, maxFrac); in oldToNew()
179 rounding = Precision.constructIncrement(roundingIncrement); in oldToNew()
188 rounding = Precision.constructSignificant(minSig, maxSig); in oldToNew()
190 rounding = Precision.constructFraction(minFrac, maxFrac); in oldToNew()
192 rounding = Precision.constructCurrency(currencyUsage); in oldToNew()
194 if (rounding != null) { in oldToNew()
195 rounding = rounding in oldToNew()
[all...]
/third_party/skia/third_party/externals/libwebp/src/dsp/
H A Dyuv.h185 // Stub functions that can be called with various rounding values:
186 static WEBP_INLINE int VP8ClipUV(int uv, int rounding) { in VP8ClipUV() argument
187 uv = (uv + rounding + (128 << (YUV_FIX + 2))) >> (YUV_FIX + 2); in VP8ClipUV()
191 static WEBP_INLINE int VP8RGBToY(int r, int g, int b, int rounding) { in VP8RGBToY() argument
193 return (luma + rounding + (16 << YUV_FIX)) >> YUV_FIX; // no need to clip in VP8RGBToY()
196 static WEBP_INLINE int VP8RGBToU(int r, int g, int b, int rounding) { in VP8RGBToU() argument
198 return VP8ClipUV(u, rounding); in VP8RGBToU()
201 static WEBP_INLINE int VP8RGBToV(int r, int g, int b, int rounding) { in VP8RGBToV() argument
203 return VP8ClipUV(v, rounding); in VP8RGBToV()
/third_party/decimal.js/
H A Ddecimal.js45 // The rounding mode used when rounding to `precision`.
58 // `Decimal.rounding = 4;`
59 // `Decimal.rounding = Decimal.ROUND_HALF_UP;`
60 rounding: 4, // 0 to 8
63 // The quotient (q = a / n) is calculated according to the corresponding rounding mode.
73 // division (9) are commonly used for the modulus operation. The other rounding modes can also
305 rm = Ctor.rounding;
307 Ctor.rounding = 1;
312 Ctor.rounding
[all...]
/third_party/icu/icu4j/demos/src/com/ibm/icu/dev/demo/number/
H A DCurrencyDemo.java50 result.setRoundingIncrement(hack.rounding); in getCurrencyFormat()
60 double rounding; field in CurrencyDemo.HackCurrencyInfo
62 HackCurrencyInfo(int decimals, double rounding, String symbol) { in HackCurrencyInfo() argument
64 this.rounding = rounding; in HackCurrencyInfo()
/third_party/skia/experimental/lowp-basic/
H A DQMath.h47 const int32_t rounding = 1 << 14; in simulate_ssse3_mm_mulhrs_epi16()
48 int32_t temp = (int32_t)r * (int32_t)s + rounding; in simulate_ssse3_mm_mulhrs_epi16()
62 const int64_t rounding = 1 << (esize - 1); in simulate_neon_vqrdmulhq_s16()
63 int64_t product = 2LL * (int64_t)r * (int64_t)s + rounding; in simulate_neon_vqrdmulhq_s16()
/third_party/icu/icu4j/main/classes/core/src/com/ibm/icu/impl/number/
H A DPatternStringParser.java38 * Whether to leave out rounding information (minFrac, maxFrac, and rounding increment)
39 * when parsing the pattern. This may be desirable if a custom rounding mode, such as
61 * the pattern string. Properties that cannot be encoded into a pattern string, such as rounding
197 public DecimalQuantity_DualStorageBCD rounding = null; field in PatternStringParser.ParsedSubpatternInfo
473 if (state.peek() != '0' && result.rounding == null) { in consumeIntegerFormat()
474 result.rounding = new DecimalQuantity_DualStorageBCD(); in consumeIntegerFormat()
476 if (result.rounding != null) { in consumeIntegerFormat()
477 result.rounding.appendDigit((byte) (state.peek() - '0'), 0, true); in consumeIntegerFormat()
529 if (result.rounding in consumeFractionFormat()
[all...]
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/impl/number/
H A DPatternStringParser.java40 * Whether to leave out rounding information (minFrac, maxFrac, and rounding increment)
41 * when parsing the pattern. This may be desirable if a custom rounding mode, such as
63 * the pattern string. Properties that cannot be encoded into a pattern string, such as rounding
198 public DecimalQuantity_DualStorageBCD rounding = null; field in PatternStringParser.ParsedSubpatternInfo
430 if (state.peek() != '0' && result.rounding == null) { in consumeIntegerFormat()
431 result.rounding = new DecimalQuantity_DualStorageBCD(); in consumeIntegerFormat()
433 if (result.rounding != null) { in consumeIntegerFormat()
434 result.rounding.appendDigit((byte) (state.peek() - '0'), 0, true); in consumeIntegerFormat()
486 if (result.rounding in consumeFractionFormat()
[all...]
/third_party/ffmpeg/libavfilter/
H A Dvf_fps.c75 int rounding; ///< AVRounding method for timestamps member
105 { "round", "set rounding method for timestamps", OFFSET(rounding), AV_OPT_TYPE_INT, { .i64 = AV_ROUND_NEAR_INF }, 0, 5, V|F, "round" },
205 s->rounding | AV_ROUND_PASS_MINMAX); in config_props()
207 s->rounding | AV_ROUND_PASS_MINMAX); in config_props()
235 * The dance with offsets is required to match the rounding behaviour of the in read_frame()
240 s->rounding | AV_ROUND_PASS_MINMAX); in read_frame()
306 int eof_rounding = (s->eof_action == EOF_ACTION_PASS) ? AV_ROUND_UP : s->rounding; in update_eof_pts()
/third_party/icu/icu4c/source/i18n/
H A DdecContext.h39 /* round -- must be one of the enumerated rounding modes */
77 enum rounding { enum
94 enum rounding round; /* rounding mode */
255 U_CAPI enum rounding U_EXPORT2 uprv_decContextGetRounding(decContext *);
259 U_CAPI decContext * U_EXPORT2 uprv_decContextSetRounding(decContext *, enum rounding);
/third_party/node/deps/icu-small/source/i18n/
H A DdecContext.h39 /* round -- must be one of the enumerated rounding modes */
77 enum rounding { enum
94 enum rounding round; /* rounding mode */
255 U_CAPI enum rounding U_EXPORT2 uprv_decContextGetRounding(decContext *);
259 U_CAPI decContext * U_EXPORT2 uprv_decContextSetRounding(decContext *, enum rounding);
/third_party/skia/third_party/externals/icu/source/i18n/
H A DdecContext.h39 /* round -- must be one of the enumerated rounding modes */
77 enum rounding { enum
94 enum rounding round; /* rounding mode */
255 U_CAPI enum rounding U_EXPORT2 uprv_decContextGetRounding(decContext *);
259 U_CAPI decContext * U_EXPORT2 uprv_decContextSetRounding(decContext *, enum rounding);
/third_party/python/Modules/_decimal/tests/
H A Ddeccheck.py78 # Unary with optional rounding mode and context:
198 self.p.rounding = self.c.rounding
232 assert(self.c.rounding == self.p.rounding)
233 return self.c.rounding
236 self.c.rounding = val
237 self.p.rounding = val
258 rounding = property(getround, setround) variable in Context
305 rounding variable
[all...]
/third_party/python/Lib/
H A D_pydecimal.py317 """Invalid context. Unknown rounding, for example.
322 underlying concrete representation or an unknown or unsupported rounding
331 """Number got rounded (not necessarily changed during rounding).
343 """Exponent < Emin before rounding.
347 Emin, before any rounding). The result in all cases is unchanged.
358 by zero), after rounding, would be greater than the largest value that
361 The result depends on the rounding mode:
376 if context.rounding in (ROUND_HALF_UP, ROUND_HALF_EVEN,
380 if context.rounding == ROUND_CEILING:
385 if context.rounding
[all...]
/third_party/ffmpeg/libavcodec/
H A Daacenc_utils.h59 static inline int quant(float coef, const float Q, const float rounding) in quant() argument
62 return sqrtf(a * sqrtf(a)) + rounding; in quant()
67 const float rounding) in quantize_bands()
72 int tmp = (int)FFMIN(qc + rounding, (float)maxval); in quantize_bands()
65 quantize_bands(int *out, const float *in, const float *scaled, int size, int is_signed, int maxval, const float Q34, const float rounding) quantize_bands() argument
/third_party/skia/third_party/externals/imgui/
H A Dimgui_draw.cpp1338 // We cannot support hard coded 0x00 with 'float rounding > 0.0f' --> replace with ImDrawFlags_RoundCornersNone or use 'float rounding = 0.0f' in FixRectCornerFlags()
1351 void ImDrawList::PathRect(const ImVec2& a, const ImVec2& b, float rounding, ImDrawFlags flags) in PathRect() argument
1354 rounding = ImMin(rounding, ImFabs(b.x - a.x) * ( ((flags & ImDrawFlags_RoundCornersTop) == ImDrawFlags_RoundCornersTop) || ((flags & ImDrawFlags_RoundCornersBottom) == ImDrawFlags_RoundCornersBottom) ? 0.5f : 1.0f ) - 1.0f); in PathRect()
1355 rounding = ImMin(rounding, ImFabs(b.y - a.y) * ( ((flags & ImDrawFlags_RoundCornersLeft) == ImDrawFlags_RoundCornersLeft) || ((flags & ImDrawFlags_RoundCornersRight) == ImDrawFlags_RoundCornersRight) ? 0.5f : 1.0f ) - 1.0f); in PathRect()
1357 if (rounding <= 0.0f || (flags & ImDrawFlags_RoundCornersMask_) == ImDrawFlags_RoundCornersNone) in PathRect()
1366 const float rounding_tl = (flags & ImDrawFlags_RoundCornersTopLeft) ? rounding : 0.0f; in PathRect()
1367 const float rounding_tr = (flags & ImDrawFlags_RoundCornersTopRight) ? rounding in PathRect()
1388 AddRect(const ImVec2& p_min, const ImVec2& p_max, ImU32 col, float rounding, ImDrawFlags flags, float thickness) AddRect() argument
1399 AddRectFilled(const ImVec2& p_min, const ImVec2& p_max, ImU32 col, float rounding, ImDrawFlags flags) AddRectFilled() argument
1637 AddImageRounded(ImTextureID user_texture_id, const ImVec2& p_min, const ImVec2& p_max, const ImVec2& uv_min, const ImVec2& uv_max, ImU32 col, float rounding, ImDrawFlags flags) AddImageRounded() argument
3836 RenderRectFilledRangeH(ImDrawList* draw_list, const ImRect& rect, ImU32 col, float x_start_norm, float x_end_norm, float rounding) RenderRectFilledRangeH() argument
3864 draw_list->PathArcToFast(ImVec2(x0, p1.y - rounding), rounding, 3, 6); // BL RenderRectFilledRangeH() local
3865 draw_list->PathArcToFast(ImVec2(x0, p0.y + rounding), rounding, 6, 9); // TR RenderRectFilledRangeH() local
3869 draw_list->PathArcTo(ImVec2(x0, p1.y - rounding), rounding, IM_PI - arc0_e, IM_PI - arc0_b, 3); // BL RenderRectFilledRangeH() local
3870 draw_list->PathArcTo(ImVec2(x0, p0.y + rounding), rounding, IM_PI + arc0_b, IM_PI + arc0_e, 3); // TR RenderRectFilledRangeH() local
3884 draw_list->PathArcToFast(ImVec2(x1, p0.y + rounding), rounding, 9, 12); // TR RenderRectFilledRangeH() local
3885 draw_list->PathArcToFast(ImVec2(x1, p1.y - rounding), rounding, 0, 3); // BR RenderRectFilledRangeH() local
3889 draw_list->PathArcTo(ImVec2(x1, p0.y + rounding), rounding, -arc1_e, -arc1_b, 3); // TR RenderRectFilledRangeH() local
3890 draw_list->PathArcTo(ImVec2(x1, p1.y - rounding), rounding, +arc1_b, +arc1_e, 3); // BR RenderRectFilledRangeH() local
3896 RenderRectFilledWithHole(ImDrawList* draw_list, ImRect outer, ImRect inner, ImU32 col, float rounding) RenderRectFilledWithHole() argument
3902 if (fill_L) draw_list->AddRectFilled(ImVec2(outer.Min.x, inner.Min.y), ImVec2(inner.Min.x, inner.Max.y), col, rounding, (fill_U ? 0 : ImDrawFlags_RoundCornersTopLeft) | (fill_D ? 0 : ImDrawFlags_RoundCornersBottomLeft)); RenderRectFilledWithHole() local
3903 if (fill_R) draw_list->AddRectFilled(ImVec2(inner.Max.x, inner.Min.y), ImVec2(outer.Max.x, inner.Max.y), col, rounding, (fill_U ? 0 : ImDrawFlags_RoundCornersTopRight) | (fill_D ? 0 : ImDrawFlags_RoundCornersBottomRight)); RenderRectFilledWithHole() local
3904 if (fill_U) draw_list->AddRectFilled(ImVec2(inner.Min.x, outer.Min.y), ImVec2(inner.Max.x, inner.Min.y), col, rounding, (fill_L ? 0 : ImDrawFlags_RoundCornersTopLeft) | (fill_R ? 0 : ImDrawFlags_RoundCornersTopRight)); RenderRectFilledWithHole() local
3905 if (fill_D) draw_list->AddRectFilled(ImVec2(inner.Min.x, inner.Max.y), ImVec2(inner.Max.x, outer.Max.y), col, rounding, (fill_L ? 0 : ImDrawFlags_RoundCornersBottomLeft) | (fill_R ? 0 : ImDrawFlags_RoundCornersBottomRight)); RenderRectFilledWithHole() local
3906 if (fill_L && fill_U) draw_list->AddRectFilled(ImVec2(outer.Min.x, outer.Min.y), ImVec2(inner.Min.x, inner.Min.y), col, rounding, ImDrawFlags_RoundCornersTopLeft); RenderRectFilledWithHole() local
3907 if (fill_R && fill_U) draw_list->AddRectFilled(ImVec2(inner.Max.x, outer.Min.y), ImVec2(outer.Max.x, inner.Min.y), col, rounding, ImDrawFlags_RoundCornersTopRight); RenderRectFilledWithHole() local
3908 if (fill_L && fill_D) draw_list->AddRectFilled(ImVec2(outer.Min.x, inner.Max.y), ImVec2(inner.Min.x, outer.Max.y), col, rounding, ImDrawFlags_RoundCornersBottomLeft); RenderRectFilledWithHole() local
3909 if (fill_R && fill_D) draw_list->AddRectFilled(ImVec2(inner.Max.x, inner.Max.y), ImVec2(outer.Max.x, outer.Max.y), col, rounding, ImDrawFlags_RoundCornersBottomRight); RenderRectFilledWithHole() local
3916 RenderColorRectWithAlphaCheckerboard(ImDrawList* draw_list, ImVec2 p_min, ImVec2 p_max, ImU32 col, float grid_step, ImVec2 grid_off, float rounding, ImDrawFlags flags) RenderColorRectWithAlphaCheckerboard() argument
3943 draw_list->AddRectFilled(ImVec2(x1, y1), ImVec2(x2, y2), col_bg2, rounding, cell_flags); RenderColorRectWithAlphaCheckerboard() local
[all...]

Completed in 21 milliseconds

12345