Giter VIP home page Giter VIP logo

cgcpp's Introduction

Docker Image CI

Computer Graphics C++ (cgcpp)

A universal solution for common needs in C++ in computer graphics software.

Supports

  • Python 2.7, Boost 1.67.0 on Windows
  • Python 3.9, Boost 1.76.0 on Windows
  • Autodesk Maya 2019-2023 on Windows (Python 2.7 and Boost 1.67.0 in Maya 2019-2022, Python 3.9 and Boost 1.76.0 in Maya 2023)
  • SideFX Houdini 19.0-19.5 on Windows (Python 2.7 and Boost 1.67.0 in Houdini 19.0, Python 3.9 and Boost 1.76.0 in Houdini 19.5)

Support for other platforms and other DCC applications may come later.

Features

  • Build inside a docker container (isolated predictable environment)
  • Call library C++ functions from Python
  • Dynamically reload modified libraries (each new call reloads the library and alows it to be updated)
  • Throw Python exceptions from C++

Installation

Install in your Windows Python virtual environment:

python -m pip install git+https://github.com/ababak/cgcpp.git

Build the examples

mkdir out
python -m cgcpp examples/source_exception --out ./out
python -m cgcpp examples/source_maya --out ./out --maya
python -m cgcpp examples/source_houdini --out ./out --houdini

Make sure you have Maya and Houdini versions installed in default locations that correspond to versions listed in CMakeLists.txt

Test built examples

Should throw AttributeError: Some error exception:

python -c 'import cgcpp;cgcpp.call(lib="out/lib_exception", func="call")'

Inside Maya:

import cgcpp
print(cgcpp.call(lib="out/maya_module", func="ls"))

Inside Houdini:

import cgcpp
print(cgcpp.call(lib="out/houdini_module", func="ls"))

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.