summaryrefslogtreecommitdiff
path: root/src/mesa/main/mipmap.c
AgeCommit message (Collapse)Author
2011-03-08mesa: add EXT_texture_compression_latcMarek Olšák
The encoding/decoding algorithms are shared with RGTC. Thanks to some magic with the base format, the RGTC texstore functions work for LATC too. swrast passes the related piglit tests besides two things: - The alpha channel is wrong (it's always 1), however the incorrect alpha channel makes some other tests fail too, so I guess it's unrelated to LATC. - Signed LATC fetches aren't correct yet (signed values are clamped to [0,1]), however RGTC has the same problem. Further testing (with other of my patches) shows that hardware drivers and softpipe work. BTW, ETQW uses this extension.
2011-03-02rgtc: fixup mipmap generationDave Airlie
this allows swrast to pass mipmap generation for these formats.
2011-02-16mesa: fix texture3D mipmap generation for UNSIGNED_BYTE_3_3_2 and 4_4Marek Olšák
Oops, I copy-pasted a typo from 3_3_2. The 3_3_2 part is a candidate for 7.9 and 7.10. The 4_4 part isn't, because AL44 is in neither branches.
2011-02-16mesa: fix mipmap generation for MESA_FORMAT_AL44Marek Olšák
This was missed when implementing AL44.
2011-01-05mesa: Include mtypes.h in files that use gl_context struct.Vinson Lee
Directly include mtypes.h if a file uses a gl_context struct. This allows future removal of headers that are not strictly necessary but indirectly include mtypes.h for a file.
2010-11-18mesa: pass gl_format to _mesa_init_teximage_fields()Brian Paul
This should prevent the field going unset in the future. See bug http://bugs.freedesktop.org/show_bug.cgi?id=31544 for background. Also remove unneeded calls to clear_teximage_fields(). Finally, call _mesa_set_fetch_functions() from the _mesa_init_teximage_fields() function so callers have one less thing to worry about.
2010-11-11mesa: handle more pixel types in mipmap generation codeBrian Paul
NOTE: This is a candidate for the 7.9 branch.
2010-10-18mesa: Add missing else in do_row_3DBrian Rogers
This fixes erroneous "bad format in do_row()" messages Signed-off-by: Brian Paul <brianp@vmware.com>
2010-10-13Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg
2010-09-25mesa/mipmap: fix warning since 1acadebd6270d3604b026842b8a21360968618a0Dave Airlie
1acadebd6270d3604b026842b8a21360968618a0 fixed the pointer but not the cast.
2010-09-24mesa: Fix type typo in glGenerateMipmap handling of GL_UNSIGNED_INT data.Eric Anholt
Fixes ARB_depth_texture/fbo-generatemipmap-formats.
2010-09-01mesa: fix out of bounds memory read in mipmap gen codeBrian Paul
Out of bounds reads could happen for reducing WxH to WxH/2 or WxH to W/2xH. Fixes fd.o bug 29918.
2010-04-23mesa: simplify some code in _mesa_generate_mipmap()Brian Paul
2010-03-04mesa: Add asserts to check inputs to memcpy.Vinson Lee
2010-03-02mesa: Add asserts to check inputs to memcpy.Vinson Lee
2010-02-27mesa: Add asserts to check inputs to memcpy.Vinson Lee
2010-02-27mesa: Add assert to check input to memcpy is not null.Vinson Lee
2010-02-19Replace the _mesa_*printf() wrappers with the plain libc versionsKristian Høgsberg
2010-02-19Replace _mesa_malloc, _mesa_calloc and _mesa_free with plain libc versionsKristian Høgsberg
2010-02-19mesa: replace old MEMCPY macro with memcpyBrian Paul
2010-01-18mesa: Remove unnecessary header from mipmap.c.Vinson Lee
2009-10-28Merge branch 'texformat-rework'Brian Paul
Conflicts: src/mesa/drivers/dri/radeon/radeon_fbo.c src/mesa/drivers/dri/s3v/s3v_tex.c src/mesa/drivers/dri/s3v/s3v_xmesa.c src/mesa/drivers/dri/trident/trident_context.c src/mesa/main/debug.c src/mesa/main/mipmap.c src/mesa/main/texformat.c src/mesa/main/texgetimage.c
2009-10-25mesa: begin removing _mesa_compressed_row_stride() callsBrian Paul
Use equivalent _mesa_format_row_stride() function instead.
2009-10-24mesa: change compressed texture size callsBrian Paul
Replace calls to ctx->Driver.CompressedTextureSize with calls to _mesa_format_image_size. The former always called the later.
2009-10-05mesa: move _mesa_format_to_type_and_comps() to formats.cBrian Paul
2009-10-05Use _mesa_select_tex_image() rather than hardcoding face 0.Michel Dänzer
Fixes crash loading a map in sauerbraten with hwmipmap 1 in ~/.sauerbraten/config.cfg.
2009-10-01mesa: removed gl_texture_image::CompressedSize fieldBrian Paul
Just call ctx->Driver.CompressedTextureSize() when we need to get the compressed image size.
2009-10-01mesa: remove gl_texture_image::IsCompressed fieldBrian Paul
Use _mesa_is_format_compressed() instead.
2009-10-01mesa: fix memory leak when generating mipmaps for compressed texturesBrian Paul
2009-09-30mesa: remove GLchan-based formats; use hw 8-bit/channel formats insteadBrian Paul
Removed: MESA_FORMAT_RGBA, RGB, ALPHA, LUMINANCE, LUMINANCE_ALPHA, INTENSITY.
2009-09-30mesa: replace gl_texture_format with gl_formatBrian Paul
Now gl_texture_image::TexFormat is a simple MESA_FORMAT_x enum. ctx->Driver.ChooseTexture format also returns a MESA_FORMAT_x. gl_texture_format will go away next.
2009-09-28mesa: use _mesa_texstore()Brian Paul
2009-09-27mesa: change _mesa_format_to_type_and_comps() format parameter typeBrian Paul
2009-09-27mesa: use _mesa_get_format_bytes()Brian Paul
2009-09-27mesa: use _mesa_get_texstore_func()Brian Paul
2009-06-24Merge branch 'mesa_7_5_branch'Brian Paul
Conflicts: src/mesa/drivers/dri/i915/i915_tex_layout.c src/mesa/drivers/dri/i965/brw_wm_glsl.c src/mesa/drivers/dri/intel/intel_buffer_objects.c src/mesa/drivers/dri/intel/intel_pixel_bitmap.c src/mesa/drivers/dri/intel/intel_pixel_draw.c src/mesa/main/enums.c src/mesa/main/texstate.c src/mesa/vbo/vbo_exec_array.c
2009-06-19Always free image offsets memory when re-initializing texture image fields.Michel Dänzer
Fixes leak running compiz with direct rendering.
2009-05-18Merge branch 'mesa_7_5_branch'Brian Paul
Conflicts: Makefile src/mesa/main/version.h
2009-05-18mesa: comments for _mesa_generate_mipmap_level()Brian Paul
2009-05-11mesa: updated comments for _mesa_generate_mipmap()Brian Paul
2009-03-31fix ugly copy/paste error in mipmap generation codeRoland Scheidegger
2009-03-28mesa: add new signed rgba texture formatRoland Scheidegger
This is a (partial) backport of the signed texture format support in OGL 3.1. Since it wasn't promoted from an existing extension roll our own.
2009-03-17mesa: update/fix doxygen commentsVinson Lee
2009-03-12mesa: add support for ATI_envmap_bumpmapRoland Scheidegger
add new entrypoints, new texture format, etc translate in texenvprogram.c for drivers using the mesa-generated tex env fragment program also handled in swrast, but not tested (cannot work due to negative texel results not handled correctly)
2009-01-06mesa: Fix the size per pixel for packed pixel format data type.Xiang, Haihao
2008-12-19Add do_row_3d for mipmapping 3D texturesIan Romanick
Previously 3D textures were mipmapped using multiple passed through the 2D mipmap generation code. This had 3 disadvantages. First, the extra passes were slow. Second, this required the allocation of a temporary buffer to hold intermediate data. Third, and most important, the extra passes caused loss of additional bits due to integer division / bit-shifting. With this change, our mipmapgen conformance test passes for non-compressed texture formats.
2008-12-19Fix typeo in mipmap filter for GL_UNSIGNED_SHORT_1_5_5_5_REVIan Romanick
2008-09-23mesa: Apply MSVC portability fixes from Alan Hourihane.José Fonseca
2008-09-21code refactoring, new next_mipmap_level_size() functionBrian
(cherry picked from commit c22d9152e33792ea58426c53bc9b96bf552b0b44)
2008-09-21refactor code, export _mesa_generate_mipmap_level()Brian