Changeset 1788


Ignore:
Timestamp:
Aug 22, 2012, 7:14:02 PM (11 years ago)
Author:
sam
Message:

gpu: document and tweak some class declarations.

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gpu/vertexbuffer.h

    r1688 r1788  
    3737};
    3838
     39/* A safe enum to indicate how a vertex stream is going to be used. For
     40 * now there is only TexCoord and not TexCoord0 TexCoord1 etc. because
     41 * we can always reorganise the vertex declaration for the indices to
     42 * match. If the need arises these enums will be added. */
    3943struct VertexUsage
    4044{
     
    5862    m_value;
    5963
    60     inline VertexUsage(Value v) { m_value = v; }
     64    inline VertexUsage(Value v) : m_value(v) {}
    6165    inline operator Value() { return m_value; }
    6266};
    6367
     68/* A safe enum to indicate what kind of primitive to draw. Used in
     69 * VertexDeclaration::DrawElements() for instance. */
    6470struct MeshPrimitive
    6571{
     
    7177    m_value;
    7278
    73     inline MeshPrimitive(Value v) { m_value = v; }
     79    inline MeshPrimitive(Value v) : m_value(v) {}
    7480    inline operator Value() { return m_value; }
    7581};
  • trunk/src/video.h

    r1772 r1788  
    2828    {
    2929        /* Note: D3D9 doesn't appear to support the accumulation buffer,
    30          * and it is a deprecated OpenGL feature. No reasone to support it. */
     30         * and it is a deprecated OpenGL feature. No reason to support it. */
    3131        Color   = 1 << 0,
    3232        Depth   = 1 << 1,
     
    3737    m_value;
    3838
    39     inline ClearMask(Value v) { m_value = v; }
    40     inline ClearMask(uint64_t i) { m_value = (Value)i; }
     39    inline ClearMask(Value v) : m_value(v) {}
     40    inline ClearMask(uint64_t i) : m_value((Value)i) {}
    4141    inline operator Value() { return m_value; }
    4242};
Note: See TracChangeset for help on using the changeset viewer.