src/oslinfo/oslinfo.cpp
// Print the default values for a parameter built out of floats (including
// color, point, etc., or arrays thereof).
Print the default values for a parameter built out of floats (including
color, point, etc., or arrays thereof).
Print the default values for a parameter built out of floats ( including color point etc . or arrays thereof ) .
static void
print_default_int_vals(const OSLQuery::Parameter* p, bool verbose)
{
    size_t nf = p->type.aggregate;
    size_t ne;
    if (p->varlenarray || p->type.arraylen < 0)
        ne = p->idefault.size() / nf;
    else
        ne = p->type.numelements();
    if (verbose)
        std::cout << "\t\tDefault value:";
    if (p->type.arraylen || nf > 1)
        std::cout << " [";
    for (size_t a = 0; a < ne; ++a) {
        for (size_t f = 0; f < nf; ++f)
            std::cout << ' ' << p->idefault[a * nf + f];
    }
    if (p->type.arraylen || nf > 1)
        std::cout << " ]";
    std::cout << std::endl;
}
static void print_default_int_vals ( const OSLQuery :: Parameter * p , bool verbose ) { size_t nf = p -> type . aggregate ; size_t ne ; if ( p -> varlenarray || p -> type . arraylen < 0 ) ne = p -> idefault . size ( ) / nf ; else ne = p -> type . numelements ( ) ; if ( verbose ) std :: cout << " \t \t " ; if ( p -> type . arraylen || nf > 1 ) std :: cout << " " ; for ( size_t a = 0 ; a < ne ; ++ a ) { for ( size_t f = 0 ; f < nf ; ++ f ) std :: cout << ' ' << p -> idefault [ a * nf + f ] ; } if ( p -> type . arraylen || nf > 1 ) std :: cout << " " ; std :: cout << std :: endl ; }
Print the default values for a parameter built out of floats (including
color, point, etc., or arrays thereof).
Print the default values for a parameter built out of floats ( including color point etc . or arrays thereof ) .