Python Interactive Graphical System made during Computer Graphics classes (INE5420-2021.1)

Overview

PY-IGS - The PYthon Interactive Graphical System

PY-IGS

The PY-IGS

Installation

To install this software you will need these dependencies (with their thevelopment libraries):

  • Numba/SciPy/NumPy Compatible Setup (https://numba.readthedocs.io/en/stable/user/installing.html) (Use for C matrix multiplication)
  • Gtk 3.20+
  • PyGOBject Dependencies (libgirepository1.0-dev gcc libcairo2-dev pkg-config python3-dev gir1.2-gtk-3.0)
  • Python 3.8+
  • Poetry (To install it, please visit the official install instructions)

After install them, install python dependencies with:

poetry install

How to Use

Executing

In order to execute this program, run the following command:

poetry run python3 py_igs

Navigation

To navigate through the world, you can use the mouse or the navigation widget.

To move with the mouse, simply click over the viewport and drag your cursor over the screen. The amplitude of this movement is inverse to the scale of the world, enabling a smooth view in your screen.

If you want to use the navigation widget, you need to click on the buttons that are displayed on the navigation grid in the left panel. You can configure the amplitude of this movement with the "Pan Step" field (world units).

For zooming, you can use your mouse scroll or the + and - buttons on the navigation grid. You can configure the zoom ammount with the "Zoom Step" slider (from 0,01% up to 50% each step)

You can also rotate the Window using the upper left and upper right buttons on navigation grid.

Navigation Widget

The navigation widget

Adding Objects

To add an object, you need to click on the "Add" button located in the objects widget. A dialog will popup in your screen.

In this dialog, insert the object name (unique in the scene) then insert the points coordinates of your object. You can select the type of the object by changing the active tab of the dialog. The drawing color can also be defined in this dialog. There is an option to fill wireframes too, just check the filled option when adding the object.

You can also input raw values at the "Text" tab. To use it, declare points using this format: (x1, y1), (x2, y2), ... (Obs: New lines are not allowed).

After that, click on the save button. The object will appear on the world at the given coordinates.

Adding an object

Adding an object

Editing Objects (Transforms)

Clicking in the edit button (in the objects widget) will open the editing dialog. In this window, you can define 3 transformations to apply on the object. They are: Translation, Rotation and Scaling. The translation will move the object over the world. The rotation will rotate the object around a given point that can be the world origin, the object center or a point that you specify. The scale will scale the objects in a "natural" way, i.e., based on the object center.

All transformations are stored in a list that will be merged when applying these transformations to the object.

Editing an object

Editing an object

Removing Objects

Select an object of the object list and then press the remove button in the objects widget. The object will disappear.

Objects Widget

The objects widget

Window Clipping

Currently we support 3 methods for Window clipping, they are:

  • None
  • Cohen-Sutherland
  • Liang-Barsky

To choose it, select the desired method in the Clipping Method option in the Window widget.

Window Widget

The window widget

Import/Export Scenes (Wavefront Object)

In the menu bar, you can select the Scene, then select Open to import objects. A file chooser will pop up and the you need to select the file to import.

To export your scene, click on Scene, then select Save As. Then define were you want to save your .obj (Model) file and then select a location for the .mtl (Materials) file.

Example Files

In the example/objects folder you can find many models that were utilized to test Py-Igs functionalities.


About

Made by Enzo Coelho Albornoz and Gabriel Soares Flores.

Software developed for the Computer Graphics (INE5420-2021.1) course. This course is part of our graduation in Computer Science at the Federal University of Santa Catarina (UFSC).

Window Widget

Made in UFSC

You might also like...
Izy - Python functions and classes that make python even easier than it is

izy Python functions and classes that make it even easier! You will wonder why t

Script that creates graphical representations of Julia an Mandelbrot sets.

Julia and Mandelbrot Picture Maker This simple functions create simple plots of the Julia and Mandelbrot sets. The Julia set require the important par

Macros in Python: quasiquotes, case classes, LINQ and more!

MacroPy3 1.1.0b2 MacroPy is an implementation of Syntactic Macros in the Python Programming Language. MacroPy provides a mechanism for user-defined fu

Python Classes Without Boilerplate

attrs is the Python package that will bring back the joy of writing classes by relieving you from the drudgery of implementing object protocols (aka d

Simple but maybe too simple config management through python data classes. We use it for machine learning.

👩‍✈️ Coqpit Simple, light-weight and no dependency config handling through python data classes with to/from JSON serialization/deserialization. Curre

This is a backport of the BaseExceptionGroup and ExceptionGroup classes from Python 3.11.

This is a backport of the BaseExceptionGroup and ExceptionGroup classes from Python 3.11. It contains the following: The exceptiongroup.BaseExceptionG

WATTS provides a set of Python classes that can manage simulation workflows for multiple codes where information is exchanged at a coarse level

WATTS (Workflow and Template Toolkit for Simulation) provides a set of Python classes that can manage simulation workflows for multiple codes where information is exchanged at a coarse level.

Simple tooling for marking deprecated functions or classes and re-routing to the new successors' instance.

pyDeprecate Simple tooling for marking deprecated functions or classes and re-routing to the new successors' instance

An extended version of the hotkeys demo code using action classes

An extended version of the hotkeys application using action classes. In adafruit's Hotkeys code, a macro is using a series of integers, assumed to be

Releases(v0.6.1)
  • v0.6.1(Aug 6, 2021)

    Changelog

    Import/Export

    • Support to export/import Bezier and B-Spline curves

    Performance

    • 🏎️ Used Numba + SciPy + Numpy to speed up matrix operations 🚀
    Source code(tar.gz)
    Source code(zip)
  • v0.6.0(Jul 27, 2021)

  • v0.5.0(Jul 27, 2021)

    Changelog

    Docs

    • Updated object edit description and screenshot.

    Curves

    • We now support curves! 🥳
    • Added Bezier 2D object type, with blending functions method

    Object Editing

    • You can now add more than three transformations per edit. You can repeat types in any order
    • Object centers keep tracks of all transformation that are in memory (Object center now follows transformations)
    Source code(tar.gz)
    Source code(zip)
  • 0.4.0(Jul 23, 2021)

    Changelog

    Docs

    • Updated docs with the new functionalities.
    • Added UFSC logo

    Clipping

    • Added Cohen-Sutherland line and wireframe clipping.
    • Added Liang-Barsky line and wireframe clipping.
    • Added Cohen Sutherland line and wireframe clipping.

    Object Creation

    • Added option to fill wireframes

    Import/Export

    • Added support for Wavefront Object file type
    Source code(tar.gz)
    Source code(zip)
  • 0.2.3(Jul 7, 2021)

  • 0.2.2(Jul 6, 2021)

    Changelog

    Object Creation

    • Added an option to use raw input with the format (x1, y1), (x2, y2), ...

    Docs

    • Update prints to inform about raw input
    Source code(tar.gz)
    Source code(zip)
  • 0.2.1(Jul 6, 2021)

  • 0.2.0(Jul 3, 2021)

    Changelog

    Objects Editing

    There is a new button that allows the user to transform the objects. These transformations are :

    • Translations
    • Scaling around object center
    • Rotations around:
      • Center of the world
      • Center of the object
      • Any point (arbitrary)

    Object Creation

    The user can now define a drawing color for an object. Simply use the color picker that appears at the object creation.

    Source code(tar.gz)
    Source code(zip)
Owner
Enzo Coelho Albornoz
Hello!!! I'm a brazilian undergrad student of Computer Science on UFSC (Universidade Federal de Santa Catarina).
Enzo Coelho Albornoz
API development made easy: a smart Python 3 API framework

appkernel - API development made easy What is Appkernel? A super-easy to use API framework, enabling API creation from zero to production within minut

156 Sep 28, 2022
Reproduction repository for the MDX 2021 Hybrid Demucs model

Submission This is the submission for MDX 2021 Track A, for Track B go to the track_b branch. Submission Summary Submission ID: 151378 Submitter: defo

Alexandre Défossez 62 Dec 18, 2022
Module for remote in-memory Python package/module loading through HTTP/S

httpimport Python's missing feature! The feature has been suggested in Python Mailing List Remote, in-memory Python package/module importing through H

John Torakis 220 Dec 17, 2022
Just some mtk tool for exploitation, reading/writing flash and doing crazy stuff

Just some mtk tool for exploitation, reading/writing flash and doing crazy stuff. For linux, a patched kernel is needed (see Setup folder) (except for read/write flash). For windows, you need to inst

Bjoern Kerler 1.1k Dec 31, 2022
A Python script made for the Python Discord Pixels event.

Python Discord Pixels A Python script made for the Python Discord Pixels event. Usage Create an image.png RGBA image with your pattern. Transparent pi

Stanisław Jelnicki 4 Mar 23, 2022
Traditionally, there is considerable friction for developers when setting up development environments

This self-led, half-day training will teach participants the patterns and best practices for working with GitHub Codespaces

CSE Labs at Spark 12 Dec 02, 2022
Minutaria is a basic educational Python timer used to learn python and software testing libraries.

minutaria minutaria is a basic educational Python timer. The project is educational, it aims to teach myself programming, python programming, python's

1 Jul 16, 2021
Simple Python tool to check if there is an Office 365 instance linked to a domain.

o365chk.py Simple Python script to check if there is an Office365 instance linked to a particular domain.

Steven Harris 37 Jan 02, 2023
Learn to code in any language. If

Learn to Code It is an intiiative undertaken by Student Ambassadors Club, Jamshoro for students who are absolute begineers in programming and want to

Student Ambassadors' Club at Mehran UET 15 Oct 19, 2022
msgqywx 使用企业微信的应用消息推送实时信息

msgqywx 使用企业微信的应用消息推送实时信息

Demon Finch 8 Dec 18, 2022
SEH-Helper - Binary Ninja plugin for exploring Structured Exception Handlers

SEH Helper Author: EliseZeroTwo A Binary Ninja helper for exploring structured e

Elise 74 Dec 26, 2022
Easily Generate Revolut Business Cards

RevBusinessCardGen Easily Generate Revolut Business Cards Prerequisites Before you begin, ensure you have met the following requirements: You have ins

Younes™ 35 Dec 14, 2022
InverterApi - This project has been designed to take monitoring data from Voltronic, Axpert, Mppsolar PIP, Voltacon, Effekta

InverterApi - This project has been designed to take monitoring data from Voltronic, Axpert, Mppsolar PIP, Voltacon, Effekta

Josep Escobar 2 Sep 03, 2022
K2HASH Python library - NoSQL Key Value Store(KVS) library

k2hash_python Overview k2hash_python is an official python driver for k2hash. Install Firstly you must install the k2hash shared library: curl -o- htt

Yahoo! JAPAN 3 Oct 19, 2022
Extra scripts to improve user experience related to OpenTaiko

OpenTaiko-Utils Extra scripts to improve user experience related to OpenTaiko osu2tja /!\ IMPORTANT NOTE /!\ Converted charts that aren't yours are fo

2 Dec 25, 2022
A python script based on OpenCV-Python, you can automatically hang up the Destiny 2 Throne to get the Dawning Essence.

A python script based on OpenCV-Python, you can automatically hang up the Destiny 2 Throne to get the Dawning Essence.

1 Dec 19, 2021
Batch obfuscator based on the obfuscation method used by the trick bot launcher

Batch obfuscator based on the obfuscation method used by the trick bot launcher

SlizBinksman 2 Mar 19, 2022
A simple calculator made with tkinter.

Simple Calculator A simple calculator made with tkinter. Requirements None, only you need to have windows 😉 ...Enjoy! Installation Clone this reposit

Abhyush 2 Jan 11, 2022
fast_bss_eval is a fast implementation of the bss_eval metrics for the evaluation of blind source separation.

fast_bss_eval Do you have a zillion BSS audio files to process and it is taking days ? Is your simulation never ending ? Fear no more! fast_bss_eval i

Robin Scheibler 99 Dec 13, 2022
The parser of a timetable of tennis matches for Flashscore website

FlashscoreParser The parser of a timetable of tennis matches for Flashscore website. The program collects the schedule of tennis matches for two days

Valendovsky 1 Jul 15, 2022