Metadata-Version: 1.1
Name: mss
Version: 0.0.4
Summary: A cross-platform multi-screen shot module in pure python using ctypes
Home-page: https://github.com/BoboTiG/python-mss
Author: Tiger-222
Author-email: contact@tiger-222.fr
License: UNKNOWN
Description: **********************************************************************
        A cross-platform multi-screen shot module in pure python using ctypes
        **********************************************************************
        
        Very basic, it will grab one screen shot by monitor or a screen shot of all monitors and save it to an optimised PNG file, Python 2.7/3.3 compatible.
        
        So, while you can `pip install mss`, you may just drop it in your project and forget about it.
        
        MSS stands for Multi-Screen Shot.
        
        It's under zlib licence.
        
        
        Instance the good class
        ========================
        
        You can determine automatically which class to use::
        
            from platform import system
            from mss import *
        
            systems = {
                'Darwin' : MSSMac,
                'Linux'  : MSSLinux,
                'Windows': MSSWindows
            }
            try:
                MSS = systems[system()]
            except KeyError:
                err = 'System "{0}" not implemented.'.format(system())
                raise NotImplementedError(err)
        
        Or simply import the good one::
        
            from mss import MSSLinux as MSS
        
        
        init(debug=False)
        -----------------
        
        When initalising an instance of MSS, you can enable debug output::
        
            mss = MSS(debug=True)
        
        
        save(output='mss', oneshot=False)
        -----------------------------------------------------
        
        For each monitor, grab a screen shot and save it to a file.
        
        Parameters::
        
            output - string - the output filename without extension
            oneshot - boolean - grab only one screen shot of all monitors
        
        This is a generator which returns created files::
        
            'output-1.png',
            'output-2.png',
            ...,
            'output-NN.png'
            or
            'output-full.png'
        
        
        Example
        ========
        
        Then, it is quite simple::
        
            try:
                mss = MSS()
        
                # One screen shot per monitor
                for filename in mss.save():
                    print('File "{0}" created.'.format(filename))
        
                # A shot to grab them all :)
                for filename in mss.save(oneshot=True):
                    print('File "{0}" created.'.format(filename))
            except Exception as ex:
                print(ex)
                raise
        
        
        Bonus
        ======
        
        Just for fun ...
        Show us your screen shot with all monitors in one file, we will update the gallery.
        
        Link to the galley: https://tiger-222.fr/tout/python-mss/galerie/
        
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Information Technology
Classifier: License :: OSI Approved :: zlib/libpng License
Classifier: Natural Language :: English
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.6
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.0
Classifier: Programming Language :: Python :: 3.1
Classifier: Programming Language :: Python :: 3.2
Classifier: Programming Language :: Python :: 3.3
Classifier: Topic :: Multimedia :: Graphics :: Capture :: Screen Capture
