Page 1 of 2

[editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 08:55
by Markelius
So ideally, after the engine and editor go post 1.0, and a new mesh format can replace NIF, it would be really great to have some sort of integration between OpenCS and Blender.

How I propose this is, OpenCS would be capable of generating some basic meshes in the world editor, things like cylinders, cubes, planes, spheres, etc. There would then be an "open in blender" drop down option or hotkey of some sort, and blender would open this mesh. It would be scaled to the scale the game would use. This way you could use the basic meshes as scaling references and build a mesh in it's place.

Here's where it gets good, any changes to the mesh made in blender would be shown in realtime in OpenCS. This way, say you needed a specific cave entrance mesh, you could make it exactly the way it needed to be, without having to export/copy into Data Files, import into CS to view the changes. All the changes would be seen when you made them.

Additionally, OpenCS should update things like textures on the fly, if I have a wilderness cell open in OpenCS, and I replace the land_default texture with something else, the new texture should be loaded into OpenCS without the need to reload the data files.

I suggest this could be implemented by having a hotkey/menu option to update assets. I'm aware it's not really practical for changes to be detected by OpenCS and updated automatically, since there are a huge amount of assets in Vanilla Mw alone, but a hotkey/menu option could make it work.

To make things easier, the editor would only check/update changed assets for the assets viewed in the render windows, which would make things go a lot faster since the program wouldn't have to reload every asset.


As a modder who works with textures and meshes often, these features would be very handy to have in the editor, let me know what you think!

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 10:05
by Berandas
How often do you need to see the mesh during it's creation process in the CS? I usually add only finished meshes into the CS...on the other hand I also have to open them in NifSkope and check the scale, transparency, alpha blending and other things for errors before importing.
Actual real time updating of the assets would be great though, since I usually copy some wrong/old files, do some changes to them or something and have to restart the whole CS after that, often even several times. Thing like this would save me lot of time.
Seeing how the texture changes in real time would also be very handy.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 11:31
by Zini
This proposal certainly does not match my experience with MW modding. Usually the art people just drop a batch of files on us who work with the CS. There is no intersection between people working with the CS and those who are working with modeling programs.
But of course not everyone works in the same way. I guess there are some people who use both the CS and 3D modelling programs (especially when working solo instead of in a team).

I am not so keen on a fixed integration specially with blender. It would be cool though to provide an application neutral IPC protocol for this purpose (and support it in OpenCS). On a platform I worked on a long time ago (RISC OS) this was widely available and I found it incredible useful. This also took care of the update problem because the server (that would be blender in this example) would report back to the client (OpenCS here) when the editing was done. Therefore it has no need for the user manually requesting an update.

DBus would be a very good choice for this feature, except that I repeatedly had Windows people telling me that getting DBus to work on Windows is difficult (no idea about the OS X situation). Maybe there even is a DBus protocol for that purpose. We could look into that, if Windows can get its shit together.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 11:39
by psi29a
Would thrift be of interest here?

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 11:55
by Zini
Maybe. We will have to investigate that more closely after 1.0.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 15:44
by Greendogo
I started reading this with trepidation, but this would actually be really useful, if like Zini says we could just expose the functionality and allow plugins to be made for each individual 3D modeling program.

The problem with limiting it to Blender was that it left out a huge selection of popular tools like 3D Studio Max, Maya, ZBrush, etc.

This would be great for making changes to stock models too instead of only primitives. Imagine you already had a stock wooden mine door model placed in an exterior. You could open it in Whatever application you wanted, which would cause the creation of a new object with a new ID in OpenCS, and you could add unique touches to that mine door, like a sign on the door, or a unique texture, shader or shape distortion.

Another example: you could select a group of rock objects together and open them as a single object- you could then eliminate unseen faces, shape them, add effects like water effects or ZBrush changes, and generally make those rocks (which were boring stock rocks) suddenly unique to that usage as well as being conveniently merged into one object (fewer resource files) with a new ID in the OpenCS.

This would be a very powerful feature and could definitely be a part of what helps set OpenMW/OpenCS apart from Morrowind's CS early on.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 18:30
by Zini
I started reading this with trepidation, but this would actually be really useful, if like Zini says we could just expose the functionality and allow plugins to be made for each individual 3D modeling program.
That is not what I proposed. No plugins. The 3D modeling program would have to implement the other end of said IPC protocol, which shouldn't be a huge problem for blender, if we can make this protocol good enough.
Of course this could easily be expanded to other resources like textures. Said protocol wouldn't be specific to 3d models.

btw. It blows my mind that there isn't a widely used and supported open cross-platform protocol for this purpose already. Todays desktop really is bearskins and stone knifes.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 19:42
by Greendogo
Ooooooh! I see. That seems quite a bit harder than a plugin, but I suppose when you explain it like that, the infrastructure doesn't exist in any modeling program yet to even support a plugin that would do this anyway.

Yeah, it would be great to be able to do this with textures too. GIMP and Photoshop seem like prime candidates for it.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 21 Aug 2014, 20:41
by psi29a
Zini wrote:btw. It blows my mind that there isn't a widely used and supported open cross-platform protocol for this purpose already. Todays desktop really is bearskins and stone knifes.
I'm telling you, apache thrift!

We use at work, across different archs and languages... all using the same API spec.

I"ve got C++ talking to python/twisted that also talks to ocaml, across amd64 and armv7.

We've not tried windows, but that shouldn't be a problem.
https://issues.apache.org/jira/browse/THRIFT-591
^-- now compiles and works with MSVC.

Re: [editor] Blender/OpenCS integration (post 1.0)

Posted: 22 Aug 2014, 09:22
by Zini
I'm telling you, apache thrift!
Yeah, the technology might be there. But it is worthless, if it isn't widely supported by the software ecosystem. I would love to get something like this going (after 1.0), but it will require a whole lot of work to convince enough other projects to support these kinds of features.