* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "pipe/p_context.h"
#include "pipe/p_defines.h"
#include "pipe/p_screen.h"
#include "util/u_gen_mipmap.h"
#include "pipe/p_context.h"
#include "pipe/p_defines.h"
#include "pipe/p_screen.h"
#include "util/u_gen_mipmap.h"
/** Check if we have a front color buffer and if it's been drawn to. */
static INLINE GLboolean
is_front_buffer_dirty(struct st_context *st)
{
/** Check if we have a front color buffer and if it's been drawn to. */
static INLINE GLboolean
is_front_buffer_dirty(struct st_context *st)
{
- if (st->frontbuffer_status == FRONT_STATUS_DIRTY) {
- return GL_TRUE;
- }
- else {
- GLframebuffer *fb = st->ctx->DrawBuffer;
- struct st_renderbuffer *strb
- = st_renderbuffer(fb->Attachment[BUFFER_FRONT_LEFT].Renderbuffer);
- return strb && strb->defined;
- }
+ struct gl_framebuffer *fb = st->ctx->DrawBuffer;
+ struct st_renderbuffer *strb
+ = st_renderbuffer(fb->Attachment[BUFFER_FRONT_LEFT].Renderbuffer);
+ return strb && strb->defined;
-void st_flush( struct st_context *st, uint pipeFlushFlags,
- struct pipe_fence_handle **fence )
+void st_flush(struct st_context *st,
+ struct pipe_fence_handle **fence,
+ unsigned flags)
- st->pipe->screen->fence_finish(st->pipe->screen, fence, 0);
+ st->pipe->screen->fence_finish(st->pipe->screen, fence,
+ PIPE_TIMEOUT_INFINITE);
/* Don't call st_finish() here. It is not the state tracker's
* responsibilty to inject sleeps in the hope of avoiding buffer
* synchronization issues. Calling finish() here will just hide
* problems that need to be fixed elsewhere.
*/
/* Don't call st_finish() here. It is not the state tracker's
* responsibilty to inject sleeps in the hope of avoiding buffer
* synchronization issues. Calling finish() here will just hide
* problems that need to be fixed elsewhere.
*/