This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This can run a custom python code to evaluate something useful. | |
| # The code is located in Program Files/SideFx.../Houdini v.v.v/houdini/scene/inspect_usd_prim.py | |
| # | |
| # Coded this little function to fetch the first Mesh subprim and a specific attribute from it. | |
| # It detects if the attribute is a list/array and then it outputs min:max values, | |
| # otherwise it outputs the actual value or indicates if the attribute is not present. | |
| # Not sure how Python can handle all the diversity of the USD datatypes yet, | |
| # so you'll have to take care of it from here for vectors/matrices/etc. | |
| # | |
| # Read the help text in the inspect_usd_prim.py, there's a flag to disable code caching, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Script that computes how many hours was spent in a regex-specified "work" category for each day in a given time span. | |
| # By Keerah.com, based on ActivityWatch example | |
| # Output: | |
| # Daily table with time and apps list sorted by the app usage | |
| # App table by usage for entire period | |
| # Verification of matches to make sure you measured nothing except the real work | |
| # If you are getting unrelated matches you need to tighten your regex criteria | |
| # | |
| # To use it in Obsidian: | |
| # Get Excecute Code extension for Obsidian |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Sometimes you need to burn in your layer(s) information into your renders | |
| // 1. Create an empty text layer | |
| // 2. Unfold its properties to Text -> Source Text | |
| // 3. Click its stopwatch while pressing Alt | |
| // 4. Paste this expression. You can exclude these descriptive lines starting with // | |
| // 5. Done. Now adjust the text properties to your preference | |
| // This expression creates text with your composition name and current layer(s) names. | |
| // If you do not want it to be included in the actual render, use Layer -> Guide Layer option | |
| // This expression takes in account all the layers below itself, so to include all of comp layers make this text layer the topmost. | |
| // The expression can be slow if you have some huge amount of layers in your comp. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Sometimes you need to burn in your layer(s) information into your renders | |
| // 1. Create an empty text layer | |
| // 2. Unfold its properties to Text -> Source Text | |
| // 3. Click its stopwatch while pressing Alt | |
| // 4. Paste this expression. You can exclude these descriptive lines starting with // | |
| // 5. Done. Now adjust the text properties to your preference | |
| // This expression creates text with your composition name and current layer(s) numbers. | |
| // If you do not want it to be included in the actual render, use Layer -> Guide Layer option | |
| // This expression takes in account all the layers below itself, so to include all of comp layers make this text layer the topmost. | |
| // The expression can be slow if you have some huge amount of layers in your comp. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import c4d | |
| #Welcome to the world of Python | |
| def main(): | |
| doc.StartUndo() | |
| s = doc.GetSelection() | |
| for x in s: | |
| try: | |
| p = x.GetUp() |