News:

 

Topic: NvilClipboard (Blender)  (Read 22304 times)

0 Members and 1 Guest are viewing this topic.

  • No avatar
  • Posts: 232
  • Spline
April 08, 2014, 02:32:38 pm
I have now tried the script out - works very nicely!
A few comments: It was great if the script allowed setting import and export preferences in Blender (on Ngons, Smoothing Groups, Polygroups, Axis remapping etc.). I would not need a GUI for this, just some additions in the script which one then could set to true or false and simply resave. Maybe one could also manually create import/export presets which get stored by Blender (that pulldown in the im/exporter) and the script got pointed to that preset?

Now for instance when Polygroups are inside the Nvil-model they cause the model to be split into separate objects in Blender. Unchecking that option on the left hand side in the importer leaves the model uncut. On export there's again a polygroup section in the Blender exporter but I failed getting groups back to Nvil, maybe someone with more experience knows what to do here?

I'm too stupid to create hotkeys for this script - could anyone give me a hand?
In User-Preferences in the Input Tab one needs to do what exactly? Searching for the Script-commands yields no results.




  • Posts: 546
  • Administrator
  • Polygon
April 08, 2014, 03:03:51 pm
well i could take a few approach to this, could make a 3rd command that pops up a UI for setting these options.

Or i could have a config file that goes along side, so you can set these options.

or i could just have these options are clearly defined vars, at the start of the script.

what would you prefer, im kinda learning towards addeding a 3rd command that lets the user configure it.


To create hotkeys, what you have to do, is in the Input tab, open up the category you want to add the key too, and at the bottom of the list click Add New
This will create a new hot key entry, expand the item open, and in the first text field copy this in.
Code: [Select]
nvilclipboard.pickupto make the key to pick things up from the clipboard
or this
Code: [Select]
nvilclipboard.dropfor the command to drop things to the clipboard.


you cant just search it in the editor, because the editor only displays operators that got keys assigned to them, so unless i create a default mapping in the script you have to add it this way.


This might be a good reason to add it to a menu or the UI somewhere, since you can rightclick UI buttons or menu items to give them hotkeys.
« Last Edit: April 08, 2014, 03:18:16 pm by Passerby »

  • No avatar
  • Posts: 232
  • Spline
April 08, 2014, 03:40:25 pm
Thanks!
@options: I tend to a non modal version. The beauty of these bridges is exactly not having to deal with settings and stuff - plop - the model is there.
That said: Settings make sense. Maybe really a third command indeed was best. It brought up a dialog which included a "reload" button to test the just dialed in settings. When closing that dialog, the last chosen options go sticky. Would that work?

There's one thing I forgot: The settings panel should also include a "replace" option (the way Zbrush reloads updated clipboard-geometry). Currently reloaded items get added as separate items to the scene. I'll now look into the keyboard mapping, thanks for the explanation!


  • Posts: 546
  • Administrator
  • Polygon
April 08, 2014, 05:19:20 pm
Im actually re-working the whole add-on from scratch, right now.

When im done the new version, will have the import and export commands, right in the import and export menus of blender, and will support binding keys by just right clicking the menu items.

I will also add a command for configuring all the options.


What options do you feel is important to have configurable?
Also what do you think the defaults should be?
« Last Edit: April 08, 2014, 05:27:16 pm by Passerby »

  • No avatar
  • Posts: 232
  • Spline
April 08, 2014, 06:44:58 pm
What options do you feel is important to have configurable?
Also what do you think the defaults should be?
Others should chime in as well. I think the default setting should be to keep poly-groups and it was great to get them out of Blender too. I don't have a need for smoothing groups but this is important to others so it should be configurable. Axis remapping seems fine already and probably doesn't need to be configurable.

  • Posts: 546
  • Administrator
  • Polygon
April 08, 2014, 06:55:42 pm
this build has the group option as a default, and i have it intergrated into the import and export menues, which should also make it easier to bind keys, via right cliking the menu items, and selecting "Add ShortCut"

https://raw.githubusercontent.com/cmcpasserby/BlenderNvilClipboard/master/NvilClipboard.py

will add the options manager in later

  • No avatar
  • Posts: 306
  • Triangle

  • No avatar
  • Posts: 306
  • Triangle
May 17, 2014, 02:33:31 am
Please using Clipboard .dae

  • Posts: 546
  • Administrator
  • Polygon
May 17, 2014, 02:00:24 pm
What are you even trying to show in those screens,but ya I could add a date option.

  • No avatar
  • Posts: 232
  • Spline
June 14, 2014, 04:48:58 pm
Hi All,
the exchange script shared passerby script works nicely but I missed a couple of options...
Blender interprets obj scale different from Nvil, so when passing things back and forth the meshes will not retain their scale, which ich quite a problem. The second thing is polygroups. By default Blender would split your mesh by polygroups, now it turns them into Vertexgroups, which even keep their names. When bringing back the geometry to Nvil, Polygroups are still there.

The updated script is attached. Please note that you might have to edit numbers in clamp scale (on import) and scale factor (on export), depending on the units you use in Nvil. You can quickly try out required values by using Blender's default Im/Exporters, then change the according values in the script.

  • No avatar
  • Posts: 8
  • Vertex
January 17, 2017, 08:53:11 am
The links seem to be broken. Any chance they could fixed?

  • No avatar
  • Posts: 23
  • Vertex
    • My worklog
April 30, 2017, 11:41:53 am
Yes, lots of ads when trying to download it.

  • No avatar
  • Posts: 8
  • Vertex
October 13, 2017, 01:36:13 pm
Could anyone that has the applink copy paste the code here if no one wants to upload it?

  • No avatar
  • Posts: 176
  • Spline
    • White-creatures
June 23, 2020, 06:58:20 am
Hi,

I created a very simple Blender addon to transfer mesh between Nvil and Blender,

The addon script:
https://drive.google.com/file/d/1mWiyZUjWznLq2phq4jsuM9mh2nWzmgX_/view?usp=sharing



Install it just like other addon, then you will be able to access it under File Context Menu (Hotkey: <F4>).

The import/export options are hardcoded, it works ok dealing with one mesh, it will preserve the vertex order which is my priority; for import/export multiple meshes, I believe there will be some issues.. it also doesn't take care of naming.