Brian Paul
e1998baef8
Implement rendering to textures for any mipmap level, any cube face, any
3D texture slice.
Added draw_offset to intel_region struct.
20 jaren geleden
Brian Paul
3e980901b0
check if copying from FBO, adjust x, y accordingly
20 jaren geleden
Brian Paul
14fe63a12b
Check for incomplete framebuffer in _mesa_Clear()
20 jaren geleden
Brian Paul
fbd147c0b5
unlock mutex before freeing data (caught w/ valgrind)
20 jaren geleden
Brian Paul
7b7c54e94c
Replace _mesa_destroy_context() with _mesa_free_context_data() because ctx
is a member of the intel_context struct and the former calls frees the
ctx pointer - BAD.
20 jaren geleden
Brian Paul
84dd9c8112
silence several -pedantic warnings
20 jaren geleden
Brian Paul
bba85343e7
remove stray semicolon
20 jaren geleden
Brian Paul
6484b373c3
s/inline/INLINE/ to allow use of -ansi flag with gcc.
20 jaren geleden
Brian Paul
245a3c54c7
merge from trunk
20 jaren geleden
Brian Paul
1266e633cc
In i915/i830_update_tex_unit() get the firstImage pointer _after_ we've called
intel_finalize_mipmap_tree().
This fixes a problem where the wrong mipmap level was used when the
texture's GL_TEXTURE_BASE_LEVEL value wasn't zero. But this only happened
the first time the texture was used. That took a while to track down!
20 jaren geleden
Brian Paul
86042f53f2
added some missing formats in _mesa_source/dest_buffer_exists()
20 jaren geleden
Brian Paul
068062f997
better switch cases
20 jaren geleden
Brian Paul
c62af8e3b7
update scissor at end of intel_draw_buffer()
20 jaren geleden
Brian Paul
8e5650d7f4
no need to pass ctx to _mesa_clip_to_region()
20 jaren geleden
Brian Paul
65f1cf2cbf
update i915/i830Scissor to use DrawBuffer instead of driDrawable bounds
20 jaren geleden
Brian Paul
f04f5e990a
minor clean-ups
20 jaren geleden
Brian Paul
1854ebe77e
more fixes and clean-up in intelCopyBuffer()
20 jaren geleden
Brian Paul
3500f2e3c4
some comments
20 jaren geleden
Brian Paul
cfeefc9b81
just comments
20 jaren geleden
Brian Paul
3ad6adfb57
another intelFlush() call
20 jaren geleden
Brian Paul
8a126f1166
fix some mapping bugs
20 jaren geleden
Brian Paul
6315aabcf2
check for NULL rb in _mesa_framebuffer_renderbuffer()
20 jaren geleden
Brian Paul
a8c2344364
Added an intelFlush() call inside intel_bind_framebuffer() to be sure
any previous rendering is completed. Not sure why this is needed when
_mesa_BindFramebufferEXT() does a FLUSH_VERTICES() call.
This fixes an offset/wrap-around bug when rendering to FBOs.
20 jaren geleden
Brian Paul
2929b2569b
added render/framebuffer locking for thread safety
20 jaren geleden
Brian Paul
f14790d7b0
tweak to render-to-texture region code
20 jaren geleden
Brian Paul
8fb2e61801
In intelCopyBuffer() use current context, not dPriv->driContextPriv->driverPrivate.
The later can lead to nested locking attempt with threaded apps.
20 jaren geleden
Brian Paul
b3c94f9d9d
move prevLockFile/Line into context struct
20 jaren geleden
Brian Paul
5b889f7f2d
INTEL_PACKCOLOR() no longer needed
20 jaren geleden
Brian Paul
0f531b5b48
Combine the bodies of _mesa_FramebufferTexture1D/2D/3DEXT into a single
function.
20 jaren geleden
Brian Paul
c6482c0d41
Comment about removing screen->fbFormat field in the future.
20 jaren geleden
Brian Paul
b71748efd1
In intelClearColor() always compute both 16bpp and 32bpp clear values
since we won't know which is needed until we're in glClear.
20 jaren geleden
Brian Paul
1c4b9edc41
Initial attempt at software fallback for rendering to a hardware texture
when the texture format isn't supported by the hw rendering system.
Doesn't work yet.
20 jaren geleden
Brian Paul
2b464d93d1
Before calling intel_region_release/reference() check if the regions
are changing.
20 jaren geleden
Brian Paul
497f80ac34
Only try to validate depth/stencil pairing for user-created FBOs.
Disable the intel_region_release/reference() code in intel_draw_buffer()
since it seems redundant with same thing in i915_state_draw_region().
20 jaren geleden
Brian Paul
2be748769b
assert(refcount > 0) in intel_region_release() - helpful for finding refernces to free'd memory
20 jaren geleden
Brian Paul
45a1083ee7
use intel_region_reference() in MakeCurrent to make sure we don't accidentally lose the screen->front/back/depth regions
20 jaren geleden
Brian Paul
3a45baa70d
fix 16bpp bug
20 jaren geleden
Brian Paul
0bc3a7ac2e
fix a test in intel_validate_paired_depth_stencil(), fixes a 16bpp bug
20 jaren geleden
Brian Paul
08f0579176
Rendering to FBO w/ stencil but w/out depth works now.
Assorted clean-ups and fixes.
20 jaren geleden
Brian Paul
d689cd0715
need to resize the depth/stencil wrappers, if present, in _mesa_resize_framebuffer()
20 jaren geleden
Brian Paul
e957f39f67
need an AllocStorage function for resizes
20 jaren geleden
Brian Paul
416f09d3e6
Merge from trunk (get RENDER_START, clip code movement)
20 jaren geleden
Brian Paul
40cc5d36fd
assertion fixes
20 jaren geleden
Brian Paul
62f9613dbc
remove some invalid assertions (storage may not yet be allocated for the renderbuffer)
20 jaren geleden
Brian Paul
7f31255eb2
Support for separate depth and stencil renderbuffers.
If the user creates several stencil renderbuffers and several depth
renderbuffers, any combination can get bound to a framebuffer object.
Since the hardware only supports combined depth+stencil buffers we
need to do some shuffling of buffer data to make things work.
This code deals with that.
Now fbotexture.c runs in hardware without the -ds flag.
Probably quite a few loose ends, clean-ups remain...
20 jaren geleden
Brian Paul
78382b4bbe
Fix a number of issues in the _mesa_extract/insert_stencil() functions.
Pass an attachment index to _mesa_update_depth/stencil_buffer() funcs to
facilitate "paired" depth/stencil renderbuffers in drivers.
New update_color_draw_buffers() and update_color_read_buffer() functions
to make the _mesa_update_framebuffer() function a little cleaner.
20 jaren geleden
Brian Paul
bd8e90857c
Call check_begin/end_render_texture() whenever the framebuffer binding
changes in _mesa_BindFramebufferEXT().
20 jaren geleden
Brian Paul
b7cc448ff8
minor clean-up
20 jaren geleden
Brian Paul
0ea582acbe
remove unused var
20 jaren geleden
Brian Paul
05c824db87
fix some _ActualFormat initializations
20 jaren geleden