[UV Packmaster] Efficient UV packing solution for Blender (C++ based, multithreaded)

Hi glukoz.

A question, there is documentation page?
I wonder if it possible to fix UV rotation on a range, let’s say, only 90 degrees, to preserve the straightness of some uv.
Also It wold be cool if it was possible to say that pinned island stay in place and unpinned islad pack around the pinned one.


Leave the ones you want to stay unselected and activate the “Pack to Others” option. No pinning necessary.

You can certainly set the rotation step to 90 degrees, but not on a per-island basis.

1 Like

rotation step to 90, sometimes rotates the island on a random degrees.

Have you tried the Pre-rotation Disable option?

ouch! thanks I will try asap.

I’m getting these errors. Whenever I click “Pack” in 2.79b it says “Unexpected Error”, in 2.8 the error either says “Unexpected Error” or “No UV Faces selected” even when they are.

Not sure what to try. I updated all my drivers, reinstalled Blender and reset it to it’s factory settings, tried x64 version and x32 version, 2.79b, 2.8… nothing seems to work and I’ve been using UVPackMaster for a while now~ never had this problem before… I even recently bought the 2.0 because I was getting the same error on the original UVPackmaster and I thought maybe the upgrade would solve something… still nothing…

any ideas ? I honestly have no Idea what might be wrong.

Please follow the procedure in Blender 2.8:

  • Disable the add-on in preferences (not uninstall, just disable). Save preferences
  • Restart Blender
  • Press F3, type “Debug Menu”, in the window set the debug value to 1
  • Now go to preferences and enable the add-on.
  • Press F3 and type “Toggle System Console”. Hit enter - the window console will appear.
  • Copy the backtrace from console and send me in private message

(Not sure how to send a private message through blenderartists.org…)

This is what I’m getting… algthough the error message changed to “could not find packing device” now.

Do you have any antivrius software installed which could prevent the UVP binary from running normally? If so, could you try to disable it for a while to verify that it is not the cause of the issue?

[EDIT] What Windows version do you use?

I’m on Windows 10. I have Malwarebytes, AVG and CCleaner running. Maybe one of them is blacklisting some essential file ? I had all of them disabled at the time of the test, but I’m not sure they were when I installed the add-on. I’ll attempt it again, even if I have to uninstall all three.

Nope, here’s what I tried:

  • Uninstalled all Antivirus softwares, Uninstalled UVPackMaster 2, restarted PC,
  • Started PC, Opened Blender, Installed UVPackMaster 2

No success.

  • Downloaded the AddOn again from Gumroad (maybe the Antivirus messed it up during/after the download ? Unlikelly because I have it installed at work and it operates as should, but let’s try)

Nothing. Still getting the (Not supported in this edition) error.

  • Uninstall Blender entirelly.
  • Install Blender on C:/ (other Driver and same from the AppData Folder as I noticed at work both Blender and my “user” folder were on D:/)
  • Run Blender
  • Install UVPackMaster 2 from newly made Download.


That’s it… I have NO Idea why nothing works… my delivery deadline is in a couple of days… I’m ready to format my PC… any ideas ?

I’ve sent you a private message. You should see it by clicking your avatar which is located in the top-right corner of the BA site.

Hi. is there any attribute I could use when
bpy.ops.uvpackmaster2.uv_pack() has finished?
I want to put it inside a small script and I can’t find a way of telling blender to wait till that operator finish the task.


I had a similar problem once, but I did not find a clean way to achieve this - only a dirty hack:

Every time the packer finishes an operation it sets a return code in the variable:


So one possible solution is to set this variable to -1 before calling the pack operation and then monitor its value in time intervals (e.g. 100 ms using a timer). The value greater or equal 0 means the operation is done - 0 means success, a value greater than 0 indicates an error.

Note that I didn’t test this approach so there might be some other details one should take into consideration to make it work. You will probably have to use a modal operator with a timer so retcode variable update is visible in your script.

U mean something like…
check = -1
check == bpy.context.preferences.addons[‘uvpackmaster2’].preferences.packer_retcode
if check == 0: # it would mean when the operator has finished
rest of the code

Thanks for the help
PS: it doesn’t work that way :frowning:

No, try something like:

On operator initialization:

bpy.context.preferences.addons[‘uvpackmaster2’].preferences.packer_retcode = -2

In the operator model method, on timer:

 if bpy.context.preferences.addons[‘uvpackmaster2’].preferences.packer_retcode != -2:
    # packer finished

I changed the initial value from -1 to -2, because I’ve just verified that the packer may set the retcode to -1 if it encounters an error.

1 Like

I found that… It stays in the same value before and after the uvpackmaster2.uv_pack operator, is it possible?
Sorry, I’m new to bpy in general. I manage to write the whole thing and this is the only missing part

I believe that in order to be able to see a value change you need to repetitively run your code in a modal operator with a timer - do you use a modal operator?

But, as I already said, this method is a bad hack and I didn’t test it at all, so I cannot guarantee it will work. Blender API is not really friendly in such cases.

1 Like

Hi, would it be possible to add one feature that would save me a lot of time? :slight_smile:

When I am unwrapping wooden stuff, I often need all the UV islands to go in one direction along their longer edge, so that the direction of the wood grain is always aligned with the longer side of the UV isle. So I was wondering if it would be possible to introduce and option to rotate all islands in the same direction based on the longer side of their bounding box :slight_smile: Like this:

Right now I always have to rotate them manually, then uncheck the “Rotation Enable” checkbox and pack them.

1 Like

Wouldn’t TexTools SortH/SortV and then pack without auto rotate do the job?
It is rotating UV islands to minimal bounds not longest edge, but i think it would do the job in most cases so You would have to manually do “Align Edge” on those failed leftovers if any.