Home
last modified time | relevance | path

Searched refs:density (Results 1 - 25 of 195) sorted by relevance

12345678

/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/jsview/canvas/
H A Djs_canvas_path.cpp36 double density = GetDensity(); in JsPath2DSetTransform() local
37 path2d_->SetTransform(scaleX, skewX, skewY, scaleY, translateX * density, translateY * density); in JsPath2DSetTransform()
48 double density = GetDensity(); in JsPath2DMoveTo() local
49 path2d_->MoveTo(x * density, y * density); in JsPath2DMoveTo()
60 double density = GetDensity(); in JsPath2DLineTo() local
61 path2d_->LineTo(x * density, y * density); in JsPath2DLineTo()
78 double density in JsPath2DArc() local
94 double density = GetDensity(); JsPath2DArcTo() local
108 double density = GetDensity(); JsPath2DQuadraticCurveTo() local
125 double density = GetDensity(); JsPath2DBezierCurveTo() local
148 double density = GetDensity(); JsPath2DEllipse() local
164 double density = GetDensity(); JsPath2DRect() local
[all...]
H A Djs_canvas_renderer.cpp119 densityCallbackId_ = pipeline->RegisterDensityChangedCallback([self = WeakClaim(this)](double density) { in JSCanvasRenderer()
122 canvasRender->density_ = density; in JSCanvasRenderer()
155 double density = GetDensity(); in JsCreateLinearGradient() local
158 gradient->SetBeginOffset(Offset(x0 * density, y0 * density)); in JsCreateLinearGradient()
159 gradient->SetEndOffset(Offset(x1 * density, y1 * density)); in JsCreateLinearGradient()
176 double density = GetDensity(); in JsCreateRadialGradient() local
179 gradient->SetBeginOffset(Offset(startX * density, startY * density)); in JsCreateRadialGradient()
201 double density = GetDensity(); JsCreateConicGradient() local
216 double density = GetDensity(); JsFillText() local
239 double density = GetDensity(); JsStrokeText() local
266 double density = GetDensity(true); SetDensity() local
321 double density = GetDensity(); JsGetLineDash() local
534 double density = GetDensity(); ExtractInfoToImage() local
619 double density = GetDensity(); JsCreateImageData() local
715 double density = GetDensity(); ParseImageData() local
765 double density = GetDensity(); JsGetImageData() local
804 double density = GetDensity(); JsGetPixelMap() local
1096 double density = GetDensity(); JsMoveTo() local
1107 double density = GetDensity(); JsLineTo() local
1118 double density = GetDensity(); JsBezierCurveTo() local
1135 double density = GetDensity(); JsQuadraticCurveTo() local
1150 double density = GetDensity(); JsArcTo() local
1167 double density = GetDensity(); JsArc() local
1184 double density = GetDensity(); JsEllipse() local
1335 double density = GetDensity(); JsSetTransform() local
1379 double density = GetDensity(); JsTransform() local
1392 double density = GetDensity(); JsTranslate() local
1405 double density = GetDensity(); JsSetLineDash() local
1472 double density = GetDensity(); JsMeasureText() local
[all...]
H A Djs_canvas_pattern.h67 double density = PipelineBase::GetCurrentDensity(); in GetDensity() local
68 return ((GetUnit() == CanvasUnit::DEFAULT) && !NearZero(density)) ? density : 1.0; in GetDensity()
H A Djs_matrix2d.cpp140 double density = GetDensity(); in JsSetTranslateX() local
141 translateX *= density; in JsSetTranslateX()
154 double density = GetDensity(); in JsSetTranslateY() local
155 translateY *= density; in JsSetTranslateY()
191 double density = GetDensity(); in JsGetTranslateX() local
192 translateX /= density; in JsGetTranslateX()
201 double density = GetDensity(); in JsGetTranslateY() local
202 translateY /= density; in JsGetTranslateY()
251 double density = GetDensity(); in JsRotate() local
252 rx *= density; in JsRotate()
271 double density = GetDensity(); JsTranslate() local
[all...]
H A Djs_drawing_rendering_context.h76 double density = PipelineBase::GetCurrentDensity(); in GetDensity() local
77 return ((GetUnit() == CanvasUnit::DEFAULT) && !NearZero(density)) ? density : 1.0; in GetDensity()
H A Djs_canvas_path.h60 double density = PipelineBase::GetCurrentDensity(); in GetDensity() local
61 return ((GetUnit() == CanvasUnit::DEFAULT) && !NearZero(density)) ? density : 1.0; in GetDensity()
H A Djs_canvas_pattern.cpp63 double density = GetDensity(); in JSSetTransform() local
64 param.translateX *= density; in JSSetTransform()
65 param.translateY *= density; in JSSetTransform()
H A Djs_canvas_image_data.h111 double density = PipelineBase::GetCurrentDensity(); in GetDensity() local
112 return ((GetUnit() == CanvasUnit::DEFAULT) && !NearZero(density)) ? density : 1.0; in GetDensity()
/foundation/arkui/ace_engine/frameworks/bridge/cj_frontend/interfaces/cj_ffi/
H A Dcj_pixel_unit_convert_ffi.cpp29 double density = PipelineBase::GetCurrentDensity(); in FfiOHOSAceFrameworkVp2Px() local
30 return value * density; in FfiOHOSAceFrameworkVp2Px()
39 double density = PipelineBase::GetCurrentDensity(); in FfiOHOSAceFrameworkPx2Vp() local
40 if (NearZero(density)) { in FfiOHOSAceFrameworkPx2Vp()
43 return value / density; in FfiOHOSAceFrameworkPx2Vp()
49 double density = PipelineBase::GetCurrentDensity(); in GetFp2PxParam() local
60 return density * fontScale; in GetFp2PxParam()
/foundation/window/window_manager/wm/src/
H A Dwindow_display_change_adapter.cpp71 auto density = displayInfo->GetVirtualPixelRatio(); in OnChange() local
73 if (displayId_ == displayId && NearEqual(density_, density) && orientation_ == orientation) { in OnChange()
78 density_ = density; in OnChange()
80 displayInfoChangeListener_->OnDisplayInfoChange(token_, displayId, density, orientation); in OnChange()
84 DisplayId displayId, float density, DisplayOrientation orientation) in OnDisplayInfoChange()
90 if (displayId_ == displayId && NearEqual(density_, density) && orientation_ == orientation) { in OnDisplayInfoChange()
95 density_ = density; in OnDisplayInfoChange()
97 displayInfoChangeListener_->OnDisplayInfoChange(token, displayId, density, orientation); in OnDisplayInfoChange()
83 OnDisplayInfoChange(const sptr<IRemoteObject>& token, DisplayId displayId, float density, DisplayOrientation orientation) OnDisplayInfoChange() argument
/foundation/ability/ability_runtime/frameworks/native/ability/native/
H A Dconfiguration_utils.cpp85 float density; in InitDisplayConfig() local
87 if (!GetDisplayConfig(displayId, density, direction)) { in InitDisplayConfig()
91 configuration->AddItem(displayId, ConfigurationInner::APPLICATION_DENSITYDPI, GetDensityStr(density)); in InitDisplayConfig()
95 UpdateDisplayResConfig(resourceManager, density, direction); in InitDisplayConfig()
107 float density; in UpdateDisplayConfig() local
109 if (!GetDisplayConfig(displayId, density, direction)) { in UpdateDisplayConfig()
114 newConfig.AddItem(displayId, ConfigurationInner::APPLICATION_DENSITYDPI, GetDensityStr(density)); in UpdateDisplayConfig()
126 UpdateDisplayResConfig(resourceManager, density, direction); in UpdateDisplayConfig()
135 std::shared_ptr<ResourceManager> resourceManager, Rosen::DisplayId displayId, float density, int32_t orientation) in InitDisplayConfig()
143 configuration->AddItem(displayId, ConfigurationInner::APPLICATION_DENSITYDPI, GetDensityStr(density)); in InitDisplayConfig()
134 InitDisplayConfig(std::shared_ptr<Configuration> configuration, std::shared_ptr<ResourceManager> resourceManager, Rosen::DisplayId displayId, float density, int32_t orientation) InitDisplayConfig() argument
149 UpdateDisplayConfig(std::shared_ptr<Configuration> configuration, std::shared_ptr<ResourceManager> resourceManager, Rosen::DisplayId displayId, float density, Rosen::DisplayOrientation orientation) UpdateDisplayConfig() argument
174 GetDisplayConfig(Rosen::DisplayId displayId, float &density, std::string &directionStr) GetDisplayConfig() argument
193 UpdateDisplayResConfig(std::shared_ptr<ResourceManager> resourceManager, float &density, std::string &direction) UpdateDisplayResConfig() argument
[all...]
/foundation/window/window_manager/wm/test/unittest/
H A Dwindow_display_change_adapter_test.cpp35 void OnDisplayInfoChange(const sptr<IRemoteObject>& token, DisplayId displayId, float density,
39 density_ = density;
100 float density = 0.2f; in HWTEST_F() local
103 window->OnDisplayInfoChange(targetToken, displayId, density, orientation); in HWTEST_F()
105 window->OnDisplayInfoChange(targetToken, displayId, density, orientation); in HWTEST_F()
108 ASSERT_EQ(density, listener->density_); in HWTEST_F()
/foundation/arkui/ace_engine/frameworks/core/pipeline/base/
H A Dflutter_render_context.cpp119 auto density = context->GetDensity(); in SetOffSet() local
122 if (!NearZero(density)) { in SetOffSet()
125 renderPost.GetX() / density - renderPost.GetX(), renderPost.GetY() / density - renderPost.GetY()); in SetOffSet()
126 pluginOffset = { renderPost.GetX() / density - renderPost.GetX(), in SetOffSet()
127 renderPost.GetY() / density - renderPost.GetY() }; in SetOffSet()
129 layer->SetOffset(pos.GetX() / density, pos.GetY() / density); in SetOffSet()
130 pluginOffset = { pos.GetX() / density, pos.GetY() / density }; in SetOffSet()
[all...]
/foundation/arkui/ace_engine/frameworks/core/components/plugin/
H A Drosen_render_plugin.cpp63 auto density = context->GetDensity(); in NotifyPaintFinish() local
69 if (density > 0 && rsNode) { in NotifyPaintFinish()
70 rsNode->SetFramePositionX(renderPost.GetX() / density - renderPost.GetX()); in NotifyPaintFinish()
71 rsNode->SetFramePositionY(renderPost.GetY() / density - renderPost.GetY()); in NotifyPaintFinish()
/foundation/arkui/ace_engine/frameworks/core/components/common/layout/
H A Dscreen_system_manager.h56 void SetWindowInfo(double screenWidth, double density, double dipScale) in SetWindowInfo() argument
59 density_ = density; in SetWindowInfo()
61 viewScale_ = density / dipScale; in SetWindowInfo()
64 void SetWindowInfo(double density, double dipScale) in SetWindowInfo() argument
66 density_ = density; in SetWindowInfo()
68 viewScale_ = density / dipScale; in SetWindowInfo()
/foundation/ability/ability_runtime/interfaces/kits/native/ability/native/
H A Dconfiguration_utils.h86 * @param density display density
90 std::shared_ptr<ResourceManager> resourceManager, Rosen::DisplayId displayId, float density,
99 * @param density display density
104 std::shared_ptr<ResourceManager> resourceManager, Rosen::DisplayId displayId, float density,
108 bool GetDisplayConfig(Rosen::DisplayId displayId, float &density, std::string &directionStr);
109 void UpdateDisplayResConfig(std::shared_ptr<ResourceManager> resourceManager, float &density,
/foundation/arkui/ace_engine/interfaces/inner_api/ace/
H A Dviewport_config.h26 ViewportConfig(int32_t width, int32_t height, float density) in ViewportConfig() argument
27 : width_(width), height_(height), density_(density) in ViewportConfig()
63 void SetDensity(float density) in SetDensity() argument
65 density_ = density; in SetDensity()
114 config.append(" density: " + std::to_string(density_)); in ToString()
/foundation/resourceschedule/background_task_mgr/services/test/unittest/mock/include/
H A Dmock_resource_manager_impl.h305 * @param density the screen density, within the area of OHOS::Global::Resource::ScreenDensity
308 virtual RState GetMediaById(uint32_t id, std::string &outValue, uint32_t density = 0);
314 * @param density the screen density, within the area of OHOS::Global::Resource::ScreenDensity
317 virtual RState GetMediaByName(const char *name, std::string &outValue, uint32_t density = 0);
369 * @param density the screen density, within the area of OHOS::Global::Resource::ScreenDensity
373 uint32_t density = 0);
380 * @param density th
[all...]
/foundation/resourceschedule/background_task_mgr/services/test/unittest/mock/
H A Dmock_resource_manager.cpp197 RState ResourceManagerImpl::GetMediaById(uint32_t id, std::string &outValue, uint32_t density) in GetMediaById() argument
202 RState ResourceManagerImpl::GetMediaByName(const char *name, std::string &outValue, uint32_t density) in GetMediaByName() argument
233 uint32_t density) in GetMediaDataById()
239 uint32_t density) in GetMediaDataByName()
244 RState ResourceManagerImpl::GetMediaBase64DataById(uint32_t id, std::string &outValue, uint32_t density) in GetMediaBase64DataById() argument
249 RState ResourceManagerImpl::GetMediaBase64DataByName(const char *name, std::string &outValue, uint32_t density) in GetMediaBase64DataByName() argument
286 std::unique_ptr<uint8_t[]> &outValue, uint32_t density) in GetDrawableInfoById()
292 std::unique_ptr<uint8_t[]> &outValue, uint32_t density) in GetDrawableInfoByName()
332 std::unique_ptr<uint8_t[]> &outValue, uint32_t iconType, uint32_t density) in GetDrawableInfoById()
339 std::unique_ptr<uint8_t[]> &outValue, uint32_t iconType, uint32_t density) in GetDrawableInfoByName()
232 GetMediaDataById(uint32_t id, size_t &len, std::unique_ptr<uint8_t[]> &outValue, uint32_t density) GetMediaDataById() argument
238 GetMediaDataByName(const char *name, size_t &len, std::unique_ptr<uint8_t[]> &outValue, uint32_t density) GetMediaDataByName() argument
285 GetDrawableInfoById(uint32_t id, std::string &type, size_t &len, std::unique_ptr<uint8_t[]> &outValue, uint32_t density) GetDrawableInfoById() argument
291 GetDrawableInfoByName(const char *name, std::string &type, size_t &len, std::unique_ptr<uint8_t[]> &outValue, uint32_t density) GetDrawableInfoByName() argument
330 GetDrawableInfoById(uint32_t id, std::tuple<std::string, size_t, std::string> &drawableInfo, std::unique_ptr<uint8_t[]> &outValue, uint32_t iconType, uint32_t density) GetDrawableInfoById() argument
337 GetDrawableInfoByName(const char *name, std::tuple<std::string, size_t, std::string> &drawableInfo, std::unique_ptr<uint8_t[]> &outValue, uint32_t iconType, uint32_t density) GetDrawableInfoByName() argument
[all...]
/foundation/ability/ability_base/interfaces/kits/native/configuration/include/
H A Dconfiguration_convertor.h30 Global::Resource::ScreenDensity ConvertDensity(float density);
31 Global::Resource::ScreenDensity ConvertDensity(std::string density);
45 std::string GetDensityStr(float density);
/foundation/arkui/ace_engine/adapter/preview/entrance/samples/
H A Dace_card_test.cpp49 constexpr double density = 2; member
56 constexpr double density = 1; member
63 constexpr double density = 2; member
88 .deviceConfig.density = density, in main()
H A Dace_phone_test.cpp45 constexpr double density = 2; member
53 constexpr double density = 1; member
61 constexpr double density = 2; member
85 .deviceConfig.density = density, in main()
/foundation/bundlemanager/bundle_framework/services/bundlemgr/src/bundle_resource/
H A Dbundle_resource_drawable.cpp51 const int32_t density, in GetIconResourceByTheme()
63 return GetIconResourceByHap(iconId, density, resourceManager, resourceInfo); in GetIconResourceByTheme()
70 Global::Resource::RState state = resourceManager->GetThemeIcons(iconId, foregroundInfo, backgroundInfo, density, in GetIconResourceByTheme()
100 const int32_t density, in GetIconResourceByHap()
113 iconId, resourceManager, state, drawableType, density); in GetIconResourceByHap()
49 GetIconResourceByTheme( const uint32_t iconId, const int32_t density, std::shared_ptr<Global::Resource::ResourceManager> resourceManager, ResourceInfo &resourceInfo) GetIconResourceByTheme() argument
98 GetIconResourceByHap( const uint32_t iconId, const int32_t density, std::shared_ptr<Global::Resource::ResourceManager> resourceManager, ResourceInfo &resourceInfo) GetIconResourceByHap() argument
/foundation/window/window_manager/dm/src/
H A Dscreen.cpp247 // Calculate display density, Density = Dpi / 160. in SetDensityDpi()
248 float density = static_cast<float>(dpi) / 160; // 160 is the coefficient between density and dpi. in SetDensityDpi() local
249 return SingletonContainer::Get<ScreenManagerAdapter>().SetVirtualPixelRatio(GetId(), density); in SetDensityDpi()
259 float density = static_cast<float>(dpi) / 160; // 160 is the coefficient between density and dpi. in SetDensityDpiSystem() local
260 return SingletonContainer::Get<ScreenManagerAdapter>().SetVirtualPixelRatioSystem(GetId(), density); in SetDensityDpiSystem()
269 // Calculate display density, Density = Dpi / 160. in SetResolution()
270 float density = static_cast<float>(dpi) / 160; // 160 is the coefficient between density an in SetResolution() local
[all...]
/foundation/ability/ability_base/interfaces/kits/native/configuration/src/
H A Dconfiguration_convertor.cpp86 Global::Resource::ScreenDensity ConvertDensity(float density) in ConvertDensity() argument
98 float deviceDpi = density * DPI_BASE; in ConvertDensity()
109 Global::Resource::ScreenDensity ConvertDensity(std::string density) in ConvertDensity() argument
123 if (tempdensity == density) { in ConvertDensity()
231 std::string GetDensityStr(Global::Resource::ScreenDensity density) in GetDensityStr() argument
245 if (dpi == density) { in GetDensityStr()
253 std::string GetDensityStr(float density) in GetDensityStr() argument
255 return GetDensityStr(ConvertDensity(density)); in GetDensityStr()

Completed in 219 milliseconds

12345678