Home
last modified time | relevance | path

Searched refs:CLAMP (Results 1 – 25 of 343) sorted by relevance

12345678910>>...14

/third_party/gstreamer/gstplugins_good/gst/videobox/
Dgstvideobox.c295 destY[0] = CLAMP (APPLY_MATRIX (matrix, 0, y1, u1, v1), 0, 255); in copy_ayuv_i420()
297 CLAMP ((3 * destU[0] + APPLY_MATRIX (matrix, 1, y1, u1, v1)) / 4, 0, in copy_ayuv_i420()
300 CLAMP ((3 * destV[0] + APPLY_MATRIX (matrix, 2, y1, u1, v1)) / 4, 0, in copy_ayuv_i420()
323 destY[y_idx] = CLAMP (APPLY_MATRIX (matrix, 0, y1, u1, v1), 0, 255); in copy_ayuv_i420()
324 destY[y_idx + 1] = CLAMP (APPLY_MATRIX (matrix, 0, y2, u2, v2), 0, 255); in copy_ayuv_i420()
325 destU[uv_idx] = CLAMP ( in copy_ayuv_i420()
328 destV[uv_idx] = CLAMP ( in copy_ayuv_i420()
345 destY[y_idx] = CLAMP (APPLY_MATRIX (matrix, 0, y1, u1, v1), 0, 255); in copy_ayuv_i420()
346 destU[uv_idx] = CLAMP ( in copy_ayuv_i420()
348 destV[uv_idx] = CLAMP ( in copy_ayuv_i420()
[all …]
/third_party/mesa3d/src/gallium/auxiliary/translate/
Dtranslate_generic.c267 value |= ((uint32_t)(CLAMP(src[2], 0, 1) * 0x3ff)) & 0x3ff; in emit_B10G10R10A2_UNORM()
268 value |= (((uint32_t)(CLAMP(src[1], 0, 1) * 0x3ff)) & 0x3ff) << 10; in emit_B10G10R10A2_UNORM()
269 value |= (((uint32_t)(CLAMP(src[0], 0, 1) * 0x3ff)) & 0x3ff) << 20; in emit_B10G10R10A2_UNORM()
270 value |= ((uint32_t)(CLAMP(src[3], 0, 1) * 0x3)) << 30; in emit_B10G10R10A2_UNORM()
279 value |= ((uint32_t)CLAMP(src[2], 0, 1023)) & 0x3ff; in emit_B10G10R10A2_USCALED()
280 value |= (((uint32_t)CLAMP(src[1], 0, 1023)) & 0x3ff) << 10; in emit_B10G10R10A2_USCALED()
281 value |= (((uint32_t)CLAMP(src[0], 0, 1023)) & 0x3ff) << 20; in emit_B10G10R10A2_USCALED()
282 value |= ((uint32_t)CLAMP(src[3], 0, 3)) << 30; in emit_B10G10R10A2_USCALED()
291 value |= (uint32_t)(((uint32_t)(CLAMP(src[2], -1, 1) * 0x1ff)) & 0x3ff) ; in emit_B10G10R10A2_SNORM()
292 value |= (uint32_t)((((uint32_t)(CLAMP(src[1], -1, 1) * 0x1ff)) & 0x3ff) << 10) ; in emit_B10G10R10A2_SNORM()
[all …]
/third_party/flutter/skia/third_party/externals/sdl/src/haptic/linux/
DSDL_syshaptic.c718 #define CLAMP(x) (((x) > 32767) ? 32767 : x) macro
746 0 : CLAMP(constant->length); in SDL_SYS_ToFFEffect()
747 dest->replay.delay = CLAMP(constant->delay); in SDL_SYS_ToFFEffect()
751 dest->trigger.interval = CLAMP(constant->interval); in SDL_SYS_ToFFEffect()
758 CLAMP(constant->attack_length); in SDL_SYS_ToFFEffect()
760 CLAMP(constant->attack_level); in SDL_SYS_ToFFEffect()
761 dest->u.constant.envelope.fade_length = CLAMP(constant->fade_length); in SDL_SYS_ToFFEffect()
762 dest->u.constant.envelope.fade_level = CLAMP(constant->fade_level); in SDL_SYS_ToFFEffect()
781 0 : CLAMP(periodic->length); in SDL_SYS_ToFFEffect()
782 dest->replay.delay = CLAMP(periodic->delay); in SDL_SYS_ToFFEffect()
[all …]
/third_party/gstreamer/gstplugins_bad/gst/audiovisualizers/
Dgstspacescope.c314 x = CLAMP (x, 0, w1); in render_color_dots()
315 y = CLAMP (y, 0, h1); in render_color_dots()
320 x = CLAMP (x, 0, w1); in render_color_dots()
321 y = CLAMP (y, 0, h1); in render_color_dots()
326 x = CLAMP (x, 0, w1); in render_color_dots()
327 y = CLAMP (y, 0, h1); in render_color_dots()
377 x2 = CLAMP (x, 0, w1); in render_color_lines()
378 y2 = CLAMP (y, 0, h1); in render_color_lines()
382 x3 = CLAMP (x, 0, w1); in render_color_lines()
383 y3 = CLAMP (y, 0, h1); in render_color_lines()
[all …]
/third_party/gstreamer/gstreamer/libs/gst/controller/
Dgstargbcontrolbinding.c263 guint src_val = (((guint) (CLAMP (src_val_a, 0.0, 1.0) * 255)) << 24) | in gst_argb_control_binding_sync_values()
264 (((guint) (CLAMP (src_val_r, 0.0, 1.0) * 255)) << 16) | in gst_argb_control_binding_sync_values()
265 (((guint) (CLAMP (src_val_g, 0.0, 1.0) * 255)) << 8) | in gst_argb_control_binding_sync_values()
266 ((guint) (CLAMP (src_val_b, 0.0, 1.0) * 255)); in gst_argb_control_binding_sync_values()
311 guint src_val = (((guint) (CLAMP (src_val_a, 0.0, 1.0) * 255)) << 24) | in gst_argb_control_binding_get_value()
312 (((guint) (CLAMP (src_val_r, 0.0, 1.0) * 255)) << 16) | in gst_argb_control_binding_get_value()
313 (((guint) (CLAMP (src_val_g, 0.0, 1.0) * 255)) << 8) | in gst_argb_control_binding_get_value()
314 ((guint) (CLAMP (src_val_b, 0.0, 1.0) * 255)); in gst_argb_control_binding_get_value()
375 values[i] = (((guint) (CLAMP (a, 0.0, 1.0) * 255)) << 24) | in gst_argb_control_binding_get_value_array()
376 (((guint) (CLAMP (r, 0.0, 1.0) * 255)) << 16) | in gst_argb_control_binding_get_value_array()
[all …]
/third_party/mesa3d/src/mesa/main/
Dpixeltransfer.c94 GLfloat r = CLAMP(rgba[i][RCOMP], 0.0F, 1.0F); in _mesa_map_rgba()
95 GLfloat g = CLAMP(rgba[i][GCOMP], 0.0F, 1.0F); in _mesa_map_rgba()
96 GLfloat b = CLAMP(rgba[i][BCOMP], 0.0F, 1.0F); in _mesa_map_rgba()
97 GLfloat a = CLAMP(rgba[i][ACOMP], 0.0F, 1.0F); in _mesa_map_rgba()
139 depthValues[i] = CLAMP(d, 0.0F, 1.0F); in _mesa_scale_and_bias_depth()
154 d = CLAMP(d, 0.0, max); in _mesa_scale_and_bias_depth_uint()
184 rgba[i][RCOMP] = CLAMP(rgba[i][RCOMP], 0.0F, 1.0F); in _mesa_apply_rgba_transfer_ops()
185 rgba[i][GCOMP] = CLAMP(rgba[i][GCOMP], 0.0F, 1.0F); in _mesa_apply_rgba_transfer_ops()
186 rgba[i][BCOMP] = CLAMP(rgba[i][BCOMP], 0.0F, 1.0F); in _mesa_apply_rgba_transfer_ops()
187 rgba[i][ACOMP] = CLAMP(rgba[i][ACOMP], 0.0F, 1.0F); in _mesa_apply_rgba_transfer_ops()
Drastpos.c154 diffuseColor[3] = CLAMP( in shade_rastpos()
269 Rcolor[0] = CLAMP(diffuseColor[0], 0.0F, 1.0F); in shade_rastpos()
270 Rcolor[1] = CLAMP(diffuseColor[1], 0.0F, 1.0F); in shade_rastpos()
271 Rcolor[2] = CLAMP(diffuseColor[2], 0.0F, 1.0F); in shade_rastpos()
272 Rcolor[3] = CLAMP(diffuseColor[3], 0.0F, 1.0F); in shade_rastpos()
273 Rspec[0] = CLAMP(specularColor[0], 0.0F, 1.0F); in shade_rastpos()
274 Rspec[1] = CLAMP(specularColor[1], 0.0F, 1.0F); in shade_rastpos()
275 Rspec[2] = CLAMP(specularColor[2], 0.0F, 1.0F); in shade_rastpos()
276 Rspec[3] = CLAMP(specularColor[3], 0.0F, 1.0F); in shade_rastpos()
458 ctx->Current.RasterPos[3] = CLAMP(ctx->Current.RasterPos[3], in _mesa_RasterPos()
[all …]
Dfog.c152 ctx->Fog.Color[0] = CLAMP(params[0], 0.0F, 1.0F); in _mesa_Fogfv()
153 ctx->Fog.Color[1] = CLAMP(params[1], 0.0F, 1.0F); in _mesa_Fogfv()
154 ctx->Fog.Color[2] = CLAMP(params[2], 0.0F, 1.0F); in _mesa_Fogfv()
155 ctx->Fog.Color[3] = CLAMP(params[3], 0.0F, 1.0F); in _mesa_Fogfv()
/third_party/gstreamer/gstplugins_good/gst/alpha/
Dgstalpha.c566 x = CLAMP (tmp, -128, 127); in chroma_keying_yuv()
568 z = CLAMP (tmp, -128, 127); in chroma_keying_yuv()
588 tmp = CLAMP (tmp, -128, 127); in chroma_keying_yuv()
595 b_alpha = 255 - CLAMP (b_alpha, 0, 255); in chroma_keying_yuv()
605 *u = CLAMP (tmp, -128, 127); in chroma_keying_yuv()
608 *v = CLAMP (tmp, -128, 127); in chroma_keying_yuv()
629 gint s_alpha = CLAMP ((gint) (alpha->alpha * 256), 0, 256); in gst_alpha_set_argb_ayuv()
682 gint pa = CLAMP ((gint) (alpha->alpha * 256), 0, 256); in gst_alpha_chroma_key_argb_ayuv()
747 gint s_alpha = CLAMP ((gint) (alpha->alpha * 256), 0, 256); in gst_alpha_set_argb_argb()
792 gint pa = CLAMP ((gint) (alpha->alpha * 256), 0, 256); in gst_alpha_chroma_key_argb_argb()
[all …]
/third_party/gstreamer/gstplugins_bad/gst/coloreffects/
Dgstcoloreffects.c403 data[offsets[0]] = CLAMP (y, 0, 255); in gst_color_effects_transform_ayuv()
404 data[offsets[1]] = CLAMP (u, 0, 255); in gst_color_effects_transform_ayuv()
405 data[offsets[2]] = CLAMP (v, 0, 255); in gst_color_effects_transform_ayuv()
411 r = CLAMP (r, 0, 255); in gst_color_effects_transform_ayuv()
412 g = CLAMP (g, 0, 255); in gst_color_effects_transform_ayuv()
413 b = CLAMP (b, 0, 255); in gst_color_effects_transform_ayuv()
427 data[offsets[0]] = CLAMP (y, 0, 255); in gst_color_effects_transform_ayuv()
428 data[offsets[1]] = CLAMP (u, 0, 255); in gst_color_effects_transform_ayuv()
429 data[offsets[2]] = CLAMP (v, 0, 255); in gst_color_effects_transform_ayuv()
/third_party/gstreamer/gstplugins_base/gst-libs/gst/video/
Dvideo-blend.c89 tmpline[i * 4 + 1] = CLAMP (y, 0, 255); in matrix_prea_rgb_to_yuv()
90 tmpline[i * 4 + 2] = CLAMP (u, 0, 255); in matrix_prea_rgb_to_yuv()
91 tmpline[i * 4 + 3] = CLAMP (v, 0, 255); in matrix_prea_rgb_to_yuv()
111 tmpline[i * 4 + 1] = CLAMP (y, 0, 255); in matrix_rgb_to_yuv()
112 tmpline[i * 4 + 2] = CLAMP (u, 0, 255); in matrix_rgb_to_yuv()
113 tmpline[i * 4 + 3] = CLAMP (v, 0, 255); in matrix_rgb_to_yuv()
133 tmpline[i * 4 + 1] = CLAMP (r, 0, 255); in matrix_yuv_to_rgb()
134 tmpline[i * 4 + 2] = CLAMP (g, 0, 255); in matrix_yuv_to_rgb()
135 tmpline[i * 4 + 3] = CLAMP (b, 0, 255); in matrix_yuv_to_rgb()
/third_party/skia/third_party/externals/opengl-registry/extensions/SGIX/
DSGIX_texture_phase.txt65 TEXTURE_WRAP_S integer CLAMP, REPEAT
66 TEXTURE_WRAP_T integer CLAMP, REPEAT
67 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
98 \ floor(u - 1/2), TEXTURE_WRAP_S is CLAMP
103 \ i0 + 1, TEXTURE_WRAP_S is CLAMP
134 \ floor(v - 1/2), TEXTURE_WRAP_T is CLAMP
139 \ j0 + 1, TEXTURE_WRAP_T is CLAMP
DSGIX_texture_coordinate_clamp.txt25 the wrap mode is set to CLAMP. This mechanism can be used to guarantee
95 TEXTURE_WRAP_S integer CLAMP, REPEAT
96 TEXTURE_WRAP_T integer CLAMP, REPEAT
97 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
141 / 2^n.TEXTURE_MAX_CLAMP_S_SGIX if (TEXTURE_WRAP_S == CLAMP and
146 / 2^n.TEXTURE_MAX_CLAMP_T_SGIX if (TEXTURE_WRAP_T == CLAMP and
152 / 2^n.TEXTURE_MAX_CLAMP_R_SGIX if (TEXTURE_WRAP_R == CLAMP and
/third_party/openGLES/extensions/SGIX/
DSGIX_texture_phase.txt65 TEXTURE_WRAP_S integer CLAMP, REPEAT
66 TEXTURE_WRAP_T integer CLAMP, REPEAT
67 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
98 \ floor(u - 1/2), TEXTURE_WRAP_S is CLAMP
103 \ i0 + 1, TEXTURE_WRAP_S is CLAMP
134 \ floor(v - 1/2), TEXTURE_WRAP_T is CLAMP
139 \ j0 + 1, TEXTURE_WRAP_T is CLAMP
DSGIX_texture_coordinate_clamp.txt25 the wrap mode is set to CLAMP. This mechanism can be used to guarantee
95 TEXTURE_WRAP_S integer CLAMP, REPEAT
96 TEXTURE_WRAP_T integer CLAMP, REPEAT
97 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
141 / 2^n.TEXTURE_MAX_CLAMP_S_SGIX if (TEXTURE_WRAP_S == CLAMP and
146 / 2^n.TEXTURE_MAX_CLAMP_T_SGIX if (TEXTURE_WRAP_T == CLAMP and
152 / 2^n.TEXTURE_MAX_CLAMP_R_SGIX if (TEXTURE_WRAP_R == CLAMP and
/third_party/musl/src/time/
Dclock_nanosleep.c6 #define CLAMP(x) (int)(IS32BIT(x) ? (x) : 0x7fffffffU+((0ULL+(x))>>63)) macro
20 long long extra = s - CLAMP(s); in __clock_nanosleep()
21 long ts32[2] = { CLAMP(s), ns }; in __clock_nanosleep()
/third_party/openGLES/extensions/ATI/
DATI_texture_mirror_once.txt64 "TEXTURE_WRAP_S integer CLAMP, CLAMP_TO_EDGE, REPEAT,
66 TEXTURE_WRAP_T integer CLAMP, CLAMP_TO_EDGE, REPEAT,
68 TEXTURE_WRAP_R integer CLAMP, CLAMP_TO_EDGE, REPEAT,
80 Like the CLAMP wrap mode, with MIRROR_CLAMP_ATI the texels from
90 under Texture Wrap Modes (if the wrap mode for a coordinate is CLAMP,
/third_party/skia/third_party/externals/opengl-registry/extensions/ATI/
DATI_texture_mirror_once.txt64 "TEXTURE_WRAP_S integer CLAMP, CLAMP_TO_EDGE, REPEAT,
66 TEXTURE_WRAP_T integer CLAMP, CLAMP_TO_EDGE, REPEAT,
68 TEXTURE_WRAP_R integer CLAMP, CLAMP_TO_EDGE, REPEAT,
80 Like the CLAMP wrap mode, with MIRROR_CLAMP_ATI the texels from
90 under Texture Wrap Modes (if the wrap mode for a coordinate is CLAMP,
/third_party/mesa3d/src/broadcom/vulkan/
Dv3dvx_device.c92 border.f[0] = CLAMP(border.f[0], 0, 1); in encode_border_color()
93 border.ui[1] = CLAMP(border.ui[1], 0, 0xff); in encode_border_color()
96 border.f[i] = CLAMP(border.f[i], 0, 1); in encode_border_color()
99 border.f[i] = CLAMP(border.f[i], -1, 1); in encode_border_color()
103 border.ui[i] = CLAMP(border.ui[i], 0, (1 << desc->channel[i].size)); in encode_border_color()
107 border.i[i] = CLAMP(border.i[i], in encode_border_color()
/third_party/skia/third_party/externals/opengl-registry/extensions/SGIS/
DSGIS_texture_filter4.txt96 TEXTURE_WRAP_S integer CLAMP, REPEAT
97 TEXTURE_WRAP_T integer CLAMP, REPEAT
98 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
125 \ floor(u - 1/2), TEXTURE_WRAP_S is CLAMP
130 \ i1 + 1, TEXTURE_WRAP_S is CLAMP
135 \ i1 + 2, TEXTURE_WRAP_S is CLAMP
140 \ i1 - 1, TEXTURE_WRAP_S is CLAMP
167 \ floor(v - 1/2), TEXTURE_WRAP_T is CLAMP
172 \ j1 + 1, TEXTURE_WRAP_T is CLAMP
177 \ j1 + 2, TEXTURE_WRAP_T is CLAMP
[all …]
/third_party/openGLES/extensions/SGIS/
DSGIS_texture_filter4.txt96 TEXTURE_WRAP_S integer CLAMP, REPEAT
97 TEXTURE_WRAP_T integer CLAMP, REPEAT
98 TEXTURE_WRAP_R_EXT integer CLAMP, REPEAT
125 \ floor(u - 1/2), TEXTURE_WRAP_S is CLAMP
130 \ i1 + 1, TEXTURE_WRAP_S is CLAMP
135 \ i1 + 2, TEXTURE_WRAP_S is CLAMP
140 \ i1 - 1, TEXTURE_WRAP_S is CLAMP
167 \ floor(v - 1/2), TEXTURE_WRAP_T is CLAMP
172 \ j1 + 1, TEXTURE_WRAP_T is CLAMP
177 \ j1 + 2, TEXTURE_WRAP_T is CLAMP
[all …]
/third_party/mesa3d/src/gallium/drivers/freedreno/a5xx/
Dfd5_emit.c252 clamped = CLAMP(bc->ui[j], 0, 0x3); in setup_border_colors()
256 clamped = CLAMP(bc->i[j], -128, 127); in setup_border_colors()
258 clamped = CLAMP(bc->ui[j], 0, 255); in setup_border_colors()
262 clamped = CLAMP(bc->ui[j], 0, 0x3ff); in setup_border_colors()
266 clamped = CLAMP(bc->i[j], -32768, 32767); in setup_border_colors()
268 clamped = CLAMP(bc->ui[j], 0, 65535); in setup_border_colors()
280 float f_u = CLAMP(f, 0, 1); in setup_border_colors()
281 float f_s = CLAMP(f, -1, 1); in setup_border_colors()
830 A5XX_RB_BLEND_RED_UINT(CLAMP(bcolor->color[0], 0.f, 1.f) * 0xff) | in fd5_emit_state()
831 A5XX_RB_BLEND_RED_SINT(CLAMP(bcolor->color[0], -1.f, 1.f) * 0x7f)); in fd5_emit_state()
[all …]
/third_party/mesa3d/src/gallium/drivers/softpipe/
Dsp_tex_sample.c294 const float u = CLAMP(s * size + offset, 0.0F, (float)size) - 0.5f; in wrap_linear_clamp()
306 const float u = CLAMP(s * size + offset, 0.0F, (float)size) - 0.5f; in wrap_linear_clamp_to_edge()
323 const float u = CLAMP(s * size + offset, min, max) - 0.5f; in wrap_linear_clamp_to_border()
406 const float u = CLAMP(t, min, max) - 0.5F; in wrap_linear_mirror_clamp_to_border()
420 *icoord = CLAMP(i + offset, 0, (int) size-1); in wrap_nearest_unorm_clamp()
430 *icoord = util_ifloor( CLAMP(s + offset, -0.5F, (float) size + 0.5F) ); in wrap_nearest_unorm_clamp_to_border()
440 *icoord = util_ifloor( CLAMP(s + offset, 0.5F, (float) size - 0.5F) ); in wrap_nearest_unorm_clamp_to_edge()
452 const float u = CLAMP(s + offset - 0.5F, 0.0f, (float) size - 1.0f); in wrap_linear_unorm_clamp()
466 const float u = CLAMP(s + offset, -0.5F, (float) size + 0.5F) - 0.5F; in wrap_linear_unorm_clamp_to_border()
482 const float u = CLAMP(s + offset, +0.5F, (float) size - 0.5F) - 0.5F; in wrap_linear_unorm_clamp_to_edge()
[all …]
/third_party/gstreamer/gstplugins_bad/gst/gaudieffects/
Dgstdodge.c248 red = CLAMP (red, 0, 255); in transform()
249 green = CLAMP (green, 0, 255); in transform()
250 blue = CLAMP (blue, 0, 255); in transform()
/third_party/musl/src/linux/
Dppoll.c8 #define CLAMP(x) (int)(IS32BIT(x) ? (x) : 0x7fffffffU+((0ULL+(x))>>63)) macro
22 s = CLAMP(s); in ppoll()

12345678910>>...14