1. How to do screenshot in Linux?
- Posted by SocIoDim May 04, 2013
- 1649 views
I need to get screenshots of Virtualbox window (with Windows XP inside). Virtualbox is QT application (I do not know, it's important or not). Of course, screenshot of entire screen is enough. By the way, euphoria is useful for image manipulation? I need to search for little images (characters) in the main image. Something like a very primitive OCR.
2. Re: How to do screenshot in Linux?
- Posted by cargoan May 06, 2013
- 1595 views
There are different methods.
3. Re: How to do screenshot in Linux?
- Posted by SocIoDim May 06, 2013
- 1533 views
There are different methods.
OK. I understand, commands in Linux even simpler than DLL in Windows. Althouth I don't understand other thing. How to run external command (for example, xwd) from inside Euphoria-script? How to put result (for example, screenshot in BMP format) to variable (sequence)?
4. Re: How to do screenshot in Linux?
- Posted by cargoan May 06, 2013
- 1506 views
See system/system_exec builtins and read_bitmap/save_bitmap in std/image.e library.
5. Re: How to do screenshot in Linux?
- Posted by SocIoDim May 07, 2013
- 1484 views
See system/system_exec builtins and read_bitmap/save_bitmap in std/image.e library.
Do I understand correctly that I have to use temporary files? I was hoping that the Euphoria allows me to work in the style of piping. Something similar to this:
sequence MySystemIs = stdout_of(system_exec("uname")) -- MySystemIs = "Linux"
6. Re: How to do screenshot in Linux?
- Posted by ghaberek (admin) May 07, 2013
- 1496 views
Do I understand correctly that I have to use temporary files? I was hoping that the Euphoria allows me to work in the style of piping. Something similar to this:
sequence MySystemIs = stdout_of(system_exec("uname")) -- MySystemIs = "Linux"
Euphoria does indeed have Pipe Input/Output. You just have to use pipeio:exec() instead of system_exec().
include std/pipeio.e function stdout_of( sequence command ) sequence data = {} object p = pipeio:exec( command, pipeio:create() ) object buff = pipeio:read( p[STDOUT], 256 ) while sequence(buff) and length(buff) do data &= buff buff = pipeio:read( p[STDOUT], 256 ) end while return data end function sequence MySystemIs = stdout_of( "uname" )
-Greg
7. Re: How to do screenshot in Linux?
- Posted by SocIoDim May 07, 2013
- 1462 views
This is something incredible! The euphoria even more comfortable than I expected. Thank you.
8. Re: How to do screenshot in Linux?
- Posted by petersalvatore Jul 30, 2013
- 1392 views
A very primitive OCR? I am a little confused by your words. I only konw that there are two basic types of core OCR algorithm, which may produce a ranked list of candidate characters. Matrix matching involves comparing an image to a stored glyph on a pixel-by-pixel basis; it is also known as "pattern matching" or "pattern recognition". This relies on the input glyph being correctly isolated from the rest of the image, and on the stored glyph being in a similar font and at the same scale. This technique works best with typewritten text and does not work well when new fonts are encountered. This is the technique the early physical photocell-based OCR implemented, rather directly. Feature extraction decomposes glyphs into "features" like lines, closed loops, line direction, and line intersections. These are compared with an abstract vector-like representation of a character, which might reduce to one or more glyph prototypes. General techniques of feature detection in computer vision are applicable to this type of OCR, which is commonly seen in "intelligent" handwriting recognition and indeed most modern OCR software. Nearest neighbour classifiers such as the k-nearest neighbors algorithm are used to compare image features with stored glyph features and choose the nearest match. Software such as Cuneiform and Tesseract use a two-pass approach to character recognition. The second pass is known as "adaptive recognition" and uses the letter shapes recognized with high confidence on the first pass to better recognize the remaining letters on the second pass. This is advantageous for unusual fonts or low-quality scans where the font is distorted (e.g. blurred or faded). But you said you want to do screenshot in Linux, I think the simpler way is using an image processing SDK whose way of processing is simple and fast to help you with that project. It can save a lot of time for you. And you'd better try its free trial package first before you make your decision. I hope you success. Good luck.
Best regards,
Arron
9. Re: How to do screenshot in Linux?
- Posted by Lnettnay Jul 31, 2013
- 1318 views
If you know he's running Linux why are you suggesting he use a .Net library?