Copy/Paste UV data between groups of vertices in the same mesh object #32562

Closed
opened 2012-09-16 11:21:11 +02:00 by Jace Priester · 19 comments
Member

Project: Blender Extensions
Tracker: Py Scripts Upload
Blender: 2.63
Category: UV
Python: 3.2
Script name: Copy/Paste UVs
Wiki page: http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/UV/Copy_Paste_UVs
Author(s): Jace Priester
Status: Open

%%%Given a set of vertices in a mesh object which has been duplicated, this script allows for copying the UV coordinates from one set to the other.

Select the source vertices and U->Copy UVs, then select the destination vertices and U->Paste UVs.%%%

**Project**: Blender Extensions **Tracker**: Py Scripts Upload **Blender**: 2.63 **Category**: UV **Python**: 3.2 **Script name**: Copy/Paste UVs **Wiki page**: http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/UV/Copy_Paste_UVs **Author(s)**: Jace Priester **Status**: Open %%%Given a set of vertices in a mesh object which has been duplicated, this script allows for copying the UV coordinates from one set to the other. Select the source vertices and U->Copy UVs, then select the destination vertices and U->Paste UVs.%%%
Author
Member

Changed status to: 'Open'

Changed status to: 'Open'

%%%what a useful tool! thank you for creating this addon. This should be in trunk imo!%%%

%%%what a useful tool! thank you for creating this addon. This should be in trunk imo!%%%

Added subscriber: @RomboutVersluijs

Added subscriber: @RomboutVersluijs

Ive got this question about this plugin. I cant copy the UV from one object to another in the same mesh. Tried cipying the vertices and than pasting it but blender keeps crashing

Ive got this question about this plugin. I cant copy the UV from one object to another in the same mesh. Tried cipying the vertices and than pasting it but blender keeps crashing
Member

Added subscriber: @PaulGeraskin

Added subscriber: @PaulGeraskin
Member

This is really powerful addon! What is the status of adding it to the blender addons?

This is really powerful addon! What is the status of adding it to the blender addons?
Member

I think i can add this addon into the blender. if @JaceP does not mind. I'll talk to @Ideasman_42 about it in IRC.

Here is my test of the addon. It's really powerful: http://youtu.be/Iy1RI6KNZ_M

I think i can add this addon into the blender. if @JaceP does not mind. I'll talk to @Ideasman_42 about it in IRC. Here is my test of the addon. It's really powerful: http://youtu.be/Iy1RI6KNZ_M
Member

Ok, Ideasman42 is ok to add this script. I did the script compatible to pep8.uv_copy_paste_uvs.py

Ok, Ideasman42 is ok to add this script. I did the script compatible to pep8.[uv_copy_paste_uvs.py](https://archive.blender.org/developer/F95635/uv_copy_paste_uvs.py)

Added subscriber: @DiThi

Added subscriber: @DiThi

Hi, I just wanted to nitpick it's not really PEP8, there are lines longer than 80 characters. You can store e.g. "source_object.data.loops" in a variable to reduce line length, and that also makes the script a little bit faster and more readable. Strings can be split like this:

                      self.report({'WARNING'},
                          "Error; source loops and destination loops do not "
                          "match; geometry seems dissimilar")

URLs don't need to be split. When there are too many levels of nesting in Python you can't have less than 80 chars, it's a symptom code needs some refactoring.
When editing PEP8 compliant code, I have my editor split in at least 3 columns or tiled with other window. Sorry if I'm being too nit-picky, I'm also writing a style guide for an internal project.

Cheers

Hi, I just wanted to nitpick it's not really PEP8, there are lines longer than 80 characters. You can store e.g. "source_object.data.loops" in a variable to reduce line length, and that also makes the script a little bit faster and more readable. Strings can be split like this: ``` self.report({'WARNING'}, "Error; source loops and destination loops do not " "match; geometry seems dissimilar") ``` URLs don't need to be split. When there are too many levels of nesting in Python you can't have less than 80 chars, it's a symptom code needs some refactoring. When editing PEP8 compliant code, I have my editor split in at least 3 columns or tiled with other window. Sorry if I'm being too nit-picky, I'm also writing a style guide for an internal project. Cheers
Member

Hi @DiThi . Could you write a mail here http:*lists.blender.org/mailman/listinfo/bf-python ? As I made a post to accept the script here http:*lists.blender.org/pipermail/bf-python/2014-June/006255.html .
I used Autopep8 tool to make it compatible.

Hi @DiThi . Could you write a mail here http:*lists.blender.org/mailman/listinfo/bf-python ? As I made a post to accept the script here http:*lists.blender.org/pipermail/bf-python/2014-June/006255.html . I used Autopep8 tool to make it compatible.

Ah, I see autopep8 doesn't wrap lines by default.

@PaulGeraskin That's where I saw your script.

Ah, I see autopep8 doesn't wrap lines by default. @PaulGeraskin That's where I saw your script.
Member

Added subscriber: @zanqdo

Added subscriber: @zanqdo
Member

Hi, how does this differ from the Transfer UV Maps operator?

Hi, how does this differ from the Transfer UV Maps operator?
Member

I think I can answer that my self. This works inside the same mesh.

I think I can answer that my self. This works inside the same mesh.
Member

Ok, i changet lines. Attached modified version.uv_copy_paste_uvs.py

Ok, i changet lines. Attached modified version.[uv_copy_paste_uvs.py](https://archive.blender.org/developer/F95670/uv_copy_paste_uvs.py)
Member

Guys! After the review of IdeasMan42 the addon is added to the blender-contribs!
https://developer.blender.org/rBACcfa509162f9ec0cc7873a61a5fa5be9e470e617a

Jace Priester thank you.

Guys! After the review of IdeasMan42 the addon is added to the blender-contribs! https://developer.blender.org/rBACcfa509162f9ec0cc7873a61a5fa5be9e470e617a Jace Priester thank you.
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
paul geraskin self-assigned this 2014-07-27 14:21:29 +02:00
Member

The addon is in repo. Close the task.

The addon is in repo. Close the task.
Sign in to join this conversation.
No Milestone
No project
No Assignees
6 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-addons#32562
No description provided.