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
 texture's name was add number by grome « View previous topic :: View next topic » 
Author Message
inucasoftware
PostPosted: Fri Oct 19, 2012 7:45 am    Post subject: texture's name was add number by grome Reply with quote



Joined: 08 Jun 2011
Posts: 18

texture's name was add number by grome tool

when add layer and exist same texture name.

my export use texname.

look at image.

layer SP grass_sand max110 0 5 3 -> time_sp_04
layer Color Layer 15 -> tile_sp_040 ( add index 0 )

how to solve?

Back to top
View user's profile Send private message
ALicu
PostPosted: Fri Oct 19, 2012 1:18 pm    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1326

Hi,

Adding a number at the end is sometimes happening when there is a texture already existent in scene but deleted (it is present in the undo stack). This is done in this way so names don't conflict (the texture deleted that is undo is considered different from the one just added).

You should not worry about this since both textures refer to the same image. So when you export the scene you will just find out that the layer is referring the same image.

Can you tell me what is the final problem you are getting from this naming convention?

Kind Regards,
Adrian L.
Back to top
View user's profile Send private message
inucasoftware
PostPosted: Mon Oct 22, 2012 1:24 am    Post subject: Reply with quote



Joined: 08 Jun 2011
Posts: 18

texture list is layer count.

differ texture name is add layer count.

can i get current texture name?

by other function?

code )

sTextureChannel channel = md->channels[j];
iTexture* texture = channel.source;
sTextureMapping *pMapping = channel.mapping;

const char* TextureName = texture->Name(); <= differ texture name
Back to top
View user's profile Send private message
ALicu
PostPosted: Mon Oct 22, 2012 8:01 am    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1326

Hi,

Once you get the layer texture obtain the image from which the texture was created:

Code:

iImage *img = texture->GetImage();
if(img)
{
   const char* ImageName = img->Name(); // or use img->GetPath() to get the file path.

   // ...

   img->CloseInterface();
}


Images should be the same (with the same name).

Kind Regards,
Adrian L.
Back to top
View user's profile Send private message
inucasoftware
PostPosted: Tue Oct 23, 2012 7:45 am    Post subject: Reply with quote



Joined: 08 Jun 2011
Posts: 18

i checked Name() and GetPath().

Name Value was Changed by grome tool.

i will process GetPath Value.

thank for reply.
Back to top
View user's profile Send private message
ALicu
PostPosted: Wed Oct 24, 2012 8:02 am    Post subject: Reply with quote



Joined: 12 Feb 2007
Posts: 1326

Hi,

It is strange that the value of name was changed. It means that the images should be different too. Can you tell me the names returned in your case?

Kind Regards,
Adrian L.
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