Text overlapping in video processing Matlab - matlab

I'm a fresher to matlab, and I'm trying to extract text from video using ocr methods. My problem is, there is same text appearing in consecutive frames, and sometimes when camera is panning new parts of already extracted text will reveal and I have to add those to already extracted text. Both makes it difficult to store a text only once if it appear in video once while playing. Text usually are name boards or road side boards having text which are captured in the video. How to solve this problem?

Related

Rectangular box to scan/analyze on the camera preview with Flutter Google-ml-kit Text Recognition

There's an example app using on-device Text Recognition of Google ML Kit: https://github.com/bharat-biradar/Google-Ml-Kit-plugin/tree/master/example
I'm using the "text recognition" part of that example app in my app and it works good. The only thing I need to do but can't do is that I want to show a rectangular box on the camera preview and only want to recognize texts inside this box. Other parts of the preview should be ignored. Otherwise, all the text in the preview would be recognized which is bad for my use case.
It's easy to show a rectangular box on the camera preview but I don't know how to only analyze the part in that rectangular box instead of the whole preview. Any help please?
There are two ideas you can consider:
(1) Crop your camera preview down to only the rectangular box and feed that cropped image to the ML Kit API.
(2) ML Kit's Text Recognition API returns a bounding box on Android (and frame on iOS). You can use that to determine if any of the text recognition results falls into or overlaps with your rectangular box. Depending on your use case and the input image, this approach may not be ideal since it can return text recognition result for text not entirely inside your rectangle.

Invisible Video Watermark

I am doing a project in invisible Video Watermarking in Matlab. But I don't know where to start and how to do it. All I can find is visible watermark on the video. Can anyone help?
If you search for the term 'steganographic' in this context it may help - steganography is basically hiding one message in another and some of the academic and basic building block material may favour this term. Some of the video techniques will be strongly related to single image techniques also as the hidden image or watermark, or part of the watermark more commonly, is hidden in individual frames within the video.
Some examples in the MathLab domain:
https://www.mathworks.com/matlabcentral/fileexchange/41326-steganography-using-lsb-substitution?requestedDomain=true
https://sites.google.com/site/cs534steganographyproject/home/matlab-code-and-examples

how to use melt to do video overlay? It's just like a PiP(picture in picture)

I want to use melt.exe (command line video editor) to do something with video overlay. It's like overlay a video on the other that I can control the size and position of the video which will be placed. I have done this with shotcut and view the xml it generates.
But I want to know how can I do this with melt command script. Or if I have known all the information about video overlay such as in/out points, size, position, and how to create a xxx.mlt(xml) file according to these info?
I got the three videos overlaied to generate one like this :
final effect
I use shotcut to do this and I get a .mlt file. sorry I don't know how to upload the xml file or maybe it can't be.
So I want to know how to do the same thing with melt.exe?

Unity How do I Flow TextMesh Pro Text around an Image?

Unity Version: 5.6.5f1 Personal
TextMesh Pro Version: 1.0.56.0b3
I have a TextMesh Pro UI Text object whose area intersects the area of a UI Image. The text is dynamic, but the image will never change. Is there a way to make the TextMesh Pro UI Text flow around the image similar to how text would wrap to one side in HTML/CSS?
The image below shows two copies of the object in Unity. One object, denoted by a red space where the image is located, is what I'm currently getting. The text enters the space of the image. The other object, denoted by a blue space where the image is located, shows the desired outcome where text is wrapping properly.
Current vs. Desired Outcome:
Research so far:
How do I put an image inside text? - The Image that I'm using is a UI Image, not a text asset. The Image will only act as though it is inline with the text.
How do you wrap text around a rectangle?, Fluid layout for Unity UI - These are what I'm looking for. However, no suggestions have been posted in them.
I've explored the idea of using multiple TextMesh Pro UI Text Objects, with each one acting as a fragment of the complete text area. However, this isn't the same as wrapping the text around the Image. For dynamic text, if I pull content from one text area and push it into the next area, this will conflict with the Auto-Sizing functionality and cause unequal font sizes.
Another possibility is that I could insert characters one at a time, check to see if adding another character would result in a collision with the image, and add System.Environment.Newline to prevent this. However, I worry about the potential performance issues from dealing with large amounts of text.
TextMesh Pro Documentation - The TextMesh Pro Documentation has some tools for finding word wrap points, but I haven't figured out how to implement a means of comparing this to an anchor position of another object.
This can be accomplished with TextMeshPro's "Linked" overflow mode. See attached picture for an example. Essentially, you'll need to make two TMP objects and adjust the layout for each of them appropriately. Then:
1) change the overflow mode of the first one to "Linked" using the dropdown in the inspector.
2) place the second TMP object as the reference in the field that appears.

Is it possible to overlay dynamic boxes over a live video feed in matlab?

I'm doing an object recognition project and would like to actively see objects being recognized in a video feed. This requires the object be boxed around in the live feed. The box would automatically adjust in size depending on the size of the object.
Is this possible in matlab?
Assuming you can do it for an image, just do it for every image and you have done it for the video.
If this is too slow, you may only want to calculate the box for every nth image.
In case you want a more detailed answer, please show where you get stuck.