1706f2543Smrg/* 2706f2543Smrg * Xephyr - A kdrive X server thats runs in a host X window. 3706f2543Smrg * Authored by Matthew Allum <mallum@openedhand.com> 4706f2543Smrg * 5706f2543Smrg * Copyright © 2007 OpenedHand Ltd 6706f2543Smrg * 7706f2543Smrg * Permission to use, copy, modify, distribute, and sell this software and its 8706f2543Smrg * documentation for any purpose is hereby granted without fee, provided that 9706f2543Smrg * the above copyright notice appear in all copies and that both that 10706f2543Smrg * copyright notice and this permission notice appear in supporting 11706f2543Smrg * documentation, and that the name of OpenedHand Ltd not be used in 12706f2543Smrg * advertising or publicity pertaining to distribution of the software without 13706f2543Smrg * specific, written prior permission. OpenedHand Ltd makes no 14706f2543Smrg * representations about the suitability of this software for any purpose. It 15706f2543Smrg * is provided "as is" without express or implied warranty. 16706f2543Smrg * 17706f2543Smrg * OpenedHand Ltd DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 18706f2543Smrg * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO 19706f2543Smrg * EVENT SHALL OpenedHand Ltd BE LIABLE FOR ANY SPECIAL, INDIRECT OR 20706f2543Smrg * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, 21706f2543Smrg * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER 22706f2543Smrg * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 23706f2543Smrg * PERFORMANCE OF THIS SOFTWARE. 24706f2543Smrg * 25706f2543Smrg * Authors: 26706f2543Smrg * Dodji Seketeli <dodji@openedhand.com> 27706f2543Smrg */ 28706f2543Smrg 29706f2543Smrg#ifndef __EPHYRDRI_H__ 30706f2543Smrg#define __EPHYRDRI_H__ 31706f2543Smrg 32706f2543Smrg#include <xf86drm.h> 33706f2543Smrg 34706f2543SmrgBool ephyrDRIQueryDirectRenderingCapable (int a_screen, Bool *a_is_capable) ; 35706f2543SmrgBool ephyrDRIOpenConnection (int screen, drm_handle_t *a_sarea, char **a_bus_id_string) ; 36706f2543SmrgBool ephyrDRIAuthConnection (int a_screen, drm_magic_t a_magic) ; 37706f2543SmrgBool ephyrDRICloseConnection (int a_screen) ; 38706f2543SmrgBool ephyrDRIGetClientDriverName (int a_screen, 39706f2543Smrg int *a_ddx_driver_major_version, 40706f2543Smrg int *a_ddx_driver_minor_version, 41706f2543Smrg int *a_ddx_driver_patch_version, 42706f2543Smrg char ** a_client_driver_name) ; 43706f2543SmrgBool ephyrDRICreateContext (int a_screen, 44706f2543Smrg int a_visual_id, 45706f2543Smrg XID *a_returned_ctx_id, 46706f2543Smrg drm_context_t *a_hw_ctx) ; 47706f2543SmrgBool ephyrDRIDestroyContext (int a_screen, 48706f2543Smrg int a_context_id) ; 49706f2543SmrgBool ephyrDRICreateDrawable (int a_screen, 50706f2543Smrg int a_drawable, 51706f2543Smrg drm_drawable_t *a_hw_drawable) ; 52706f2543SmrgBool ephyrDRIDestroyDrawable (int a_screen, int a_drawable) ; 53706f2543SmrgBool ephyrDRIGetDrawableInfo (int a_screen, 54706f2543Smrg int /*Drawable*/a_drawable, 55706f2543Smrg unsigned int *a_index, 56706f2543Smrg unsigned int *a_stamp, 57706f2543Smrg int *a_x, 58706f2543Smrg int *a_y, 59706f2543Smrg int *a_w, 60706f2543Smrg int *a_h, 61706f2543Smrg int *a_num_clip_rects, 62706f2543Smrg drm_clip_rect_t **a_clip_rects, 63706f2543Smrg int *a_back_x, 64706f2543Smrg int *a_back_y, 65706f2543Smrg int *num_back_clip_rects, 66706f2543Smrg drm_clip_rect_t **a_back_clip_rects) ; 67706f2543SmrgBool ephyrDRIGetDeviceInfo (int a_screen, 68706f2543Smrg drm_handle_t *a_frame_buffer, 69706f2543Smrg int *a_fb_origin, 70706f2543Smrg int *a_fb_size, 71706f2543Smrg int *a_fb_stride, 72706f2543Smrg int *a_dev_private_size, 73706f2543Smrg void **a_dev_private) ; 74706f2543Smrg#endif /*__EPHYRDRI_H__*/ 75706f2543Smrg 76