i965: Fix unresolved symbol intel_miptree_pitch_align.

For some reason, I thought that function was shared with i915tex... The good
news is that i965 gets to keep the lower pitch alignment requirements.

Thanks to Todd Merrill for pointing out the problem on IRC.
This commit is contained in:
Michel Dänzer 2008-01-11 16:32:39 +01:00
parent b9f3f732aa
commit 45cdb6eb45
2 changed files with 27 additions and 0 deletions

View file

@ -110,6 +110,29 @@ struct intel_mipmap_tree *intel_miptree_create( struct intel_context *intel,
}
/**
* intel_miptree_pitch_align:
*
* @intel: intel context pointer
*
* @mt: the miptree to compute pitch alignment for
*
* @pitch: the natural pitch value
*
* Given @pitch, compute a larger value which accounts for
* any necessary alignment required by the device
*/
int intel_miptree_pitch_align (struct intel_context *intel,
struct intel_mipmap_tree *mt,
int pitch)
{
if (!mt->compressed)
pitch = (pitch * mt->cpp + 3) & ~3;
return pitch;
}
void intel_miptree_destroy( struct intel_context *intel,
struct intel_mipmap_tree *mt )

View file

@ -115,6 +115,10 @@ struct intel_mipmap_tree *intel_miptree_create( struct intel_context *intel,
GLuint cpp,
GLboolean compressed);
int intel_miptree_pitch_align (struct intel_context *intel,
struct intel_mipmap_tree *mt,
int pitch);
void intel_miptree_destroy( struct intel_context *intel,
struct intel_mipmap_tree *mt );