#ifndef XSURFACE_H
#define XSURFACE_H

#include "xasset.h"
#include "xd3dindexbuffer.h"
#include "xrigidvertlist.h"
#include "xsurfacevertexinfo.h"
#include "xgfxpackedvertex.h"
#include "xd3dvertexbuffer.h"

class XSurface : public XAsset
{
public:
    explicit XSurface();
    ~XSurface();

    void ParseData(XDataStream *aStream) override;
    void Clear() override;

private:
    quint8 mTileMode;
    bool mDeformed;
    quint16 mVertCount;
    quint16 mTriCount;
    QVector<quint16> mTriIndices;
    XSurfaceVertexInfo mVertInfo;
    XGfxPackedVertex mVert;
    XD3DVertexBuffer mVertBuffer;
    quint32 mVertListCount;
    XRigidVertList mVertList;
    XD3DIndexBuffer mIndexBuffer;
    QVector<int> mPartBits;
};

#endif // XSURFACE_H








