Closed pratikbutani closed 3 years ago
can you please tell me how did you take font file in android?
can you please tell me how did you take the font file in android?
You need to save the font file into a folder before loading and give the absolute path of that file.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Description I am running the following command to write text on video. Its writing text on video successfully but If I use 2-3 lines, it's wrapping out the video.
String command = "-i '" + videoPath + "' -vf \"drawtext=fontsize=20:fontcolor=White:fontfile=" + fontFile.getAbsolutePath() + ":text='" + myTwoThreeLines + "':x=(w-text_w)/2:y=(h-10-text_h)\" -b:v 5M -codec:a copy '" + mDestinationPath +"'";
Expected behavior I want to give some padding left and right side so the text does not wrap and display properly with some space both sides. It must become in the next line If text is bigger then the video's width.
Current behavior It's wrapping out the text outsides the video.
Screenshots
Environment