www.quadsoftware.com
FAQ  FAQ   Search  Search   Memberlist  Memberlist   Usergroups  Usergroups
Register  ::  Log in Log in to check your private messages


Post new topic  Reply to topic
 DDS textures « View previous topic :: View next topic » 
Author Message
baawolf
PostPosted: Sun Sep 20, 2015 9:42 am    Post subject: DDS textures Reply with quote



Joined: 25 Mar 2015
Posts: 3

Hi,

Is there a tool or a different export option that uses png instead of DDS in the Collada models.

Collada is an open standard (although I guess you can link to any filetype) whereas DDS isn't. Personally, I don't have an easy way of getting my iOS pipeline to deal with DDS - other than manual conversion and find and replace.

Best regards and kudos for a great piece of software
Back to top
View user's profile Send private message
ALicu
PostPosted: Sun Sep 20, 2015 11:07 am    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1323

Hi,

If you are referring to Grome Collada exporter, this saves the images as png and not DDS. You do have the source code of the collada exporter (SDK/Publis/Plugins/Collada/ExpCollada) and you can easily change the export format to any format and recompile the exporter.

If you are referring to the plugin reading Collada objects, this reads the images in any format are referred inside Collada (png, dds, bmp, jpeg etc), depending on the format they were saved in by the original application that created the collada.

Kind Regards,
Adrian L.
Quad Software
Back to top
View user's profile Send private message
baawolf
PostPosted: Thu Jun 09, 2016 12:12 pm    Post subject: Reply with quote



Joined: 25 Mar 2015
Posts: 3

Hi Adrian,

I'm using Grome_3.11.09 - and the Grome Collada Exporter - it seems to default to DDS not png?

e.g.

09/06/2016 13:10 <DIR> .
09/06/2016 13:10 <DIR> ..
09/06/2016 13:08 349,680 dry_grass11.dds
09/06/2016 13:08 349,680 dry_mud01.dds
09/06/2016 13:08 77,072,757 mountain.dae
09/06/2016 13:08 349,680 rock12.dds
09/06/2016 13:08 1,068 shadow.tga
09/06/2016 13:10 0 temp.txt
09/06/2016 13:08 349,680 uneven_earth02.dds
09/06/2016 13:08 349,680 vegetation01.dds
12 File(s) 156,110,693 bytes
2 Dir(s) 4,351,492,096 bytes free

Do you have a version of the plugin that doesn't default to DDS?

If not, what line do i change to make it output PNG in SDK/Publis/Plugins/Collada/ExpCollada?

Many Thanks
Back to top
View user's profile Send private message
ALicu
PostPosted: Thu Jun 09, 2016 7:56 pm    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1323

Hi,

The function to save the images is cExpCollada::_Export_Image inside ExpCollada.cpp. It is using CopyTo function with only the file name, which is just making a copy of the file (so if the original Grome image is dds is saving it as dds).

In case you want to save under a different type you should use the second parameter to that function to indicate the file type:

image->CopyTo(_export_path + M_SZ("/") + image_path, C_IMG_TYPE_PNG);

Make sure you put the parameter to both CopyTo calls (at line 2857 and 2864). One variant is appending some padding to the terrain color images to allow continuous images between terrain zones even if bilinear filtering is being used.

Let me know if you have issues compiling the plugin.

Regards,
Adrian
Back to top
View user's profile Send private message
baawolf
PostPosted: Sun Jun 12, 2016 10:50 pm    Post subject: Reply with quote



Joined: 25 Mar 2015
Posts: 3

Hi Adrian,

Thanks - found those lines and changed easily enough - just the usual hassles completing the actual compile and link.

Firstly, version.hpp not there for boost but recreated that file the internet

Then lots of links that don't exist

libcollada_dae.lib and others.

If you have a version that spits out just pngs - or can take it as far as adding a tick box - that would be amazing.

otherwise I'll get back to these libs at some point and fix.

Thanks for your pointers again
Back to top
View user's profile Send private message
ALicu
PostPosted: Tue Jun 14, 2016 7:08 am    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1323

Hi,

Strange that the files are missing. Thank you for pointing that. The SDK supposed to contain the entire Collada DOM library. I will check that.

To make things easier, I will also compile the plugin for you (to output only PNG). I will let you know the download link shortly.

Regards,
Adrian
Back to top
View user's profile Send private message
ALicu
PostPosted: Fri Jun 17, 2016 8:39 pm    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1323

Hi,

Indeed there were some projects settings (preprocessor directives) that needed to be made to make the plugin compile with visual studio 2010 or newer.

I've updated the project to work with visual studio 2010, I've modified the export plugin to save pngs, tested it to work on Grome. You can find the archive here:

www.quadsoftware.com/storage/ColladaExpPng.rar

It contains the compiled plugin and the updated SDK source for collada dom library and the plugin. You can just unpack the content where Grome is. Let me know if you have any other issues.

Regards,
Adrian
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic 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


Based on a template by Dustin Baccetti
Powered by phpBB © 2001, 2005 phpBB Group