Page 7 of 9

Re: Mesh Combiner

Posted: Fri Aug 12, 2011 11:05 am
by Kuzy
Thank you very much Ducky, I will try.

For now I'm going in holiday for one week :D , but after that I'll give you a feedback.

Re: Mesh Combiner

Posted: Fri Aug 19, 2011 9:22 pm
by Lonesome Ducky
Alright, I'm thinking of changing the mesh combiner a bit. I think I want to make it just a mesh class derived from IMesh, so it can have more functionality. I can then more easily allow adding in other objects afterwards, and even transforming objects that are already in the mesh. Does this sound like a good idea?

Re: Mesh Combiner

Posted: Sat Aug 20, 2011 5:52 am
by Brainsaw
This is a good idea for sure. An IrrEdit plugin would be cool in that case. Otherwise I might write a scenenode (and plugin) that does combine all it's children to a single mesh, without any special new functions.

Re: Mesh Combiner

Posted: Mon Aug 22, 2011 11:09 am
by sodandk
Wierd... when I use the MeshCombiner in debug mode its fine, and when I run it in release mode from inside VS, its fine...
but when I run it in releasemode and an exe... it crashes...
any clues...?

Re: Mesh Combiner

Posted: Mon Aug 22, 2011 12:47 pm
by mongoose7
Are you sure you're running the same executable inside and outside of VS? And, if you are, are you in the same directory both times. VS probably sets the CWD to the current directory, whereas the executable is probably in 'Release'. So, it is not able to find a file and, well, I guess ... you are not checking the return value. Dereferencing a null pointer usually results in a GPF.

Re: Mesh Combiner

Posted: Mon Aug 22, 2011 3:34 pm
by sodandk
it find and loads the model and textures just fine... and if I dont use the combiner, also runs fine... but as soon I use the combiner, it dies...

Re: Mesh Combiner

Posted: Mon Aug 22, 2011 6:56 pm
by sodandk
in the function 'CMeshCombiner::packTextures'... one of the last lines... says:

Code: Select all

  delete [] occupied;
that line goes BOOM in releasemode...

Re: Mesh Combiner - problem solved!

Posted: Mon Aug 29, 2011 3:13 pm
by Kuzy
Hello Ducky and Mongoose,

I now have solved my problem with the lighting...
You were right, my normals were not correct. I changed my mesh and corrected the normals. As you expected you have no error in your combiner :-)
Thank you for your help. It gave me the right clue.

Kuzy

Re: Mesh Combiner

Posted: Wed Aug 31, 2011 4:59 pm
by Lonesome Ducky
Good to hear you got it working, hopefully the performance boost is enough

Re: Mesh Combiner

Posted: Sat Oct 01, 2011 3:12 am
by hungryninja
I want to make a minecraft-like game, but without the random map generation, in VB.NET.
1) Could you please give me the code that allows you to add and remove meshes?
2) For the minecraft-like graphics, do I need to split the pixels into multiple meshes?
3) Can I do the different textures for the sides of the cube without splitting the cube into individual squares? Should I do this?

Thanks.

Re: Mesh Combiner

Posted: Sat Oct 01, 2011 5:19 am
by Lonesome Ducky
Removing is not part of the current functionality, but should be trivial to add. I'd encourage you to look at the mesh combiner code and modify it to better suit what you need. As is, my mesh combiner will not work well for a minecraft clone. It strength lies in one time creation of a static mesh, not being constantly modified. It could serve as a starting point to make something more modifiable, though.

Re: Mesh Combiner

Posted: Sun Oct 02, 2011 5:06 am
by hungryninja
Yeah. I get your point and I don't want to convert 700 lines of code to VB.NET, but don't want to use C++.

Re: Mesh Combiner

Posted: Sun Oct 02, 2011 8:23 am
by serengeor
hungryninja wrote:Yeah. I get your point and I don't want to convert 700 lines of code to VB.NET, but don't want to use C++.
Aren't you supposed just to make a 'wrapper' on top of c++ code?

Re: Mesh Combiner

Posted: Sun Oct 02, 2011 3:44 pm
by Lonesome Ducky
hungryninja wrote:Yeah. I get your point and I don't want to convert 700 lines of code to VB.NET, but don't want to use C++.
I don't know what you want then. If you want me to write it for you, I'm not going to.

Re: Mesh Combiner

Posted: Mon Oct 03, 2011 10:44 pm
by hungryninja
still, I want to know how to do the minecraft pixel graphics.