GithubHelp home page GithubHelp logo

andrewhazelden / silhouettefx-python-scripts Goto Github PK

View Code? Open in Web Editor NEW
15.0 4.0 3.0 375 KB

A collection of Python scripts for SilhouetteFX v7+.

License: GNU General Public License v3.0

Python 100.00%
compositing nodes vfx pipeline python pyside2 silhouette

silhouettefx-python-scripts's Introduction

SilhouetteFX Python Scripts - v1.1 2020-10-27


Created By: Andrew Hazelden
Email: [email protected]
Web: http://www.andrewhazelden.com

Overview

This is a collection of custom python scripts for SilhouetteFX v7.x. These tools help to improve the sfx node based compositing experience and make the artist more productive. (Note: These scripts haven't been updated for use in v2020 yet as the sfx python API is slighlty different.)

SFX Logo

Actions Menu Items

  • Developer
    • Actions Explorer
    • Environment Explorer
    • Hook Explorer
    • IO Modules Explorer
    • Node Explorer
    • Preference Explorer
    • Project Explorer
    • Reveal Actions in Finder
    • Reveal Scripts in Finder
    • Session Explorer
  • Encode Movie
    • MP4
    • ProRes
    • YouTube LQ
  • Send To
    • Affinity Photo
    • DJV View
  • Tools
    • Output To Source
    • Reveal in Finder
    • SplitEXR

Keybind Hotkeys

  • "g" hotkey runs a node alignment script
  • "r" hotkey runs a "Reveal in Finder" script
  • "Tab" hotkey runs a "Send To > DJV View" script

The "SplitEXR" functionality is also embedded into the keybinds file so you get auto-magic drag-and-drop EXR channel expansion when you drag an EXR image from your desktop into the SilhouetteFX tree "nodes view" area.

Here's a short video clip of the drag-and-drop plus the SplitEXR tools in action:
https://www.youtube.com/watch?v=is82luQSf7A

Node Alignment Script

Node Alignment

There is a custom PySide2 based Node Alignment tool that is embedded in the keybinds_snippets.py file. Paste this file's contents into the top of the sfx scripts/keybinds.py file and then restart Silhouette.

You can use the Node Alignment tool when you are working in the sfx "Tree" view. Select several nodes and then press the "g" hotkey to display the Node Alignment floating window.

Clicking the first "X" button in the window will close the floating view you don't want to use any of the buttons in the window.

Here's a short video clip of the node alignment tools in action:
https://www.youtube.com/watch?v=dMrfnLQZtMs

Install

  1. Download the contents of the SilhouetteFX-Python-Scripts repository.

  2. Open Scripts folder, and copy the compressor and icons resources to your SilhouetteFX Ressources/scripts/ folder. On macOS that is located at:

/Applications/SilhouetteFX/Silhouette v7.5/Silhouette.app/Contents/Resources/scripts/

  1. Copy the .py scripts from inside the scripts/actions/ folder into your SilhouetteFX Ressources/scripts/actions/ folder. On macOS that is located at:

/Applications/SilhouetteFX/Silhouette v7.5/Silhouette.app/Contents/Resources/scripts/actions/

  1. Open the scripts/actions/keybinds_snippets.py Python script in a programmer's text editor. This file has a snippet of custom code that provides drag and drop support, along with Trees view grid layout snapping tools. You need to add this content via copy/paste to the top of the SilhouetteFX's built-in keybinds.py file by replacing this text area with the new code:

     import fx
    
     #
     # Helper function which returns a function that calls
     # a specified method of an object, passing in the argument list.
     # Used to replace 'lambda', which is being phased out
     #
     def callMethod(func, *args, **kwargs):
     	def _return_func():
     		return func(*args, **kwargs)
     	return _return_func
    

SilhouetteFX's built-in keybinds.py file is located at:

/Applications/SilhouetteFX/Silhouette v7.5/Silhouette.app/Contents/Resources/scripts/keybinds.py

Note: It's a good idea to save a copy of your original keybinds.py file as keybinds.bak when you edit it.

  1. Edit the keybinds.py file and change the entries below to point to the correct paths for your current SilhouetteFX install:

SaveByCSV() / AlignByCSV() Functions:

path = '/Applications/SilhouetteFX/Silhouette v7.5/Silhouette.app/Contents/Resources/scripts/node_shape.csv'

SnapDialog() Function:

iconFolder = '/Applications/SilhouetteFX/Silhouette v7.5/Silhouette.app/Contents/Resources/scripts/icons/'

runDJV() Function:

cmd = "/Applications/DJV.app/Contents/Resources/bin/djv_view.sh"

Screenshots

Developer Menu

Encode Menu

Send To Menu

Actions Menu

Last Revised 2020-10-27

silhouettefx-python-scripts's People

Contributors

andrewhazelden avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  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.