Blender addon to launch custom scripts from the User Panel
Go to file
christophe.seux f1aaa1dfca clean + add collection 2024-10-03 12:07:33 +02:00
shelves Detailed shelves structure 2022-03-16 10:30:54 +00:00
.gitignore custom_shelf initial commit 2022-03-04 12:28:53 +01:00
ISSUE_TEMPLATE.yml Update from template 2023-07-21 11:39:01 +02:00
LICENSE Add LICENSE 2022-03-04 12:02:46 +00:00
PULL_REQUEST_TEMPLATE.md Update from template 2023-07-21 11:39:01 +02:00
README.md Update README.md 2023-10-03 11:54:36 +02:00
Types.py clean + add collection 2024-10-03 12:07:33 +02:00
__init__.py clean + add collection 2024-10-03 12:07:33 +02:00
functions.py clean + add collection 2024-10-03 12:07:33 +02:00
operators.py clean + add collection 2024-10-03 12:07:33 +02:00
properties.py custom_shelf initial commit 2022-03-04 12:28:53 +01:00
ui.py clean + add collection 2024-10-03 12:07:33 +02:00
utils.py clean + add collection 2024-10-03 12:07:33 +02:00

README.md

CUSTOM_SHELF

Blender addon to launch custom scripts from the User Panel

Pipe_test is a test repository that can be used by TDs to run code or development tests so as not to pollute the main repositories.


Table of Contents
  1. Installation
  2. Contents
  3. Usage

Installation

  1. Create your own local directory in
    /home/<USER>/dev
    
  2. Create your own local directory in
    git clone ssh://git@git.autourdeminuit.com:222/autour_de_minuit/custom_shelf.git
    

Contents

Usage

Place your .py scripts in the shelves/ folder with following folder structure:

shelves / sidebar_tab_name / panel_name / button_name.py

Here is the dictionnary to put at the beginning of your code to have tooltip, icon and variables inside a popup:

info = {
    'icon' : 'SORTALPHA',
    'description' : 'Rename active object in something',
    'name' : 'Some name',
    'enum' : {'value': '3', 'items': ['1', '2', '3', '4']},
    'int' : 2,
    'path' : '/temp',
    'bool' : False,
    'float' : 2.0,
    'collection' : {'value': 'object', 'collection': 'Object'},
}

To get yout variables in your code :

name = info['name']

The collection return the name, so to get an object :

ob = bpy.data.objects.get(info['collection']['value'])

You can next filter by tags by clicking on the arrow icon