From b888baccbcaab72479592c794ef6210ad8d250be Mon Sep 17 00:00:00 2001 From: l00844999 Date: Sat, 1 Mar 2025 19:14:20 +0800 Subject: [PATCH] drawing change api version Signed-off-by: l00844999 --- .../native_drawing/drawing_canvas.h | 10 ++--- .../native_drawing/drawing_error_code.h | 2 +- .../graphic_2d/native_drawing/drawing_font.h | 6 +-- .../native_drawing/drawing_gpu_context.h | 2 +- .../native_drawing/drawing_path_effect.h | 12 +++--- .../graphic_2d/native_drawing/drawing_rect.h | 8 ++-- .../native_drawing/drawing_surface.h | 4 +- .../native_drawing/libnative_drawing.ndk.json | 42 +++++++++---------- 8 files changed, 43 insertions(+), 43 deletions(-) diff --git a/graphic/graphic_2d/native_drawing/drawing_canvas.h b/graphic/graphic_2d/native_drawing/drawing_canvas.h index e152fc0c6..2581f31ab 100644 --- a/graphic/graphic_2d/native_drawing/drawing_canvas.h +++ b/graphic/graphic_2d/native_drawing/drawing_canvas.h @@ -236,7 +236,7 @@ void OH_Drawing_CanvasDrawPath(OH_Drawing_Canvas* canvas, const OH_Drawing_Path* * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of canvas, pixelMap * and dst is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_CanvasDrawPixelMapNine(OH_Drawing_Canvas* canvas, OH_Drawing_PixelMap* pixelMap, @@ -433,7 +433,7 @@ void OH_Drawing_CanvasDrawArc(OH_Drawing_Canvas* canvas, * @return Returns the error code. * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if canvas or rect is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_CanvasDrawArcWithCenter(OH_Drawing_Canvas* canvas, const OH_Drawing_Rect* rect, @@ -462,7 +462,7 @@ void OH_Drawing_CanvasDrawRoundRect(OH_Drawing_Canvas* canvas, const OH_Drawing_ * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of canvas, outer * and inner is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_CanvasDrawNestedRoundRect(OH_Drawing_Canvas* canvas, const OH_Drawing_RoundRect* outer, @@ -914,7 +914,7 @@ OH_Drawing_ErrorCode OH_Drawing_CanvasDrawRecordCmd(OH_Drawing_Canvas* canvas, O * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if canvas or path is nullptr, * or quickReject is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_CanvasQuickRejectPath(OH_Drawing_Canvas* canvas, const OH_Drawing_Path* path, @@ -931,7 +931,7 @@ OH_Drawing_ErrorCode OH_Drawing_CanvasQuickRejectPath(OH_Drawing_Canvas* canvas, * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if canvas or rect is nullptr, * or quickReject is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_CanvasQuickRejectRect(OH_Drawing_Canvas* canvas, const OH_Drawing_Rect* rect, diff --git a/graphic/graphic_2d/native_drawing/drawing_error_code.h b/graphic/graphic_2d/native_drawing/drawing_error_code.h index 7b0503528..5bdc19682 100644 --- a/graphic/graphic_2d/native_drawing/drawing_error_code.h +++ b/graphic/graphic_2d/native_drawing/drawing_error_code.h @@ -86,7 +86,7 @@ OH_Drawing_ErrorCode OH_Drawing_ErrorCodeGet(); * @brief Resets the error code of the drawing module to OH_DRAWING_SUCCESS. * * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing - * @since 16 + * @since 18 * @version 1.0 */ void OH_Drawing_ErrorCodeReset(); diff --git a/graphic/graphic_2d/native_drawing/drawing_font.h b/graphic/graphic_2d/native_drawing/drawing_font.h index dd8601730..e8582939c 100644 --- a/graphic/graphic_2d/native_drawing/drawing_font.h +++ b/graphic/graphic_2d/native_drawing/drawing_font.h @@ -509,7 +509,7 @@ float OH_Drawing_FontGetMetrics(OH_Drawing_Font* font, OH_Drawing_Font_Metrics* * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of font, glyphs * and bounds is nullptr or count is 0. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_FontGetBounds(const OH_Drawing_Font* font, const uint16_t* glyphs, uint32_t count, @@ -526,7 +526,7 @@ OH_Drawing_ErrorCode OH_Drawing_FontGetBounds(const OH_Drawing_Font* font, const * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of font, path * is nullptr or glyph not exist. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_FontGetPathForGlyph(const OH_Drawing_Font* font, uint16_t glyph, @@ -547,7 +547,7 @@ OH_Drawing_ErrorCode OH_Drawing_FontGetPathForGlyph(const OH_Drawing_Font* font, * @return Returns the error code. * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if any of font, text or path is nullptr. - * @since 16 + * @since 18 */ OH_Drawing_ErrorCode OH_Drawing_FontGetTextPath(const OH_Drawing_Font* font, const void* text, size_t byteLength, OH_Drawing_TextEncoding encoding, float x, float y, OH_Drawing_Path* path); diff --git a/graphic/graphic_2d/native_drawing/drawing_gpu_context.h b/graphic/graphic_2d/native_drawing/drawing_gpu_context.h index 1949a5e72..236b2d0cc 100644 --- a/graphic/graphic_2d/native_drawing/drawing_gpu_context.h +++ b/graphic/graphic_2d/native_drawing/drawing_gpu_context.h @@ -73,7 +73,7 @@ OH_Drawing_GpuContext* OH_Drawing_GpuContextCreateFromGL(OH_Drawing_GpuContextOp * * @syscap SystemCapability.Graphic.Graphic2D.NativeDrawing * @return Returns the pointer to the OH_Drawing_GpuContext object created. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_GpuContext* OH_Drawing_GpuContextCreate(void); diff --git a/graphic/graphic_2d/native_drawing/drawing_path_effect.h b/graphic/graphic_2d/native_drawing/drawing_path_effect.h index e89201d14..214cea663 100644 --- a/graphic/graphic_2d/native_drawing/drawing_path_effect.h +++ b/graphic/graphic_2d/native_drawing/drawing_path_effect.h @@ -49,7 +49,7 @@ extern "C" { /** * @brief Enumerate path dash style. * - * @since 16 + * @since 18 * @version 1.0 */ typedef enum { @@ -69,7 +69,7 @@ typedef enum { * @param outer Indicates an OH_Drawing_PathEffect object * @param inner Indicates an OH_Drawing_PathEffect object * @return Returns the pointer to the OH_Drawing_PathEffect object created. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_PathEffect* OH_Drawing_CreateComposePathEffect(OH_Drawing_PathEffect* outer, OH_Drawing_PathEffect* inner); @@ -83,7 +83,7 @@ OH_Drawing_PathEffect* OH_Drawing_CreateComposePathEffect(OH_Drawing_PathEffect* * @return Returns the pointer to the OH_Drawing_PathEffect object created. * If nullptr is returned, the creation fails. * The possible cause of the failure is radius is zero or less. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_PathEffect* OH_Drawing_CreateCornerPathEffect(float radius); @@ -109,7 +109,7 @@ OH_Drawing_PathEffect* OH_Drawing_CreateDashPathEffect(float* intervals, int cou * @param segLength Indicates the maximum segment length of the path. * @param deviation Indicates the deviation during drawing. * @return Returns the pointer to the OH_Drawing_PathEffect object created. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_PathEffect* OH_Drawing_CreateDiscretePathEffect(float segLength, float deviation); @@ -125,7 +125,7 @@ OH_Drawing_PathEffect* OH_Drawing_CreateDiscretePathEffect(float segLength, floa * @return Returns the pointer to the OH_Drawing_PathEffect object created. * If nullptr is returned, the creation fails. * The possible cause of the failure is advance and phase are zero or less. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_PathEffect* OH_Drawing_CreatePathDashEffect(const OH_Drawing_Path* path, float advance, float phase, @@ -138,7 +138,7 @@ OH_Drawing_PathEffect* OH_Drawing_CreatePathDashEffect(const OH_Drawing_Path* pa * @param firstPathEffect Indicates the pointer to an OH_Drawing_PathEffect object. * @param secondPathEffect Indicates the pointer to an OH_Drawing_PathEffect object. * @return Returns the pointer to the OH_Drawing_PathEffect object created. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_PathEffect* OH_Drawing_CreateSumPathEffect(OH_Drawing_PathEffect* firstPathEffect, diff --git a/graphic/graphic_2d/native_drawing/drawing_rect.h b/graphic/graphic_2d/native_drawing/drawing_rect.h index ecabab963..27dd05fea 100644 --- a/graphic/graphic_2d/native_drawing/drawing_rect.h +++ b/graphic/graphic_2d/native_drawing/drawing_rect.h @@ -225,7 +225,7 @@ void OH_Drawing_RectDestroy(OH_Drawing_Rect* rect); * If nullptr is returned, the creation fails. * The possible cause of the failure is that the available memory is empty, * or size is invalid. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_Array* OH_Drawing_RectCreateArray(size_t size); @@ -239,7 +239,7 @@ OH_Drawing_Array* OH_Drawing_RectCreateArray(size_t size); * @return Returns the error code. * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if rectArray or pSize is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_RectGetArraySize(OH_Drawing_Array* rectArray, size_t* pSize); @@ -255,7 +255,7 @@ OH_Drawing_ErrorCode OH_Drawing_RectGetArraySize(OH_Drawing_Array* rectArray, si * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if rectArray or rect is nullptr, * or index is valid. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_RectGetArrayElement(OH_Drawing_Array* rectArray, size_t index, @@ -269,7 +269,7 @@ OH_Drawing_ErrorCode OH_Drawing_RectGetArrayElement(OH_Drawing_Array* rectArray, * @return Returns the error code. * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if rectArray is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_RectDestroyArray(OH_Drawing_Array* rectArray); diff --git a/graphic/graphic_2d/native_drawing/drawing_surface.h b/graphic/graphic_2d/native_drawing/drawing_surface.h index 67f951f74..240854f25 100644 --- a/graphic/graphic_2d/native_drawing/drawing_surface.h +++ b/graphic/graphic_2d/native_drawing/drawing_surface.h @@ -69,7 +69,7 @@ OH_Drawing_Surface* OH_Drawing_SurfaceCreateFromGpuContext( * @param imageInfo Indicates the image info. * @param window Indicates the pointer of the screen window. * @return Returns the pointer to the OH_Drawing_Surface object created. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_Surface* OH_Drawing_SurfaceCreateOnScreen( @@ -95,7 +95,7 @@ OH_Drawing_Canvas* OH_Drawing_SurfaceGetCanvas(OH_Drawing_Surface* surface); * @return Returns the error code. * Returns {@link OH_DRAWING_SUCCESS} if the operation is successful. * Returns {@link OH_DRAWING_ERROR_INVALID_PARAMETER} if surface is nullptr. - * @since 16 + * @since 18 * @version 1.0 */ OH_Drawing_ErrorCode OH_Drawing_SurfaceFlush(OH_Drawing_Surface* surface); diff --git a/graphic/graphic_2d/native_drawing/libnative_drawing.ndk.json b/graphic/graphic_2d/native_drawing/libnative_drawing.ndk.json index 6ee257eb1..35f99e90b 100644 --- a/graphic/graphic_2d/native_drawing/libnative_drawing.ndk.json +++ b/graphic/graphic_2d/native_drawing/libnative_drawing.ndk.json @@ -153,24 +153,24 @@ }, { "name": "OH_Drawing_CreateDashPathEffect" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_CreatePathDashEffect" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_CreateSumPathEffect" }, { "name": "OH_Drawing_PathEffectDestroy" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_CreateDiscretePathEffect" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_CreateCornerPathEffect" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_CreateComposePathEffect" }, { "name": "OH_Drawing_ColorFilterCreateBlendMode" }, @@ -185,7 +185,7 @@ "name": "OH_Drawing_ErrorCodeGet" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_ErrorCodeReset" }, { "name": "OH_Drawing_FilterCreate" }, @@ -323,7 +323,7 @@ "name": "OH_Drawing_GpuContextCreateFromGL" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_GpuContextCreate" }, { @@ -713,7 +713,7 @@ "name": "OH_Drawing_SurfaceCreateFromGpuContext" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_SurfaceCreateOnScreen" }, { @@ -721,7 +721,7 @@ "name": "OH_Drawing_SurfaceGetCanvas" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_SurfaceFlush" }, { @@ -1583,27 +1583,27 @@ "name": "OH_Drawing_LineTypographyCreateLine" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_FontGetBounds" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_FontGetPathForGlyph" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_RectCreateArray" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_RectGetArraySize" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_RectGetArrayElement" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_RectDestroyArray" }, { @@ -1627,7 +1627,7 @@ "name":"OH_Drawing_SetTypographyTextTab" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_FontGetTextPath" }, { @@ -1771,23 +1771,23 @@ "name":"OH_Drawing_GetFontCollectionGlobalInstance" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_CanvasQuickRejectPath" }, { - "first_introduced": "16", + "first_introduced": "18", "name":"OH_Drawing_CanvasQuickRejectRect" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_CanvasDrawNestedRoundRect" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_CanvasDrawArcWithCenter" }, { - "first_introduced": "16", + "first_introduced": "18", "name": "OH_Drawing_CanvasDrawPixelMapNine" } ] \ No newline at end of file -- Gitee