1e41f4b71Sopenharmony_ci# Graphics Subsystem Changelog
2e41f4b71Sopenharmony_ci
3e41f4b71Sopenharmony_ci## cl.blendMode.1 blendMode Changed
4e41f4b71Sopenharmony_ci
5e41f4b71Sopenharmony_ci**Access Level**
6e41f4b71Sopenharmony_ci
7e41f4b71Sopenharmony_ciPublic API
8e41f4b71Sopenharmony_ci
9e41f4b71Sopenharmony_ci**Reason for Change**
10e41f4b71Sopenharmony_ci
11e41f4b71Sopenharmony_ciThe API behavior fails to meet the requirements of third-party applications in multiple scenarios.  
12e41f4b71Sopenharmony_ci
13e41f4b71Sopenharmony_ci**Change Impact**
14e41f4b71Sopenharmony_ci
15e41f4b71Sopenharmony_ciThis change is a non-compatible change.
16e41f4b71Sopenharmony_ci1. The enumerated values of **blendMode** are changed. Specifically, **NORMAL** is changed to **NONE**, **SOURCE_IN** is changed to **SRC_IN**, and **DESTINATION_IN** is changed to **DST_IN**.
17e41f4b71Sopenharmony_ci2. The API behavior is changed. Before the change, the API blends the component background with the subnode content. After the change, the API blends the component content (including the subnode content) with the content of the canvas (possibly offscreen canvas).
18e41f4b71Sopenharmony_ci
19e41f4b71Sopenharmony_ci**API Level**
20e41f4b71Sopenharmony_ci
21e41f4b71Sopenharmony_ci11
22e41f4b71Sopenharmony_ci
23e41f4b71Sopenharmony_ci**Change Since**
24e41f4b71Sopenharmony_ci
25e41f4b71Sopenharmony_ciOpenHarmony SDK 4.1.6.3
26e41f4b71Sopenharmony_ci
27e41f4b71Sopenharmony_ci**Key API/Component Changes**
28e41f4b71Sopenharmony_ci
29e41f4b71Sopenharmony_ciThe enumerated values and behavior of **blendMode** are changed.
30e41f4b71Sopenharmony_ci
31e41f4b71Sopenharmony_ci**Adaptation Guide**
32e41f4b71Sopenharmony_ci
33e41f4b71Sopenharmony_ci1. Change the enumerated values in your code. Specifically, change **NORMAL** to **NONE**, **SOURCE_IN** to **SRC_IN**, and **DESTINATION_IN** to **DST_IN**.
34e41f4b71Sopenharmony_ci2. The API behavior is changed. Before the change, the API provides two offscreen operations, which are used to the component background and subnode content, respectively. After the change, the API supports only one offscreen operation, which must be triggered by calling **BlendApplyType.OFFSCREEN**. If you want to retain the original behavior, call **BlendApplyType.OFFSCREEN** twice to trigger two offscreen operations to draw the component background and subnode content.<br>
35e41f4b71Sopenharmony_ci  The sample code is as follows:
36e41f4b71Sopenharmony_ci
37e41f4b71Sopenharmony_ci  ```ts
38e41f4b71Sopenharmony_ci  // In the .ets file that uses the new API, you can call BlendApplyType.OFFSCREEN twice to trigger two offscreen operations.
39e41f4b71Sopenharmony_ci  @Entry
40e41f4b71Sopenharmony_ci  @Component
41e41f4b71Sopenharmony_ci  struct Index {
42e41f4b71Sopenharmony_ci    build() {
43e41f4b71Sopenharmony_ci      Column() {
44e41f4b71Sopenharmony_ci        // The second offscreen operation is used to draw the subnode content.
45e41f4b71Sopenharmony_ci        Text("test")
46e41f4b71Sopenharmony_ci          .fontSize(144)
47e41f4b71Sopenharmony_ci          .fontWeight(FontWeight.Bold)
48e41f4b71Sopenharmony_ci          .fontColor('#ffff0101')
49e41f4b71Sopenharmony_ci          .blendMode(BlendMode.SRC_IN, BlendApplyType.OFFSCREEN)
50e41f4b71Sopenharmony_ci      }
51e41f4b71Sopenharmony_ci     // The first offscreen operation is used to draw the component background.
52e41f4b71Sopenharmony_ci      .blendMode(BlendMode.SRC_OVER, BlendApplyType.OFFSCREEN)
53e41f4b71Sopenharmony_ci      .height('100%')
54e41f4b71Sopenharmony_ci      .width('100%')
55e41f4b71Sopenharmony_ci      .backgroundColor('#ff08ff00')
56e41f4b71Sopenharmony_ci    }
57e41f4b71Sopenharmony_ci  }
58e41f4b71Sopenharmony_ci  
59e41f4b71Sopenharmony_ci  // In the .ets file that uses the original API, two offscreen operations are triggered by default.
60e41f4b71Sopenharmony_ci  @Entry
61e41f4b71Sopenharmony_ci  @Component
62e41f4b71Sopenharmony_ci  struct Index {
63e41f4b71Sopenharmony_ci    build() {
64e41f4b71Sopenharmony_ci      Column() {
65e41f4b71Sopenharmony_ci        // The second offscreen operation is used to draw the subnode content.
66e41f4b71Sopenharmony_ci        Text("test")
67e41f4b71Sopenharmony_ci          .fontSize(144)
68e41f4b71Sopenharmony_ci          .fontWeight(FontWeight.Bold)
69e41f4b71Sopenharmony_ci          .fontColor('#ffff0101')
70e41f4b71Sopenharmony_ci      }
71e41f4b71Sopenharmony_ci      // The first offscreen operation is used to draw the component background.
72e41f4b71Sopenharmony_ci      .blendMode(BlendMode.SRC_IN)
73e41f4b71Sopenharmony_ci      .height('100%')
74e41f4b71Sopenharmony_ci      .width('100%')
75e41f4b71Sopenharmony_ci      .backgroundColor('#ff08ff00')
76e41f4b71Sopenharmony_ci    }
77e41f4b71Sopenharmony_ci  }
78e41f4b71Sopenharmony_ci  ```