Questions tagged [drawtext]

340 questions
1
vote
1 answer

Center fixed text during canvas scroll in Android

I am trying to create a watermark text to my custom view, but the problem is when I scroll the canvas, I am unable to determine the exact co-ordinates of the screen's center. I tried tracking the onTouchEvent and getting the co-ordinates, but still…
Mal
  • 373
  • 4
  • 15
1
vote
1 answer

Android Compose - Why is drawText in Canvas being cut off at bottom but not at top?

I'm relatively new to Android Compose and as a project, I'm trying to design a bar graph. Gathering various examples, I'm now trying to design the axes in a Canvas composable with a DrawScope. Once I've drawn the lines, my next task was to create…
1
vote
1 answer

How to draw text in Jetpack compose at the center of another object?

I am trying to draw text inside a circle in Jetpack Compose. I drew the circle with the center being the center of the canvas. Now I want to draw text exactly at the center of the circle. The drawText function inside the canvas in Jetpack compose…
1
vote
1 answer

How to add letter spacing in ffmpeg drawtext filter

I am using drawtext in FFMPEG kit to overlay text on an image. I want to increase the spacing between the letters (tracking). How to acheive this. I was only able to find line_spacing but couldnot find letter_spacing Expected to increase the space…
1
vote
2 answers

Qt6 : Applying fonts without any anti-aliasing - any strategy not respected

I'm trying to render text with a QPainter and I do not want anti-aliasing applied. I am fairly new to QT, so might be doing something wrong here. No matter what i've tried there is always some sort of antialiasing. I'll share my code below, which…
NightShade
  • 422
  • 5
  • 19
1
vote
1 answer

How do I make FFMPEG use localized strftime with drawtext?

I'm trying to write a script to use FFMPEG to draw localized timestamps on a video, but I'm not having much luck. I can confirm I have the locale fr_FR.UTF-8 installed on my system by running the following command: LC_ALL=fr_FR.UTF-8 date However,…
1
vote
1 answer

How can I draw text in Swift's CoreGraphics context in a UIImageView?

I'm trying to draw a string in a UIImageView in Swift's CoreGraphics for a dynamic geometry software app. I'm using context graphics for graphing points and lines, but when I try to draw a text string (for example, the length of a line segment), I…
1
vote
0 answers

Not getting accurate time stamp from FFMPEG after converting datetime to Unix

I am creating a video editing application. I have created an ObservableCollection which contains information regarding every frame, 30 per second. I have computed the DateTime per frame as VideoCreationDate + FrameNumber / 29.97. When I display…
Jacob
  • 11
  • 3
1
vote
0 answers

Canvas.drawTextOnPath doesn't scales text along with canvas scale

I am trying to draw a text on curved path. But when I scale up the canvas, text gets blurred. Here's the code I've tried public void draw(Canvas canvas) { float midX = (maxX + minX) / 2; float midY = (maxY + minY) / 2; canvas.save(); …
Bhupesh
  • 477
  • 1
  • 8
  • 22
1
vote
2 answers

error C2665, can't resolve between 2 overloads for System::Windows::Forms::TextRenderer::DrawText

Windows::Forms::TextRenderer::DrawText(gT, numTo100, sfo, Rectangle(2, 2, 12, 12), SystemColors::ControlText); is giving the error 1>error C2665: 'System::Windows::Forms::TextRenderer::DrawText' : none of the 8 overloads could convert all…
John
  • 6,433
  • 7
  • 47
  • 82
1
vote
2 answers

Android Canvas - Position text with drawText in the same location on all screen resolutions

I can't seem to get text positioned in the same places on screens of different resolution. The problem is the text is floating, it's not part of any layout type of control. I try to position the text in relative units compared the screen size. For…
Jason
  • 1,225
  • 2
  • 16
  • 18
1
vote
1 answer

Next drawtext clears the previous one ffmpeg

ffmpeg.exe -i ffmpeg_inputs/zheltiy_chelik.mp4 -vf "[in]drawtext=fonts/Temporarium.otf:text='r':fontcolor=orange:fontsize=100:x=(w-text_w)/2+0:y=0:enable='between(t,0, 11)', drawtext =fonts/Temporarium.otf:text =…
1
vote
1 answer

How to compute length of the text on the path?

I have some path and some text and concrete paint to draw it on canvas by drawTextOnPath method. How to compute how much length it will take on the path? I need it to compute textScaleX value.
1
vote
1 answer

Trying to convert the tick value of Y-Axis Scale in SAS

I'm trying to convert the tick value of Y-Axis Scale from (0 .2 .4 .6 .8 1.0) to (0 .01 .02 .03 .04 .05), but failed. However, no such problem when converting viewmax PROC TEMPLATE; DELETE Stat.Lifetest.Graphics.ProductLimitFailure2; SOURCE…
regmumu
  • 13
  • 4
1
vote
1 answer

When using ffplay, how to eliminate milliseconds from timestamp display in the video-filter

So when specifying a video-filter to display current video-time in 'hms' layout, the filter appends a millisecond value after the seconds-field. I want to eliminate the milliseconds portion. So far, my invoked cmd looks like: ffplay myfile.mp4 -vf…
David
  • 2,253
  • 5
  • 23
  • 29