GetVertexColorSpecular (inline)

...

Syntax

//
//   Strong typing definition
//

static  inline  uint32_t    GetVertexColorSpecular(
                                    OwlModel                model,
                                    const void              * vertexBuffer,
                                    int64_t                 vertexIndex,
                                    int64_t                 setting
                                )
{
    uint32_t    specular = 0;
    GetVertexColor(
            model,
            vertexBuffer,
            vertexIndex,
            setting,
            nullptr,                            //    ambient
            nullptr,                            //    diffuse
            nullptr,                            //    emissive
            &specular
        );
    return  specular;
}


//
//   Weak typing definition
//

static  inline  uint32_t    GetVertexColorSpecular(
                                    int64_t                 model,
                                    const void              * vertexBuffer,
                                    int64_t                 vertexIndex,
                                    int64_t                 setting
                                )
{
    uint32_t    specular = 0;
    GetVertexColor(
            model,
            vertexBuffer,
            vertexIndex,
            setting,
            nullptr,                            //    ambient
            nullptr,                            //    diffuse
            nullptr,                            //    emissive
            &specular
        );
    return  specular;
}
    

Property model

Size: 64 bit / 8 byte (value)
The handle to the model. The model handle is static during its existance. Several models can be opened simultaniously within one session. Different models are always independent, threads are allowed to be running on different models simultaniously.

Property vertexBuffer

Size: 64 bit / 8 byte (reference)
The array of vertices, this array is allocated by the host application. Depending on SetFormat() the array exists of 32 bit (4 byte) single precision floats or 64 bit (8 byte) double precision floats. Each vertex elements exists of several elemens, i.e. X, Y, Z values, but optionally also nX, nY, nZ, texture coordinates, bitangent / binormal coordinates, colors etc. What is contained is defined by SetFormat() and can be retrieved via GetFormat(). The host application has to make sure enough memory is allocated for the vertexBuffer array.

Property vertexIndex

Size: 64 bit / 8 byte (value)
The index in the vertex buffer.

Property setting

Size: 64 bit / 8 byte (value)
The setting is the data that is defined for bitwise operations, only bits set in the mask will be relevant.