Delgine 3D Tools & Content DeleD Community Edition
Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

dmf + normals? Plugin?

 
Post new topic   Reply to topic    DeleD Community Edition Forum Index -> DeleD Plugins
View previous topic :: View next topic  
Author Message
banshee777
Member


Joined: 10 Feb 2005
Posts: 37

PostPosted: Sat May 31, 2008 8:36 am    Post subject: dmf + normals? Plugin? Reply with quote

Anyone know if there is an exporter that can do the standard dmf + normals?
I'm finding the other plugin's way too complex.

or is there a really simply exporter?

that has texture name
vertex coords
text coords
normal coords
Back to top
View user's profile Send private message
jwatte
DeleD PRO user


Joined: 26 Apr 2006
Posts: 513

PostPosted: Sun Jun 01, 2008 3:10 am    Post subject: Reply with quote

The simplest text file formats I know of are .OBJ and .X.

If you want to use DeleD, you can easily calculate the normals yourself. If you have three vertices A, B and C for a triangle, then the triangle normal is simply:

N = normalize(cross((B - A), (C - A)));
Back to top
View user's profile Send private message
Jeroen
Site Admin


Joined: 07 Aug 2004
Posts: 5333
Location: The Netherlands

PostPosted: Sun Jun 01, 2008 10:45 am    Post subject: Reply with quote

Make sure that the three vertices do not line up (as in, form a straight line). In that case, the triangle is degenerate and the normal calculation will not give proper results.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
jwatte
DeleD PRO user


Joined: 26 Apr 2006
Posts: 513

PostPosted: Mon Jun 02, 2008 6:16 pm    Post subject: Reply with quote

Quote:
In that case, the triangle is degenerate and the normal calculation will not give proper results.


Mainly because there IS no proper normal in that case... Which doesn't matter, because that triangle will contribute no pixels, and will not contribute to an area-weighted vertex normal calculation :-)
Back to top
View user's profile Send private message
Paul-Jan
Site Admin


Joined: 08 Aug 2004
Posts: 3066
Location: Lage Zwaluwe

PostPosted: Mon Jun 02, 2008 6:29 pm    Post subject: Reply with quote

An import detail here is that DeleD itself does not actually manage normals (yet), so there is no use trying to write a specific exporter for them (as there is no data to export).
Back to top
View user's profile Send private message Visit poster's website
AWM Mars
Member


Joined: 06 Jan 2010
Posts: 1195
Location: Wilts England

PostPosted: Fri Jun 18, 2010 4:10 pm    Post subject: Reply with quote

Paul-Jan wrote:
An import detail here is that DeleD itself does not actually manage normals (yet), so there is no use trying to write a specific exporter for them (as there is no data to export).

Has this now been included?
I'm assuming it has as when I export to Ogre, there is an option to export smoothed normals.
_________________
Politeness is priceless when received, cost nothing to own or give, yet some cannot afford.

Checkout:
http://www.awm.mars.yourinside.com/
http://www.bccservices.co.uk
http://www.localtradecheck.co.uk
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    DeleD Community Edition Forum Index -> DeleD Plugins All times are GMT
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum