Horde3D

Next-Generation Graphics Engine
It is currently 13.11.2024, 07:30

All times are UTC + 1 hour




Post new topic Reply to topic  [ 9 posts ] 
Author Message
PostPosted: 29.05.2008, 00:30 
Offline

Joined: 15.05.2008, 05:32
Posts: 46
Location: California
I've made the following changes to Horde, if someone wants them let me know:

  • Color per vertex in the Collada converter and in Horde
  • Pre-multiplied alpha blend mode
  • wrap_s, wrap_t, minfilter, magfilter and mipfilter values from the DAE file are read and stored by the Collada converter
  • wrap_s is used to write out the wrapping mode for textures in the material
  • Added a function to set up view matrices for rendering with just camera-rotation on the modelview stack, this means it follows the camera around. I added a new pipeline command to render geometry like this. I use this to render a skydome.
  • The Collada converter converts textures from whatever format they are in to .PNG and are copied to the textures folder, if the source texture is newer than the output texture. I'm using FreeImage to do this this.
  • The Collada converter output folders for textures, materials and models are configurable on the command line
  • Max number of joints is configurable on the Collada converter command line

I know I have some more changes here and there that are specific to my project too...


Top
 Profile  
Reply with quote  
PostPosted: 29.05.2008, 22:33 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
Just post the patches, I'm sure someone will find them very usefull or they'll get integrated it into svn.


Top
 Profile  
Reply with quote  
PostPosted: 01.06.2008, 19:24 
Offline

Joined: 02.01.2008, 18:34
Posts: 14
I would be interested in your changes, could you please post a patch.

I believe the following should be integrated into the main branch:

Quote:
Color per vertex in the Collada converter and in Horde
Pre-multiplied alpha blend mode
wrap_s, wrap_t, minfilter, magfilter and mipfilter values from the DAE file are read and stored by the Collada converter
wrap_s is used to write out the wrapping mode for textures in the material
The Collada converter converts textures from whatever format they are in to .PNG and are copied to the textures folder, if the source texture is newer than the output texture. I'm using FreeImage to do this this.
The Collada converter output folders for textures, materials and models are configurable on the command line


Currently utImage uses STBI, it probably doesn't make sense to use two different image loaders in the source base (FreeImage could be replaced with STBI). The converting and copying of textures should also probably be optional, as should the output type.


Top
 Profile  
Reply with quote  
PostPosted: 01.06.2008, 21:53 
Offline

Joined: 15.05.2008, 05:32
Posts: 46
Location: California
I'll post a patch when I have time, I checked all the changes into a local repository so I need to get a clean Horde into a SVN repository before I can make a patch.

I don't think STBI supports what I'm currently using from Freeimage, PSD files with multiple layers, saving all kinds of different file-formats, etc. But I don't really care what is put into the main branch.


Top
 Profile  
Reply with quote  
PostPosted: 05.06.2008, 19:46 
Offline

Joined: 15.05.2008, 05:32
Posts: 46
Location: California
Unified diffs attached. I started with revision 28 and added my changes.

---------------------------------------------------------------------------
184
Using MultiThreaded DLL and MultiThreaded Debug DLL.
Output different files for Release build and Debug build to avoid issues when switching back and forth.

186
Added function strstri().

187
Added functions Mirror() and Compare() to the DaeSource class.

188
Textures are converted to PNG and written to the output folder.
Output-paths for textures, materials and models can be specified on the command line.
Color per vertex was added.
'draw_always' property added to scene-nodes, currently set to true when 'skydome' is on the node-name.
Materials write out texture repeat mode using the wrap_s property from the Collada file.
Material class is written as 'translucent' or 'opaque' depending on material effect transparency setting.
Material class is written as 'skydome' for materials with 'skydome' in the name.
Created the class DaeMap which is used by the DaeEffect class for the diffuse texture map.
Added geometry mirroring and node mirroring when node matrix determinant is negative. This duplicates the mesh and mirrors the matrix.

189
Added a draw-always flag to nodes to avoid culling.
Added color-per-vertex to VertexData class.
VertexData class now calculates the size of the vertex instead of using constants in the source.
Added pipeline-command 'DrawSkydome' for drawing things where the camera is with the inverse camera rotation.
Added Pre-Multiplied alpha blend mode (ONE,ONE_MINUS_SRC_ALPHA)
Added functions setTransformRad() to use radians instead of angles.

191
GLFW as DLL.

193
Removing animation fro nodes that do not move.
Fixed a bug when mirroring node matrices. There is still a bug there for some nodes.
Added call to mirror geometry and nodes.
Added call to convert textures.
Added call to set the output paths.

194
Fixed a bug where the vertex colors were not written to the GEO file.
When mirroring the node I calculate the matrix the same way processNode() does.

195
Removing animated matrices from Nodes that do not move.

200
Added color to Overlay and to Text.


Attachments:
Horde3D diffs.rar [29.77 KiB]
Downloaded 683 times
Top
 Profile  
Reply with quote  
PostPosted: 05.06.2008, 22:38 
Offline

Joined: 18.05.2008, 17:47
Posts: 96
thanks 8)


Top
 Profile  
Reply with quote  
PostPosted: 17.07.2008, 23:28 
Offline

Joined: 03.07.2008, 01:23
Posts: 50
What happened to this? Has some of it been integrated?


Top
 Profile  
Reply with quote  
PostPosted: 19.07.2008, 09:37 
Offline
Tool Developer

Joined: 13.11.2007, 11:07
Posts: 1150
Location: Germany
First of all, thanks for all these patches.

To answer the question of cantele:
cantele wrote:
What happened to this? Has some of it been integrated?


roarflolo wrote:
Using MultiThreaded DLL and MultiThreaded Debug DLL.

What's the advantage of doing that? It just creates a dependency to the C++ runtime libraries from Microsoft.

roarflolo wrote:
Output different files for Release build and Debug build to avoid issues when switching back and forth.

We had a discussion about that at this thread.

roarflolo wrote:
Textures are converted to PNG and written to the output folder.

I can't see the the reason why this should be any advantage. Maybe we could add this optionally, but personally I would think integrating
DDS would make more sense. After doing that we could think about an automatical conversion to DDS. See also this thread.

roarflolo wrote:
Output-paths for textures, materials and models can be specified on the command line.

That's something we want to integrate.
roarflolo wrote:
Color per vertex was added.

That may break the cache alignment of the vertex format. But that's something that should be discussed with 'marciano'.

roarflolo wrote:
'draw_always' property added to scene-nodes, currently set to true when 'skydome' is on the node-name.

That's something very specific. We could think about a configuration file where you can set some name mapping. But currently we don't think
about integrating that yet.
roarflolo wrote:
Materials write out texture repeat mode using the wrap_s property from the Collada file.
Material class is written as 'translucent' or 'opaque' depending on material effect transparency setting.

I posted a patch only integrating that to 'marciano' but we hadn't the time to integrate that yet.

roarflolo wrote:
Material class is written as 'skydome' for materials with 'skydome' in the name.

Again this is very specific.

roarflolo wrote:
Added geometry mirroring and node mirroring when node matrix determinant is negative. This duplicates the mesh and mirrors the matrix.

That's something we definitely want to integrate in the future.

roarflolo wrote:
Added a draw-always flag to nodes to avoid culling.

What's the reason for that?

roarflolo wrote:
Added Pre-Multiplied alpha blend mode (ONE,ONE_MINUS_SRC_ALPHA)

May be integrated.

roarflolo wrote:
Added functions setTransformRad() to use radians instead of angles.

Why? Converting is very trivial and the additional method is padding out the API needlessly I think.

roarflolo wrote:
GLFW as DLL.

Why?

roarflolo wrote:
Removing animation from nodes that do not move.

That's something I discussed with Nicolas yesterday. There may be some problems with that. But we will keep an eye on it and may integrate it in the future.

roarflolo wrote:
Added color to Overlay and to Text.

Haven't checked the solution proposed in the patch yet.

Although some of my comments may sound a bit negative, I want to aver that I'm really thankfull for sharing these patches!


Top
 Profile  
Reply with quote  
PostPosted: 19.07.2008, 14:23 
Offline
Engine Developer

Joined: 10.09.2006, 15:52
Posts: 1217
Volker wrote:
roarflolo wrote:
Color per vertex was added.

That may break the cache alignment of the vertex format. But that's something that should be discussed with 'marciano'.

The best performance for the GPU is achieved when the vertex size in a stream is a multiple of 32 bytes. That was the main argument against vertex colors. But we had to break this for supporting software skinning anyway, so actually we could look into supporting vertex colors again.

Volker wrote:
roarflolo wrote:
Removing animation from nodes that do not move.

That's something I discussed with Nicolas yesterday. There may be some problems with that. But we will keep an eye on it and may integrate it in the future.

Imagine you have your model in an arbitrary pose after doing some animations. Now you want to set it back to some other pose exported from 3dsmax. The problem is, if there is no transformation stored for unanimated nodes, you won't be able to restore the correct pose as it is seen in 3dsmax. It would be better to have some animation compression, so that an unanimated node only stores one transformation instead of the same for each frame. I think you also mention something like that in your changelog.[*]


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group