Skip to main content

A package to easily create windows in Python using GLFW, OpenCV-Python, NumPy, pywin32 and ctypes.

Project description

SimpleWindow

A package to easily create windows in Python using GLFW, OpenCV-Python, NumPy, pywin32 and ctypes.

Installation

pip install SimpleWindow

Usage

import SimpleWindow
import numpy as np

# Initialize the window, the window wont be shown until Show() is called
SimpleWindow.Initialize(Name="Example Window",
                        Size=(1280, 720),
                        Position=(100, 100), 
                        TitleBarColor=(0, 0, 0),
                        Resizable=True,
                        TopMost=False,
                        Foreground=True,
                        Minimized=False,
                        Undestroyable=False,
                        Icon="",
                        NoWarnings=False)

# Create an image
Image = np.zeros((720, 1280, 3), dtype=np.uint8)

while True:
    # The window will be shown now since its the first call of Show() since the Initialize() call
    SimpleWindow.Show(Name="Example Window", Frame=Image)

    # Get the window open state
    WindowIsOpen = SimpleWindow.GetOpen(Name="Example Window")

    # If the value is False then the window was destroyed by the code, if the value is None then the window got destroyed by the user
    if WindowIsOpen == False or WindowIsOpen == None:
        break

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

simplewindow-0.16.tar.gz (43.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

SimpleWindow-0.16-py3-none-any.whl (31.2 kB view details)

Uploaded Python 3

File details

Details for the file simplewindow-0.16.tar.gz.

File metadata

  • Download URL: simplewindow-0.16.tar.gz
  • Upload date:
  • Size: 43.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for simplewindow-0.16.tar.gz
Algorithm Hash digest
SHA256 f4babcdcdb3f460666fefc126f6c97134b0872ca922d80e4b65afcf44397b810
MD5 e95120c7c4622c16985397f51c16c45b
BLAKE2b-256 5740ffc80dfee5baa2dde8288154ecc972cb7fe807b9a1af0b4fdcadfaf2aaf8

See more details on using hashes here.

File details

Details for the file SimpleWindow-0.16-py3-none-any.whl.

File metadata

  • Download URL: SimpleWindow-0.16-py3-none-any.whl
  • Upload date:
  • Size: 31.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for SimpleWindow-0.16-py3-none-any.whl
Algorithm Hash digest
SHA256 57426422b00cdc29f9af86d91cb680695f45b7fdff65a70b8b2f70915b9f4fbe
MD5 2b3ed5ddf629125501e4e885bf436121
BLAKE2b-256 cea4bb0d1f34b7de585ce27cec62efc3ee0075ed63251d271cd0703f8f2dc92c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page