Plugin: Blender Layer - Live 3d View in Krita

Blender Layer v1.0.1 (Krita 5.2.6 fix)

Blender Layer is a plugin that allows you to stream 3D View from Blender into Krita, behaving like a normal layer: You can trace over it, change the blending mode and even apply layer styles!

BlenderLayer
Layer

Direct zip link: https://github.com/Yuntokon/BlenderLayer/archive/refs/heads/main.zip

Limitations

  • Poor performance for high resolutions and complicated scenes
  • Blender must be open in the background
  • Transparent background requires Blender 3.6.0 (Still in alpha at time of writing)
  • Cycles is only supported when doing a full render
  • Only tested on Windows and with recent versions of Krita/Blender
  • Probably still quite buggy, especially the animation features

Getting Started

  • Install Blender
  • Make sure the ‘Blender Layer’ add-on is installed and enabled in Krita
  • Open a document
  • Connect to Blender:
    • Drag and drop a .blend File into Krita. This will start Blender, connect and directly open the .blend file.
      (You might be asked to select the path to the blender executable. Under Windows and Blender 3.4 for example select ‘C:\Program Files\Blender Foundation\Blender 3.4\blender.exe’)
    • Or use the ‘Start Blender’ button in the ‘Blender Layer’ Docker. This will start Blender with a fresh file and connect automatically.
    • (Advanced) Or manually install the companion add-on for Blender. Goto ‘Preferences → Add-Ons → Install…’ and select ‘blenderLayerClient.py’ from the blender_layer folder of the add-on. (Under Windows installed Krita add-ons can be found in ‘%APPDATA%\krita\pykrita’). In Krita, start the server from the docker, then in Blender from the header of a 3D View choose ‘View → Connect to Krita’ make sure host and port match the settings in Krita and press ok.

Navigation

Using the navigation widget in the docker:

  • Drag to rotate
  • Shift + Drag to pan
  • Ctrl + Drag vertically to zoom

You can also change the view from outside the docker with Alt + Middle Mouse Button.

Assistants

In order to create painting assistants matching Blender’s perspective use the ‘Create Assistant Set’ button in the docker. You will be asked to save an xml file. Make sure the assistant tool is selected, then open the Tool Settings and press the ‘Load Assistant Set’ Button (Folder icon) and select the file you have just created.
The colored axis can be disabled in settings.


Library

The docker allows you to append a selection of objects to the current scene. By default, this includes posable mannequin models ‘Body-chan’ and ‘Body-kun’. (CC-0 License, created by vinchau).
You can configure additional objects from the settings menu by providing a .blend file and the path to objects within the file e.g. Object/Cube. (See Blender’s append function for reference)

Blender Layer also supports Blender’s asset based Pose Library. If your Blender file contains pose assets, these will show up in the ‘Library’ section of the docker and can be directly applied from within Krita.

Pose

Animation

You can also directly import animations from Blender.

Anim

147 Likes

That looks awesome, I have not tested this yet but i performance is a thing I do not mind just rotating the scene in Blender only, maybe that could be optional when using large scenes.

2 Likes

Insane plugin, thanks for the implementation. The basic idea works. I had issues with new layers not showing up (and some other operations) until I save the doc.

It would be useful to have the camera sync from Blender as well.

Here is a super quick test

14 Likes

THIS IS CRAZY! I can’t wait to see where this goes!

3 Likes

It works very well on Linux (Fedora 37) with Blender (Flatpak) and well it doesn’t run slow setting the resolution to a quarter size.

14 Likes

OMG this gonna be perfect.

edit: just finish reading read me and body kun is included. This is fantastic :smiley:

load it but I got a socket error;
image

Might be conflicting with something im currently running. Will try again after work with fresh restart.

1 Like

The model that I use and the model that the plugin brings is not the same, that is to say the original one, yes, but the one from the plugin is modified and looks different from the one I use.

1 Like

If you want to see the view in Krita update while in Blender, you can set the update mode to ‘Live’. This will update constantly though, even if nothing changed i.e., Blender might get a bit laggy, so this isn’t the default.
In auto mode it should update once Krita regains focus, if it doesn’t that’s a bug.
(Or did you mean setting the view to the current camera? You can do that by changing the mode to ‘Camera’)

Other operations not working sounds pretty annoying, can you reproduce that reliably? I had that once when updating the animation, but I thought I fixed that :sweat_smile:

1 Like

Great to see it working on Linux, you never know what might break if you’ve only tested it on your own machine

Judging fromthe video, the pose previews do appear to be butchered though~ (It should show the same image as in Blender’s asset explorer…)

Yeah, probably some programming listening for the same port. I chose the default port pretty much at random, so maybe it happened to be a common one.
You can try changing the port in the settings (Button at the bottom of the docker). If that doesn’t fix it, maybe it’s be a firewall/VPN thing?

1 Like

Wow… I wonder whether we shouldn’t try to port this to C++ and optimize the heck out if. It looks so incredibly useful!

28 Likes

If you were to put this as a poll, it will probably be the poll with the most hits in the shortest time possible! :joy:

If you do this, you would be doing a lot of users a very big favor, do I consider all the requests there have already been around this topic.

Michelist

7 Likes

:astonished: This looks amazing!

:star_struck::clap: Bravo!

4 Likes

It definitely is a port - dont worry about it [my system fault]. Pretty sure it just conflicted with something I’m using [i have quite a number of port use earlier since doing some work]

thank you for telling where to change it.

BTW . it’s amazing. I was looking for something like this. :face_holding_back_tears: [i’m tearing up how fantastic this is]

Doing blockings is gonna be fantastic with this.

I’m having way too much fun. :joy:

4 Likes

The 3d posing aspect is one of the main points of ClipPaint, a native functionality of this could be a killer feature.

5 Likes

Holy cow this opens so much possibilities.

1 Like

Yes, the pose previews look bad but other than that it works fine.

1 Like

This is probably the most important Krita development of 2023. Great work, now we don’t need to implement a model viewer, we can just use Blender alongside in harmony.

6 Likes

It’s definitely cool, but despite the high coolness factor, I still think Shortcut Composer is the most useful extension of this year so far, and the year isn’t even ⅓ over yet, with more than ⅔ to come.
And if everything goes well, which I wish for the team, we might even see the version jump to Krita 5.2 and for that I keep my fingers crossed for the team, the devs really deserve it, with all the stones that suddenly got in the way due to the unpredictable events of the last years.

Michelist

3 Likes

There is no reason to prefer one plugin over another. Both provide great opportunities.

12 Likes