Blender addons - A collection of Blender tools I've written for myself over the years.

Overview

gret

A collection of Blender tools I've written for myself over the years. I use these daily so they should be bug-free, mostly. Feel free to take and use any parts of this project. gret can be typed with one hand in the search bar.

Installation

TODO

Configuration

TODO

Tools

Mesh: Graft

Connects boundaries of selected objects to the active object. I wrote it to deal with stylised fur in a non-destructive way that allows normals to be lifted from the body.

Demo

Mesh: Retarget Mesh

Refit clothing meshes to a modified version of the character mesh.

Demo

If retargeting to a different mesh, make sure they share topology and vertex order. If the retargeted mesh becomes polygon soup then it's probably the vertex order. Try using an addon like Transfer Vert Order to fix it.

Mesh: Make Collision

Intended for use with UE4, generates collision shapes for selected geometry. For example, to make compound collision for a chair:

  1. Select a part of the chair in edit mode (can use Select Linked Pick if the pieces are separate).
  2. Click Make Collision and select an appropriate shape, e.g. capsules for the posts, a box for the backrest and cylinder for the seat.
  3. Repeat for every piece.

Demo

Mesh: Vertex Color Mapping

Procedurally generates vertex colors from various sources. Sources can be vertex groups, object or vertex position, or a random value. Useful for exporting masks to game engines.

Panel

Mesh: Apply Modifiers with Shape Keys

The much needed ability to apply modifiers on a mesh with shape keys. Mirrors are specially handled to fix shape keys that move vertices off the center axis. Found in Shape Keys → Specials Menu → Apply Modifiers with Shape Keys.

Mesh: Sync UV Maps

Adds a few buttons that allow reordering UV maps. Sync UV Maps works on all selected objects to ensure UV layer names and order are consistent with the active object. It can also be used to simply switch the active UV layer for multiple objects.

Buttons

Mesh: Add Strap

Similar in function to an extruded curve. Since it's mesh and not curve based, typical mesh operators can be used to edit it. Use case is adding belts to characters.

Mesh: Add Rope

Generates helicoid meshes, mostly useful as ropes. Can edit the base shape once created.

Animation: Pose Blender

Allows blending poses together, similar to the UE4 AnimGraph node. Works on bones, not shape keys.

Demo

Has a performance cost, I'll try to optimize it further at some point.

Animation: Actions Panel

A panel for quick access to actions and working with pose libraries. Pose libraries are simply actions where each frame has a named marker, and normally they're very annoying to work with. A pose library is necessary to use the Pose Blender tool.

Panel

Animation: Rig Panel

Add any frequently used rig or bone properties here. To find the data path of a property, right click it then select Copy Data Path.

The addon Bone Selection Sets must be enabled for the second panel to show. I don't find bone pickers to be comfortable to use, and this is a workable alternative. Add and delete buttons make it easy to create temporary sets while animating.

Panel

Material: Texture Bake

One-click bake and export. Intended for quickly baking out curvature and AO masks.

Panel

Material: Tile Paint

Rudimentary tool to create tile-based UV maps. For anything more complicated use Sprytile instead.

Demo

UV: Relax Loops

Relaxes selected UV edge loops to their respective length on the mesh. Can be used to rectify non-grid meshes that TexTools Rectify won't work on. Found in UV Editor → UV → Relax Loops.

Demo

Other

Sculpt Selection: Sets the sculpt mask from the current edit-mode vertex selection. Found in the Select menu in edit mode.

Normalize Shape Key: Resets min/max of shape keys while keeping the range of motion. A shape key with range [-1..3] becomes [0..1], neutral at 0.25. Some game engines don't allow extrapolation of shape keys. Found in Shape Keys → Specials Menu → Normalize Shape Key.

Merge Shape Keys to Basis: Mixes active shape keys into the basis shape. It's possible to filter shape keys by name.

Remove Unused Vertex Groups: Originally an addon by CoDEmanX, this operator respects L/R pairs of vertex groups. Found in Vertex Groups → Specials Menu → Remove Unused Vertex Groups.

Deduplicate Materials: Squashes duplicate materials, like "Skin.002", "Skin.003", etc. Found in File → Clean Up.

Replace References: Replaces object references in modifiers. I use it to swap meshes that are shrinkwrap targets and such. Found in File → Clean Up.

Export Jobs

TODO

Comments
  • Apply Modfiers with Shapekey, but not Armature

    Apply Modfiers with Shapekey, but not Armature

    Hello, is there a way to apply modifiers with Shapekey, but ignore Armature.

    I need to apply mirror and subdiv for Fbx exports, and your plugin seems to be the most stable form all that I have tested.

    Thanks

    opened by fls-eugene 4
  • Can't enable the addon.

    Can't enable the addon.

    When I try to enable GRET 0.3.0 by clicking a checkbox in addons tab, blender won't let me do it and prints this error log -

    Traceback (most recent call last): File "blender-3.1.2-windows-x64\3.1\scripts\modules\addon_utils.py", line 351, in enable mod = import(module_name) File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0_init_.py", line 52, in modules = import_or_reload_modules(module_names, name) File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0_init_.py", line 31, in import_or_reload_modules module = globals()[module_name] = importlib.import_module(module_name) File "blender-3.1.2-windows-x64\3.1\python\lib\importlib_init_.py", line 126, in import_module return bootstrap.gcd_import(name[level:], package, level) File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0\mesh_init.py", line 23, in modules = import_or_reload_modules(module_names, name) File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0_init.py", line 31, in import_or_reload_modules module = globals()[module_name] = importlib.import_module(module_name) File "blender-3.1.2-windows-x64\3.1\python\lib\importlib_init_.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0\mesh\shape_key_store.py", line 152, in class ShapeKeyPanelPatcher(PanelPatcher): File "AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\gret-0_3_0\mesh\shape_key_store.py", line 154, in ShapeKeyPanelPatcher panel_type = bpy.types.DATA_PT_shape_keys AttributeError: 'module' object has no attribute 'DATA_PT_shape_keys'

    I am installing it on Blender 3.1.2, tried 3.1.0 but it prints the same exact error. 0.2.0 GRET works just fine.

    opened by Electrognome 3
  • Doesn't work at all for me

    Doesn't work at all for me

    I've downloaded the add on and have blender 2.93.7. I can install it, but when searching it does not appear. Tried to remove and install again and also older versions on gret.

    opened by vanessahjerpe 3
  • Request: add handling for converting Blender poses to unreal pose assets.

    Request: add handling for converting Blender poses to unreal pose assets.

    Blender poses only want the posed bones to have keyframes data. Unreal pose assets require zero transforms keyframes. For exporting a blender pose (for example for faceARKit face shapes) to unreal I need to manually keyframe the rest pose along with the changed bones. But this break's blenders about to blend poses.

    Is there a way to add an option to automatically add or strip zero keyframes from an animation to allow non destructive conversion between blender and unreal poses?

    opened by BusterCharlie 2
  • Changes in Blender 3.4 break rope and collision mesh creation

    Changes in Blender 3.4 break rope and collision mesh creation

    After installing the addon in Blender 3.4 and trying to create a rope there is an error: AttributeError: 'Mesh' object has no attribute 'use_customdata_edge_crease'

    also, when trying to create collision mesh there is another error: AttributeError: 'Mesh' object has no attribute 'use_customdata_vertex_bevel'

    Probably related to https://developer.blender.org/rB291c313f80b4cc and https://developer.blender.org/rBa8a454287a27

    opened by Ran9 1
  • Speed up shape_key_apply_modifiers using buffers

    Speed up shape_key_apply_modifiers using buffers

    By using buffer objects with type matching the 'co' data (single precision float), in foreach_set and foreach_get, Blender will directly memcpy the data into/out of the buffer instead of iterating and casting each element to the correct type. This results in slightly faster foreach_set and foreach_get calls.

    It's probably not much of a timesave unless the mesh being operated on is huge (or ends up huge from its modifiers) and/or has a ton of shape keys.

    Here's the foreach_getset code in Blender's source: https://github.com/blender/blender/blob/594f47ecd2d5367ca936cf6fc6ec8168c2b360d0/source/blender/python/intern/bpy_rna.c#L5228 The lines containing !buffer_is_compat are where it'll swap to iteration if the buffer isn't compatible with the data, the code for compatible buffers is right before.

    Here's the code I used for benchmarking along with results in the comments:

    import bpy
    import numpy as np
    import timeit
    
    # Requirements:
    # In object mode with an active mesh object in current scene that has shape keys
    
    
    def orig_get(my_list, vertices):
        my_list[:] = [0.0] * (len(vertices) * 3)
        vertices.foreach_get('co', my_list)
    
    def np_get(my_array, vertices):
        my_array.resize(len(vertices) * 3, refcheck=False)
        vertices.foreach_get('co', my_array)
        
    def put(my_list_or_array, vertices):
        vertices.foreach_set('co', my_list_or_array)
        
    
    trials = 1000
    
    
    get_setup = "basis=bpy.context.object.data.shape_keys.key_blocks[0]"
    put_setup_orig = get_setup + ";my_list = [];orig_get(my_list, basis.data)"
    put_setup_np = get_setup + ";my_array = np.empty(0, dtype=np.single);np_get(my_array, basis.data)"
    
    # ~56.49ms per call with 393218 verts (ran with 100 trials instead of 1000)
    # ~2.96ms per call with 24578 verts
    # ~0.041ms per call with 386 verts
    print(timeit.timeit("my_list = [];orig_get(my_list, basis.data)", setup=get_setup, globals=globals(), number=trials)/trials*1000)
    # ~18.82ms per call with 393218 verts (ran with 100 trials instead of 1000) (3x)
    # ~1.16ms per call with 24578 verts (2.55x)
    # ~0.022ms per call with 386 verts (1.86x)
    print(timeit.timeit("my_array = np.empty(0, dtype=np.single);np_get(my_array, basis.data)", setup=get_setup, globals=globals(), number=trials)/trials*1000)
    
    # ~28.45ms per call with 393218 verts (ran with 100 trials instead of 1000)
    # ~1.75ms per call with 24578 verts
    # ~0.03ms per call with 386 verts
    print(timeit.timeit("put(my_list, basis.data)", setup=put_setup_orig, globals=globals(), number=trials)/trials*1000)
    # ~20.85ms per call with 393218 verts (ran with 100 trials instead of 1000) (1.36x)
    # ~1.29ms per call with 24578 verts (1.36x)
    # ~0.022ms per call with 386 verts (1.36x)
    print(timeit.timeit("put(my_array, basis.data)", setup=put_setup_np, globals=globals(), number=trials)/trials*1000)```
    opened by Mysteryem 1
  • Support Live link Such As Unity MeshSync For Blender

    Support Live link Such As Unity MeshSync For Blender

    • Workflow: i.e. A real-time link from Blender to UE is like unity's meshSync plugin
    • Description: i.e.

    Hi!I recently noticed that Unity's MehSync plugin has been able to sync most of Blender's data in real time. Just bone data may not be perfect for games, but it's almost done with USD data transfer.

    The USD Hydra plug-in developed by AMD is currently the only way to dynamically link USD to Blender. However, the supported data is too few. Blender's meeting last week was still discussing the follow-up development route of USD, so it is difficult to make progress in the short term.

    So I'm really looking forward to a plugin like Unity's MeshSync that links to Blender in real time, which is a breakthrough for both game development and film production, allowing almost any Blender user project to seamlessly connect to UE, even if they've only learned the basics of UE for five minutes. 

    Hopefully you will be able to develop a similar real-time synchronization feature before Blender fully supports USD (which I think is at least a few years away), thanks for your efforts!

    Here are some links and demos

    opened by 1405100494 1
  • Remove ARP thingy from Action panel and substitue for new Blender 3.1…

    Remove ARP thingy from Action panel and substitue for new Blender 3.1…

    … Frame Range feature :)

    I've updated here on our internal tools, it's working fine from what I've tested :) Never did a Pull Request before, so excuse me if I'm doing something wrong!

    opened by elamhut 1
  • Error trying to enable add-on in Blender 2.93

    Error trying to enable add-on in Blender 2.93

    Traceback (most recent call last): File "C:\Program Files\Blender Foundation\Blender 2.93\2.93\scripts\modules\addon_utils.py", line 386, in enable mod.register() File "C:\Users\Main\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\gret-0_0_1_init_.py", line 159, in register module.register(GRET_PG_settings) File "C:\Users\Main\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\gret-0_0_1\material_init_.py", line 14, in register module.register(settings) File "C:\Users\Main\AppData\Roaming\Blender Foundation\Blender\2.93\scripts\addons\gret-0_0_1\material\tile_paint.py", line 578, in register GRET_OT_tileset_draw.annotations['uv_layer_name'][1]['default'] = prefs.tileset_uv_layer_name TypeError: '_PropertyDeferred' object is not subscriptable

    opened by welovekah 1
Releases(1_1_0)
【AI创造营】参赛作品

-AI-emmmm 【AI创造营】参赛作品 鬼畜小视频 AiStuido地址:https://aistudio.baidu.com/aistudio/projectdetail/1647685 BiliBili视频地址:https://www.bilibili.com/video/BV1Zv411b

107 Nov 09, 2022
Height 2 LDraw With python

Height2Ldraw About This project aims to be able to make a full lego 3D model using the ldraw file format (.ldr) from a height and color map, currently

1 Dec 22, 2021
A napari plugin to inspect data within a cisTEM project

napari-cistem A plugin to inspect data within a cisTEM project This napari plugin was generated with Cookiecutter using with @napari's cookiecutter-na

Johannes Elferich 1 Nov 07, 2021
Neptune client library - integrate your Python scripts with Neptune

Lightweight experiment tracking tool for AI/ML individuals and teams. Fits any workflow. Neptune is a lightweight experiment logging/tracking tool tha

neptune.ai 353 Jan 04, 2023
LTGen provides classic algorithms used in Language Theory.

LTGen LTGen stands for Language Theory GENerator and provides tools to implement language theory. Command Line LTGen is a collection of tools to imple

Hugues Cassé 1 Jan 07, 2022
Eatlocal - This package helps users solve PyBites code challenges on their local machine

eatlocal This package helps the user solve Pybites code challenges locally. Inst

Russell 0 Jul 25, 2022
Fully coded Apps by Codex.

OpenAI-Codex-Code-Generation Fully coded Apps by Codex. How I use Codex in VSCode to generate multiple completions with autosorting by highest "mean p

nanowell 47 Jan 01, 2023
A code base for python programs the goal is to integrate all the useful and essential functions

Base Dev EN This GitHub will be available in French and English FR Ce GitHub sera disponible en français et en anglais Author License Screen EN 🇬🇧 D

Pikatsuto 1 Mar 07, 2022
Direct Multi-view Multi-person 3D Human Pose Estimation

Implementation of NeurIPS-2021 paper: Direct Multi-view Multi-person 3D Human Pose Estimation [paper] [video-YouTube, video-Bilibili] [slides] This is

Sea AI Lab 253 Jan 05, 2023
Blender Addon for Snapping a UV to a specific part of a Tilemap

UVGridSnapper A simple Blender Addon for easier texturing. A menu in the UV editor allows a square UV to be snapped to an Atlas texture, or Tilemap. P

2 Jul 17, 2022
Tracing and Observability with OpenFaaS

Tracing and Observability with OpenFaaS Today we will walk through how to add OpenTracing or OpenTelemetry with Grafana's Tempo. For this walk-through

Lucas Roesler 8 Nov 17, 2022
🤖️ Plugin for Sentry which allows sending notification via DingTalk robot.

Sentry DingTalk Sentry 集成钉钉机器人通知 Requirments sentry = 21.5.1 特性 发送异常通知到钉钉 支持钉钉机器人webhook设置关键字 配置环境变量 DINGTALK_WEBHOOK: Optional(string) DINGTALK_CUST

1 Nov 04, 2021
Our Ping Pong Project of numerical analysis, 2nd year IC B2 INSA Toulouse

Ping Pong Project The objective of this project was to determine the moment of impact of the ball with the ground. To do this, we used different model

0 Jan 02, 2022
Runtime fault injection platform by Daniele Rizzieri (2021)

GDBitflip [v1.04] Runtime fault injection platform by Daniele Rizzieri (2021) This platform executes N times a binary and during each execution it inj

Daniele Rizzieri 1 Dec 07, 2021
This is a working model for which I have used python.

Jarvis_voiceAssistance This is a working model for which I have used python. This model can: 1)Play a video or song on youtube. 2)Tell us time. 3)Tell

Hardik Jain 1 Jan 30, 2022
This is a modified variation of abhiTronix's vidgear. In this variation, it is possible to write the output file anywhere regardless the permissions.

Info In order to download this package: Windows 10: Press Windows+S, Type PowerShell (cmd in older versions) and hit enter, Type pip install vidgear_n

Ege Akman 3 Jan 30, 2022
Simple Python API for the Ergo Platform Explorer

Ergo is a "Resilient Platform for Contractual Money." It is designed to be a platform for applications with the main focus to provide an efficient, se

7 Jul 06, 2021
Oppia is an online learning tool that enables anyone to easily create and share interactive activities

Oppia is an online learning tool that enables anyone to easily create and share interactive activities (called 'explorations'). These activities simulate a one-on-one conversation with a tutor, makin

Oppia 4.7k Dec 29, 2022
Push Prometheus metrics to VictoriaMetrics or other exporters

Push metrics from your periodic long-running jobs to existing Prometheus/VictoriaMetrics monitoring system.

olegm 14 Nov 04, 2022
Frappe app for authentication, can be used with FrappeVue-AdminLTE

Frappeauth App Frappe app for authentication, can be used with FrappeVue-AdminLTE

Anthony C. Emmanuel 9 Apr 13, 2022