Giter VIP home page Giter VIP logo

maim's Introduction

maim

maim (Make Image) is a utility that takes screenshots of your desktop. It's meant to overcome shortcomings of scrot and performs better in several ways.

Features

  • Takes screenshots of your desktop, and saves it in png, jpg, or bmp format.
  • Takes screenshots predetermined regions or windows, useful for automation.
  • Allows a users to select a region, or window, before taking a screenshot on the fly.

screenshot with selection

  • Blends the system cursor to the screenshot. screenshot with cursor
  • Masks off-screen pixels to be transparent or black.

screenshot with masked pixels

  • Maim cleanly pipes screenshots directly to standard output (unless otherwise specified). Allowing for command chaining.
  • Maim supports anything slop does, even selection shaders!

slop animation

Installation

Install using your Package Manager (Preferred)

Install using CMake (Requires CMake, git, libXrender, libXfixes, libGLM, libxcomposite, libxrandr, libxext, GLEW)

git clone https://github.com/naelstrof/slop.git
cd slop
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="/usr" ./
make && sudo make install
cd ..
git clone https://github.com/naelstrof/maim.git
cd maim
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="/usr" ./
make && sudo make install

Examples

Maim allows for a lot of unique and interesting functionalities. Here's an example of a few interactions.

  • This command will allow you to select an area on your screen, then copy the selection to your clipboard. This can be used to easily post images in mumble, discord, gimp-- or any other image supporting application.
$ maim -s | xclip -selection clipboard -t image/png
  • This messy command forces a user to select a window to screenshot, then applies a shadow effect using imagemagick, then saves it to shadow.png. It looks really nice on windows that support an alpha channel.
$ maim -st 9999999 | convert - \( +clone -background black -shadow 80x3+5+5 \) +swap -background none -layers merge +repage shadow.png
  • This command is a particular favorite of mine, invented by a friend. It simply prints the RGB values of the selected pixel. A basic color picker that has the additional ability to average out the pixel values of an area. If used cleverly with the geometry and window flag, the return color might warn you of a found counter-strike match...
$ maim -st 0 | convert - -resize 1x1\! -format '%[pixel:p{0,0}]' info:-
  • This is a basic, but useful command that simply screenshots the current active window.
$ maim -i $(xdotool getactivewindow) ~/mypicture.jpg
  • This is another basic command, but I find it necessary to describe the usefulness of date. This particular command creates a full screenshot, and names it as the number of seconds that passed since 1970. Guaranteed unique, already sorted, and easily read.
$ maim ~/Pictures/$(date +%s).png
  • This one overlays a still of your desktop, then allows you to crop it. Doesn't play well with multiple monitors, but I'm sure if it did it wouldn't look this pretty and simple.
$ maim | feh - -x & maim -s cropped.png
$ maim -s /tmp/screenshot.png; imgur.sh /tmp/screenshot.png | xclip -selection clipboard
  • The following command can be used to select a QR code (or click into a window where a QR code is present), decode it, print the text to the console and copy the text into the clipboard for further usage.
$ maim -qs | zbarimg -q --raw - | xclip -selection clipboard -f

maim's People

Contributors

9ary avatar akamch avatar alezost avatar avalonv avatar awused avatar aymenq avatar carlasouza avatar chadrik avatar chrisduerr avatar conradludgate avatar david-duncan avatar emanuelduss avatar feugenea avatar foxpy avatar issmirnov avatar johnnynator avatar lilyinstarlight avatar llenck avatar lonami avatar markusg avatar mbakke avatar mimoralea avatar naelstrof avatar narthorn avatar neelchauhan avatar raboof avatar shadowkyogre avatar soapgentoo avatar tumlinh avatar veryjos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.