Librelancer 2022.02
-
I’ve had to make all parts as Fix as I don’t think that quite maps to the collada spec. So basically just the part stuff and the hardpoint data doesn’t carry over. The part/hardpoint editors are reasonably streamlined to help deal with this, though it seems I still have a couple more bugs to work out in them.
-
I am using Lanceredit extensively for 5 months now and my pipeline is pretty much set:
1.) make mesh in blender, texture it, export collada, import to lanceredit, export working CMP;
*The DAE export options I use are the default ones (triangulating on export works flawlessly, although mirrored meshes might be better off getting triangulated BEFORE applying the mirror, to keep consistent shading on the tris). I do click on the “sort by object name” option, to make multi-part CMP’s have their parts be sorted by name upon export.
2.) create MAT file (a new method I use is to set Lanceredit to create materials embedded in the CMP, then just grab them and move them to a separate MAT).
**Lanceredit can import any image file format directly and convert it to your desired texture format (DXT1-5 and others), producing incredible quality results.
3.) animate the CMP (I do some of the work in UTF Editor 3, like copy-pasting nodes from my other animated CMPs because its a bit faster with drag/drop).
***Lanceredit can PREVIEW animations (both mesh animations AND texture animations)
4.) make the hardpoints and make use of the “free flight” controls to navigate around the model to see it from any angle I want;
5.) wait for it…. PROFIT!
A big shoutout to Ichiru for making all this possible!
P.S. Did you know you can preview ALE effects and STARSPHERES with Lanceredit? :)))
-
Release 2018.12.1 is out, fixing some startup errors and bugs
-
@eigos: Thanks for the elaborate explanation! I’ll give this to our modders so they can try it out
For me personally the collada export is helping since I can test out some ideas I had for making old modes look better. Also I was thinking to develop better export and import tools (also open source), since the current ones are not that great. Seems like this might not be necessary, though.
-
2019.01 is now released fixing some bugs and improving performance.
-
Current state of Librelancer: https://youtu.be/blsVd26WnaE
@Alucard: won’t be doing editing sorta stuff until the ale renderer actually works properly
-
2019.08 is now released.
-
Amazing! Managed to watch the cut scene in 2560x1440p.
Also flew around New York for a bit. Good work!
-
How about some light sources at system editor?
-
@Helloween I don’t entirely know what you mean. The system viewer loads the light sources defined in the ini, there is not editing functionality at present and for now I recommend Freelancer Mod Studio for graphical system editing. I don’t expect to write a system editor tool until a lot of the base gameplay is settled, so I can make sure all my stuff is correct.
-
Sure all correct.
Just idea to use sytem editor as showcase of new not yet released systems by making their screenshots for example -
Latest SystemViewers work for me, but not gameengine itself. Some of previous daily builds work, some don’t.
And this:
~6 FPS
Here’s that model, Kavash_Base_3:
https://www79.zippyshare.com/v/VNS8ymtR/file.html~6000 meshes of 3 materials.
I fixed that by making meshes of same material lie in one line inside of a vertexbuffer, combined same into single, and eliminated index buffers as well. Current tested snippet in pascal https://pastebin.com/RZy9VNs2
Well, that’s fun, but wrong rendering and black screen are my regular companions)
-
The model is from Y-Universe combomod, made of many tiny (4-6 vertices) details being of same material ID. Technically, 65536 vertices are allowed per 3db, I just hope the number is not treated as 32767.
Details in this model are unique, possible optimization approach isn’t clear. However, Freelancer and UTFEditor turned out being able to handle it just fine.
Without looking at above test, the solution is just streaming meshes into vertexbuffer by material, not by the order known as “for i = Ref.StartMesh to Ref.MeshCount”.
-
It’s just a very badly exported model. VMeshGroup of same material reference are expected to be pre-merged within block range of single VMeshRef. There’s zero benefit of fragmenting it.
This is clearly a very bad attempt to get around the fact milkshape exporter can’t properly export vertex normals (and exporter being dumb enough not to merge mesh elements by materials).
All in all that fragmentation had led to 6200+ draw calls and that’s the cause of such low FPS. Model doesn’t exceed any buffer limits nor is anywhere close to, it’s just a very bad export case.
-
Pre sort them https://pastebin.com/Sdj3vvwz
This is a test for Indexed this time.
But i’m unaware of the OpenGL pipeline and whether it shares same approach, various contexts, reusage of shaded contexts and so on.In current code the 3db model contains ~6000 _3d structures for making calls to DrawIndexedXXXXX. However, they’re ordered by a material so calls to shading context occurs 3 times only. Calls to draw don’t matter almost as shaded context for a particular material is reused.
ps
I’m unable to measure CPU load because of 8+8 cores on modern hardware. Task manager shows 6-8% lol. Gotta surf the web for some specialized tool. -
This model has arbitrarily bloated number of VMeshGroups in mesh for no reason whatsoever. It’s not engine job to resort and merge groups, it is exporter job to produce sane result by combining face groups matching material within each LOD of each compound part.
I’ve just re-exported it in Maxlancer which resulted in only 6 VMeshGroups. 6 draw calls is all it takes and all it should have ever been in the first place. There never was any excuse to have any more than that.
-
It’s rendering optimization/resorting.
Well, there’s another bug that came in sight both in my attempts and LibRelancer: not all parts’ maxtrices are applied in real.
These are 3 Aurora nebulae in Ku02 system in original Freelancer:
But in SystemViewer all three are rendered in one position:
starsphere_ku02.cmp
Mine renders same as i started “optimizing”. Unlike old archieved build, where i used to reapply shader on each mesh and reset matrices for each part, but that, of course, impacts performance. (images are HD just in case, right click - open, my browser cuts large previews here so i reduce them)
I’m personally planning to bind a buffer of part indices parallel to vertices and allocate Parts[MAX_PARTS] in a shader. More no thoughts yet.
About blending, texture’s runtime format is incorrect. In my code (and this is Direct3D) there’s a conversion:
Alpha := FreeImage_IsTransparent(Targa); if Alpha then Format := DXGI_FORMAT_B8G8R8A8_UNORM else Format := DXGI_FORMAT_B8G8R8X8_UNORM; ```All i know is this makes match Freelancer in drawing starspheres.
-
Hello.
I don’t check this very often, so if you’re having rendering bugs like in Ku02 please report them in the github issues with the version of the software you’re using.
R.E. that awful cmp/mesh:
- There is a very limited amount of mesh fixups applied in the engine on load time, but they’re only applicable in very small amounts of situations. The only solution there will be to export the model properly, as the FL resource loading model simply doesn’t work in such a way that I can modify the vertex buffers at runtime and maintain full vanilla compatibility.
And with “Latest SystemViewers work for me, but not gameengine itself. Some of previous daily builds work, some don’t.” this is not something I can do anything with as there is simply not enough info. There’s a lot of game engine work going on at the moment, and while it does work with vanilla I can’t guarantee mod compatibility. Especially if you’re not using the nice Copy Details button I made when there are crash errors