Read and display of PMD format model

Source: Internet
Author: User
Read and display of PMD format model
has been in the Mayflower, spent more than 10 days of research has finally come to fruition, write a diary to commemorate.
PMD, full name polygon model Document, is a three-dimensional modeling format, mainly used in Mikumikudance and Pmdeditor. The description of the format is even less, so my research mainly refer to Itsuhane's MMD library.
PMD format file is also a simple binary file, because the file format specification is more stringent, so the file chunk is not very free, relatively good analysis. The VMD file (full name Vocaloid Motion Data) describes the model action, the model skeleton needs to be interpolated to achieve animation effect, since this log may have little time after writing, so there is no in-depth study of PMD illumination, material, bone parts, and VMD parts.
Original blog, prohibited unauthorized reprint (original blog address: http://blog.csdn.net/jiangcaiyang123/article/details/8898734).
Demo program Download Address: here

Here's a screenshot of the program:






Here the default load is the Lothini model, of course, the program comes with the initial tone ミク, mirror-Tone Gemini (リン, レン), Kaito, and so on can be loaded (when you start loading these models, there are also small problems, and then carefully look at the format note to know that you need some workaround to load correctly).
The program uses the QT framework and uses OpenGL rendering, in addition to the QT state Machine framework and animation framework. The fly-to-disappear effect will be explained in a separate log. Because of the limited knowledge, OpenGL rendering still stays at the Glbegin ()/glend () level, and I don't know why it is not successful for QT programs to use multiple sampling anti-aliasing. In addition, for some reason, open this program under Ubuntu13.04. Roy's eyes are gone (presumably luo_eye.bmp files cannot be loaded) I hope it will be improved in the next release.

Here's the black history of the program, which now looks like a terrible thing to do.

#1 didn't handle the textures.


#2 also did not handle the texture well ...


#3 Terrible. ミク has no eyes L.


#4 texture, but the texture coordinates are wrong.


#5 is only drawn with line segments, and it's like abstract painting.


#6 look up to Roy Tian Yi ... o (>﹏<) o


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.