Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libva
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
libva
Commits
7376e698
Commit
7376e698
authored
May 12, 2010
by
Austin Yuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix build issue
Signed-off-by:
Austin Yuan
<
shengquan.yuan@gmail.com
>
parent
deb99d31
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
54 additions
and
37 deletions
+54
-37
configure.ac
configure.ac
+2
-1
va/Makefile.am
va/Makefile.am
+30
-14
va/glx/va_glx_impl.c
va/glx/va_glx_impl.c
+20
-20
va/glx/va_glx_impl.h
va/glx/va_glx_impl.h
+2
-2
No files found.
configure.ac
View file @
7376e698
...
...
@@ -153,7 +153,8 @@ AC_OUTPUT([
va/Makefile
va/va_version.h
va/x11/Makefile
va/android/Makefile
va/glx/Makefile
va/dummy/Makefile
dummy_drv_video/Makefile
i965_drv_video/Makefile
i965_drv_video/shaders/Makefile
...
...
va/Makefile.am
View file @
7376e698
...
...
@@ -27,10 +27,8 @@ INCLUDES = \
LDADD
=
\
$(LIBVA_LT_LDFLAGS)
lib_LTLIBRARIES
=
\
libva.la
\
libva-tpi.la
\
libva-x11.la
libva_x11_backend
=
libva-x11.la
libva_x11_backenddir
=
x11
libva_ladir
=
$(libdir)
libva_la_LDFLAGS
=
$(LDADD)
-no-undefined
...
...
@@ -40,28 +38,46 @@ libva_tpi_ladir = $(libdir)
libva_tpi_la_LDFLAGS
=
$(LDADD)
-no-undefined
libva_tpi_la_LIBADD
=
$(libvacorelib)
-ldl
libva_x11_la_SOURCES
=
libva_x11_la_LIBADD
=
$(libvacorelib)
x11/libva_x11.la
$(LIBVA_LIBS)
$(X11_LIBS)
$(XEXT_LIBS)
$(DRM_LIBS)
$(XFIXES_LIBS)
libva_x11_la_LDFLAGS
=
$(LDADD)
libva_x11_la_DEPENDENCIES
=
$(libvacorelib)
x11/libva_x11.la
SUBDIRS
=
x11
if
BUILD_DUMMY_BACKEND
lib_LTLIBRARIES
+=
libva-dummy.la
libva_dummy_backend
=
libva-dummy.la
libva_dummy_backenddir
=
dummy
libva_dummy_la_SOURCES
=
libva_dummy_la_LIBADD
=
$(libvacorelib)
dummy/libva_dummy.la
$(LIBVA_LIBS)
$(DRM_LIBS)
libva_dummy_la_LDFLAGS
=
$(LDADD)
libva_dummy_la_DEPENDENCIES
=
$(libvacorelib)
dummy/libva_dummy.la
else
libva_dummy_backend
=
libva_dummy_backenddir
=
endif
if
USE_GLX
libva_glx_backend
=
libva-glx.la
libva_glx_backenddir
=
glx
SUBDIRS
+=
dummy
libva_glx_la_SOURCES
=
libva_glx_la_LIBADD
=
$(libvacorelib)
glx/libva_glx.la libva-x11.la
$(GL_DEPS_LIBS)
-ldl
libva_glx_la_LDFLAGS
=
$(LDADD)
libva_glx_la_DEPENDENCIES
=
$(libvacorelib)
glx/libva_glx.la libva-x11.la
else
libva_glx_backend
=
libva_glx_backenddir
=
endif
libva_x11_la_SOURCES
=
libva_x11_la_LIBADD
=
$(libvacorelib)
x11/libva_x11.la
$(LIBVA_LIBS)
$(X11_LIBS)
$(XEXT_LIBS)
$(DRM_LIBS)
$(XFIXES_LIBS)
libva_x11_la_LDFLAGS
=
$(LDADD)
libva_x11_la_DEPENDENCIES
=
$(libvacorelib)
x11/libva_x11.la
libva_la_SOURCES
=
va.c va_trace.c
libva_tpi_la_SOURCES
=
va_tpi.c
lib_LTLIBRARIES
=
libva.la libva-tpi.la
$(libva_x11_backend)
$(libva_dummy_backend)
$(libva_glx_backend)
SUBDIRS
=
$(libva_x11_backenddir)
$(libva_dummy_backenddir)
$(libva_glx_backenddir)
libvaincludedir
=
${includedir}
/va
libvainclude_HEADERS
=
va.h va_tpi.h va_x11.h va_backend.h va_backend_tpi.h va_dummy.h va_version.h
...
...
va/glx/va_glx_impl.c
View file @
7376e698
...
...
@@ -199,7 +199,7 @@ static int check_tfp_extensions(VADriverContextP ctx)
if
(
!
check_extension
(
"GL_ARB_texture_non_power_of_two"
,
gl_extensions
))
return
0
;
glx_extensions
=
glXQueryExtensionsString
(
ctx
->
x11
_dpy
,
ctx
->
x11_screen
);
glx_extensions
=
glXQueryExtensionsString
(
(
Display
*
)
ctx
->
native
_dpy
,
ctx
->
x11_screen
);
if
(
!
check_extension
(
"GLX_EXT_texture_from_pixmap"
,
glx_extensions
))
return
0
;
return
1
;
...
...
@@ -332,7 +332,7 @@ gl_create_context(VADriverContextP ctx, OpenGLContextStateP parent)
if
(
!
cs
)
goto
error
;
cs
->
display
=
ctx
->
x11
_dpy
;
cs
->
display
=
(
Display
*
)
ctx
->
native
_dpy
;
cs
->
window
=
parent
?
parent
->
window
:
None
;
cs
->
context
=
NULL
;
...
...
@@ -349,7 +349,7 @@ gl_create_context(VADriverContextP ctx, OpenGLContextStateP parent)
goto
choose_fbconfig
;
fbconfigs
=
glXGetFBConfigs
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
ctx
->
x11_screen
,
&
n_fbconfigs
);
...
...
@@ -359,7 +359,7 @@ gl_create_context(VADriverContextP ctx, OpenGLContextStateP parent)
/* Find out a GLXFBConfig compatible with the parent context */
for
(
n
=
0
;
n
<
n_fbconfigs
;
n
++
)
{
status
=
glXGetFBConfigAttrib
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
fbconfigs
[
n
],
GLX_FBCONFIG_ID
,
&
val
);
...
...
@@ -372,7 +372,7 @@ gl_create_context(VADriverContextP ctx, OpenGLContextStateP parent)
else
{
choose_fbconfig:
fbconfigs
=
glXChooseFBConfig
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
ctx
->
x11_screen
,
fbconfig_attrs
,
&
n_fbconfigs
);
...
...
@@ -384,7 +384,7 @@ gl_create_context(VADriverContextP ctx, OpenGLContextStateP parent)
}
cs
->
context
=
glXCreateNewContext
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
fbconfigs
[
n
],
GLX_RGBA_TYPE
,
parent
?
parent
->
context
:
NULL
,
...
...
@@ -461,12 +461,12 @@ static int create_tfp_surface(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
int
*
attrib
;
int
n_fbconfig_attrs
;
root_window
=
RootWindow
(
ctx
->
x11
_dpy
,
ctx
->
x11_screen
);
XGetWindowAttributes
(
ctx
->
x11
_dpy
,
root_window
,
&
wattr
);
root_window
=
RootWindow
(
(
Display
*
)
ctx
->
native
_dpy
,
ctx
->
x11_screen
);
XGetWindowAttributes
(
(
Display
*
)
ctx
->
native
_dpy
,
root_window
,
&
wattr
);
if
(
wattr
.
depth
!=
24
&&
wattr
.
depth
!=
32
)
return
0
;
pixmap
=
XCreatePixmap
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
root_window
,
width
,
height
,
...
...
@@ -500,7 +500,7 @@ static int create_tfp_surface(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
*
attrib
++
=
GL_NONE
;
fbconfig
=
glXChooseFBConfig
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
ctx
->
x11_screen
,
fbconfig_attrs
,
&
n_fbconfig_attrs
...
...
@@ -524,7 +524,7 @@ static int create_tfp_surface(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
x11_trap_errors
();
glx_pixmap
=
glXCreatePixmap
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
fbconfig
[
0
],
pixmap
,
pixmap_attrs
...
...
@@ -550,12 +550,12 @@ static void destroy_tfp_surface(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
}
if
(
pSurfaceGLX
->
glx_pixmap
)
{
glXDestroyPixmap
(
ctx
->
x11
_dpy
,
pSurfaceGLX
->
glx_pixmap
);
glXDestroyPixmap
(
(
Display
*
)
ctx
->
native
_dpy
,
pSurfaceGLX
->
glx_pixmap
);
pSurfaceGLX
->
glx_pixmap
=
None
;
}
if
(
pSurfaceGLX
->
pixmap
)
{
XFreePixmap
(
ctx
->
x11
_dpy
,
pSurfaceGLX
->
pixmap
);
XFreePixmap
(
(
Display
*
)
ctx
->
native
_dpy
,
pSurfaceGLX
->
pixmap
);
pSurfaceGLX
->
pixmap
=
None
;
}
}
...
...
@@ -572,12 +572,12 @@ static int bind_pixmap(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
x11_trap_errors
();
pOpenGLVTable
->
glx_bind_tex_image
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
pSurfaceGLX
->
glx_pixmap
,
GLX_FRONT_LEFT_EXT
,
NULL
);
XSync
(
ctx
->
x11
_dpy
,
False
);
XSync
(
(
Display
*
)
ctx
->
native
_dpy
,
False
);
if
(
x11_untrap_errors
()
!=
0
)
{
va_glx_error_message
(
"failed to bind pixmap
\n
"
);
return
0
;
...
...
@@ -597,11 +597,11 @@ static int unbind_pixmap(VADriverContextP ctx, VASurfaceGLXP pSurfaceGLX)
x11_trap_errors
();
pOpenGLVTable
->
glx_release_tex_image
(
ctx
->
x11
_dpy
,
(
Display
*
)
ctx
->
native
_dpy
,
pSurfaceGLX
->
glx_pixmap
,
GLX_FRONT_LEFT_EXT
);
XSync
(
ctx
->
x11
_dpy
,
False
);
XSync
(
(
Display
*
)
ctx
->
native
_dpy
,
False
);
if
(
x11_untrap_errors
()
!=
0
)
{
va_glx_error_message
(
"failed to release pixmap
\n
"
);
return
0
;
...
...
@@ -929,13 +929,13 @@ associate_surface(
status
=
ctx
->
vtable
.
vaPutSurface
(
ctx
,
surface
,
pSurfaceGLX
->
pixmap
,
(
void
*
)
pSurfaceGLX
->
pixmap
,
0
,
0
,
pSurfaceGLX
->
width
,
pSurfaceGLX
->
height
,
0
,
0
,
pSurfaceGLX
->
width
,
pSurfaceGLX
->
height
,
NULL
,
0
,
flags
);
XSync
(
ctx
->
x11
_dpy
,
False
);
XSync
(
(
Display
*
)
ctx
->
native
_dpy
,
False
);
if
(
x11_untrap_errors
()
!=
0
)
return
VA_STATUS_ERROR_OPERATION_FAILED
;
if
(
status
!=
VA_STATUS_SUCCESS
)
...
...
@@ -1057,7 +1057,7 @@ VAStatus va_glx_init_context(VADriverContextP ctx)
vtable
->
vaDestroySurfaceGLX
=
vaDestroySurfaceGLX_impl_libva
;
vtable
->
vaCopySurfaceGLX
=
vaCopySurfaceGLX_impl_libva
;
if
(
!
glXQueryVersion
(
ctx
->
x11
_dpy
,
&
glx_major
,
&
glx_minor
))
if
(
!
glXQueryVersion
(
(
Display
*
)
ctx
->
native
_dpy
,
&
glx_major
,
&
glx_minor
))
return
VA_STATUS_ERROR_UNIMPLEMENTED
;
if
(
glx_major
<
1
||
(
glx_major
==
1
&&
glx_minor
<
3
))
{
/* GLX 1.3 */
va_glx_error_message
(
"GLX version 1.3 expected but only "
...
...
va/glx/va_glx_impl.h
View file @
7376e698
...
...
@@ -31,7 +31,7 @@
* @param[in] ctx the VA driver context
* @return VA_STATUS_SUCCESS if successful
*/
VAStatus
va_glx_init_context
(
VADriverContextP
ctx
)
ATTRIBUTE_HIDDEN
;
VAStatus
va_glx_init_context
(
VADriverContextP
ctx
)
;
/* ATTRIBUTE_HIDDEN; */
#endif
/* VA_GLX_IMPL_H */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment