static void AcceptParamProc (ButtoN b) { ApplyParams (b); CloseParamWindowProc (ParentWindow (b)); ClearWindowFlag (b); return; }
void CTextureCubeMap::UploadSubRegion(EFace const Face, void const * const Data, vec2u const & Offset, vec2u const & Size, EFormatComponents const Components, EScalarType const Type) { CheckedGLCall(glBindTexture(GL_TEXTURE_CUBE_MAP, Handle)); CheckExistingErrors(Texture2D::SubImage); glTexSubImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + (int) Face, 0, Offset.X, Offset.Y, Size.X, Size.Y, FormatMatrix[(int) Components], Util::ScalarTypeMatrix[(int) Type], Data); if (OpenGLError()) { cerr << "Error occured during glTexSubImage2D for CTextureCubeMap: " << GetOpenGLError() << endl; cerr << "Handle is " << Handle << endl; cerr << "Offset is " << Offset << endl; cerr << "Size is " << Size << endl; cerr << "Format is " << FormatStringMatrix[(int) Components] << endl; cerr << "Type is " << Util::ScalarTypeStringMatrix[(int) Type] << endl; cerr << endl; } else { if (MipMaps) CheckedGLCall(glGenerateMipmap(GL_TEXTURE_CUBE_MAP)); ApplyParams(); } CheckedGLCall(glBindTexture(GL_TEXTURE_CUBE_MAP, 0)); }
static void UpdateParamProc (ButtoN b) { ApplyParams (b); return; }
void CTexture::SetAnisotropy(f32 const Anisotropy) { this->Anisotropy = Anisotropy; ApplyParams(); }
void CTexture::SetWrapMode(EWrapMode const WrapMode) { this->WrapMode = WrapMode; ApplyParams(); }
void CTexture::SetMipMapFilter(EFilter const MipMapFilter) { this->MipMapFilter = MipMapFilter; ApplyParams(); }
void CTexture::SetMagFilter(EFilter const MagFilter) { this->MagFilter = MagFilter; ApplyParams(); }