| 2027 | } |
| 2028 | |
| 2029 | void Tr2Effect::AddLoddable( ITriEffectParameter* param, const char* name ) |
| 2030 | { |
| 2031 | if( ITriEffectTextureParameterPtr loddable = BlueCastPtr( param ) ) |
| 2032 | { |
| 2033 | auto found = find( begin( m_lodTextureParameters ), end( m_lodTextureParameters ), loddable ); |
| 2034 | if( found == end( m_lodTextureParameters ) ) |
| 2035 | { |
| 2036 | std::array<float, ITriEffectTextureParameter::UV_SET_MAX_COUNT> uvScale; |
| 2037 | if( ExtractLodingAnnotations( uvScale, name, m_shader->GetEffectDescription().annotations, m_constParameters ) ) |
| 2038 | { |
| 2039 | loddable->EnableTextureLoding( uvScale ); |
| 2040 | } |
| 2041 | else |
| 2042 | { |
| 2043 | loddable->DisableTextureLoding(); |
| 2044 | } |
| 2045 | m_lodTextureParameters.push_back( loddable ); |
| 2046 | } |
| 2047 | } |
| 2048 | } |
| 2049 | |
| 2050 | void Tr2Effect::SetVariableStore( Tr2VariableStore* variableStore ) |
| 2051 | { |
nothing calls this directly
no test coverage detected