Skip to content

Commit 8fceb97

Browse files
committed
fix
1 parent 3d5c943 commit 8fceb97

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

patches/opencv-3.4.20-drawing-mono-font.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ diff -Nuarp opencv-3.4.20.orig/modules/imgproc/src/drawing.cpp opencv-3.4.20/mod
9393

9494
double getFontScaleFromHeight(const int fontFace, const int pixelHeight, const int thickness)
9595
{
96-
+ return pixelHeight / 16.0;
96+
+ return pixelHeight / (fontFace == 1 ? 16 : (fontFace == 5 ? 24 : 40));
9797
+#if 0
9898
// By https://stackoverflow.com/a/27898487/1531708
9999
const int* ascii = getFontData(fontFace);

patches/opencv-4.8.1-drawing-mono-font.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ diff -Nuarp opencv-4.8.1.orig/modules/imgproc/src/drawing.cpp opencv-4.8.1/modul
9393

9494
double getFontScaleFromHeight(const int fontFace, const int pixelHeight, const int thickness)
9595
{
96-
+ return pixelHeight / 16.0;
96+
+ return pixelHeight / (fontFace == 1 ? 16 : (fontFace == 5 ? 24 : 40));
9797
+#if 0
9898
// By https://stackoverflow.com/a/27898487/1531708
9999
const int* ascii = getFontData(fontFace);

0 commit comments

Comments
 (0)