From 877045e7ab738d25fec053415bf6295918ce2c97 Mon Sep 17 00:00:00 2001 From: xumale Date: Sun, 22 Jun 2025 10:52:37 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=96=B0=E5=A2=9EcontentLight=E5=92=8Cbord?= =?UTF-8?q?erLight=E6=8E=A5=E5=8F=A3=20Signed-off-by:xumale@h-partners.com?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: xumale --- api/@ohos.graphics.uiEffect.d.ts | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/api/@ohos.graphics.uiEffect.d.ts b/api/@ohos.graphics.uiEffect.d.ts index 43ca0d0f7f..225d9dc7a9 100644 --- a/api/@ohos.graphics.uiEffect.d.ts +++ b/api/@ohos.graphics.uiEffect.d.ts @@ -134,6 +134,22 @@ declare namespace uiEffect { */ bezierWarp(controlPoints: Array): Filter; + /** + * Sets the content light filter. + * + * @param { common2D.Point3d } lightPosition + * @param { Color } lightColor + * @param { number } lightIntensity + * @param { Mask } [displacementMap] + * @returns { Filter } - Returns the Filter that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + contentLight(lightPosition: common2D.Point3d, lightColor: Color, lightIntensity: number, + displacementMap?: Mask): Filter; + /** * Sets the color gradient filter, may blend with alpha mask. * @@ -345,6 +361,22 @@ declare namespace uiEffect { * @arkts 1.1&1.2 */ backgroundColorBlender(blender: BrightnessBlender): VisualEffect; + + /** + * Sets the border light effect. + * + * @param { common2D.Point3d } lightPosition + * @param { Color } lightColor + * @param { number } lightIntensity + * @param { number } borderWidth + * @returns { VisualEffect } - Returns the VisualEffect that the current effect have been added. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @syscap SystemCapability.Graphics.Drawing + * @systemapi + * @since 20 + */ + borderLight(lightPosition: common2D.Point3d, lightColor: Color, lightIntensity: number, + borderWidth: number): VisualEffect; } /** -- Gitee From e279ad5c5aad35d4c65f63107533c64285420629 Mon Sep 17 00:00:00 2001 From: xumale Date: Sun, 22 Jun 2025 07:04:39 +0000 Subject: [PATCH 2/2] update api/@ohos.graphics.uiEffect.d.ts. Signed-off-by: xumale --- api/@ohos.graphics.uiEffect.d.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/api/@ohos.graphics.uiEffect.d.ts b/api/@ohos.graphics.uiEffect.d.ts index 225d9dc7a9..274fa286a1 100644 --- a/api/@ohos.graphics.uiEffect.d.ts +++ b/api/@ohos.graphics.uiEffect.d.ts @@ -138,7 +138,7 @@ declare namespace uiEffect { * Sets the content light filter. * * @param { common2D.Point3d } lightPosition - * @param { Color } lightColor + * @param { common2D.Color } lightColor * @param { number } lightIntensity * @param { Mask } [displacementMap] * @returns { Filter } - Returns the Filter that the current effect have been added. @@ -147,7 +147,7 @@ declare namespace uiEffect { * @systemapi * @since 20 */ - contentLight(lightPosition: common2D.Point3d, lightColor: Color, lightIntensity: number, + contentLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: number, displacementMap?: Mask): Filter; /** @@ -366,7 +366,7 @@ declare namespace uiEffect { * Sets the border light effect. * * @param { common2D.Point3d } lightPosition - * @param { Color } lightColor + * @param { common2D.Color } lightColor * @param { number } lightIntensity * @param { number } borderWidth * @returns { VisualEffect } - Returns the VisualEffect that the current effect have been added. @@ -375,7 +375,7 @@ declare namespace uiEffect { * @systemapi * @since 20 */ - borderLight(lightPosition: common2D.Point3d, lightColor: Color, lightIntensity: number, + borderLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: number, borderWidth: number): VisualEffect; } -- Gitee