Some experiences in writing the xNa editor over the past few days

Source: Internet
Author: User
Recently, the xNa 3D editor has been available for concentrated firepower. Let's look back and see the following progress: 1. the format conversion of the xNa internal model is completed. X /. after the fbx model is loaded in, it extracts the position and UV information that I need (color and normal are not saved for the time being and are useless on the mobile phone ); the most difficult part here is that the input model is actually very messy. The vertex format is not uniform, and it is a little troublesome to convert it into a uniform format. A preliminary static model file format is designed. For the terrain, because the cropping is involved, the Triangle List must be used. For other static decoration models, you can use the Strip algorithm to optimize it. test the efficiency on a real machine. A new virtual quad-tree is created to manage all the terrain triangle, and all the triangle is registered to the leaf node. When cropping, the visible triangle is copied to the buffer, then unified rendering; export the pre-processed quad-tree information into binary, let the phone Directly construct 4. the OBB-based scene collision detection is implemented. The hierarchical relationship is like this: sphere> AABB> OBB. If precise collision is required in the later stage, AABB tree5. different forms are considered, one set of models can be shared, but texture cannot be shared due to the content mechanism of xNa. It can only be one set of graphicsdevice .. 6. I have rewritten the resource manager, which is much more convenient and beautiful than before. Haha, what I want to do next: 1. Suddenly I had an idea to create a simulator in the editor... The underlying rendering has already come out independently. As for the game logic, there is not much difference. Moreover, the class library provided by xNa is so powerful that game logic can be developed in xNa in the early stage, after maturity, and then porting to other platforms, you only need to translate C # into Java/C ++. 2. the terrain self-shadow algorithm is added to realize the overall brightness and shade effect of static scenes through Vertex coloring. 3. start designing the animation model format .. In short, the technology used to write the editor is not very difficult, but there are too many things in combination ~~ The more I write, the more I think it is unmeasurable, but I am confident that such a freshman can't do such a thing?

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.