Search found 4 matches

by jolin1337
Sun Oct 06, 2013 2:01 pm
Forum: Coding Blender
Topic: Read .blend file materials
Replies: 5
Views: 11916

Nice, it is still confusing about the link type of the data structure but I think I have solved it now. I solved it by ignoring the structure type and read past the structure, and I read the data as it only would be integers. With the count of totcol(the amount of materials) and it worked! I know th...
by jolin1337
Sat Oct 05, 2013 6:47 pm
Forum: Coding Blender
Topic: Read .blend file materials
Replies: 5
Views: 11916

I'm not sure what code you use but I've read a lot of the data inside a .blend using FBT from GameKit. Check http://www.gamekit.org there's a lot of code there that does the same. Nice you are correct, there is a lot of code there, I'll check it out and see if I can find something. I believe that t...
by jolin1337
Thu Sep 26, 2013 5:15 pm
Forum: Coding Blender
Topic: Read .blend file materials
Replies: 5
Views: 11916

Re: Read .blend file materials

My code is written like this when reading a mesh material list, this is obvious wrong, any one that can point me to the right direction? :?: void Mesh::parseMaterials(StructureDNA *sdna, FileBlockHeader *fbh, std::vector<Material > *mat) { if(fbh == 0 || totcol == 0) return; FileBlockHeader *mfbh = ...
by jolin1337
Tue Sep 24, 2013 9:25 am
Forum: Coding Blender
Topic: Read .blend file materials
Replies: 5
Views: 11916

Read .blend file materials

Hi, This is my first post on this forum. My current project is to write a c++ application for reading a .blend file. I have been successful until now. To test my application I render it in OpenGL. I have read the materials from a .blend file that contains one mesh with 6 materials attached to differ...