Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better Directory Input & Game Object based Lip Syncing #76

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

deviandice
Copy link

1. Enhanced Directory Wizard
The existing wizard has a significant limitation: It only reads the children of a specified directory without replicating that directory's structure in the output.
This oversight forces users to manually sort their baked data to match the hierarchy of the original audio clips, which is inefficient, prone to errors, and if your line count is high enough may lead to death from dehydration because of how long sorting them would take. My alternative wizard addresses this issue by cloning the directory hierarchy from input to output, ensuring that the structure of subfolders and their contents is preserved.

2. Game Object-based Lip Syncing for 2D Rigs
I noticed a very noticeable gap in the current toolset for 2D lipsyncing, particularly for rigs that aren't sprite sheet-based (Believe it or not that's every single rig I use). uLipSyncTexture falls short in this case. One of Unity's only features that actually "just works" is the PSB import pipeline, which automatically slices sprites based on their boundaries, resulting in varying origins and sizes that aren't easily swappable. It also mirrors the layer structure when dragging the imported PSB into the editor. Therefore, all of your phonemes will already exist as individual game objects. So I created uLipSyncGameObject which is functionally similar to uLipSyncTexture, but works by just enabling and disabling the objects instead.

I love this tool, so I hope these are useful additions.

The current wizard takes a directory input and reads all the children of the directory. Then it dumps everything into one folder, which makes the directory input kind of misleading. 
This wizard recreates the folder hierarchy 1:1, perfect for any functionality that uses the resources folder.
An editor for ULipSyncGameObject
It's sort of like ULipSyncTexture but for game objects. 
I use this for 2D sprite puppets, like those imported via the PSB importer will have different origins for their phoneme sprites due to the automatic sprite slicing. Not only that, but you'll already have a sprite hierarchy you want to keep, so this requires no edits to the layer structure in your PSB or PSD imports. Very convenient.
There was some sort of bug where if you changed the profile after baking data it would spew out a message saying "The main object name should match the asset filename. Please fix to avoid errors.”. You would have to, one by one, click a button to fix it. This script does that but for literally everything.
@hecomi
Copy link
Owner

hecomi commented Jul 31, 2024

Thank you for the fantastic PR! I aim to review and integrate it as soon as possible. However, I might not have time in the immediate future, so it could take up to a month. I appreciate your patience. Additionally, since there are two updates included, it would be smoother to review if you could separate them into individual PRs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants