diff options
author | Luc Verhaegen <libv@skynet.be> | 2009-07-29 09:23:51 +0200 |
---|---|---|
committer | Luc Verhaegen <libv@skynet.be> | 2009-11-04 15:13:00 +0100 |
commit | 4f0284bc6f77bf8b5367cc1cdbeb47e0a2b5e716 (patch) | |
tree | 8e1c5c8fbdbce3e9fdce31e51b4556381a13808c | |
parent | 9c31f6572945cc028c82d4acc724ba2e669e4403 (diff) |
XvMC: Add boilerplate libXvMCunichrome
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile.am | 22 | ||||
-rw-r--r-- | configure.ac | 3 | ||||
-rw-r--r-- | lib/Makefile.am | 1 | ||||
-rw-r--r-- | lib/xvmc/Makefile.am | 8 | ||||
-rw-r--r-- | lib/xvmc/libXvMCunichrome.pc.in | 12 | ||||
-rw-r--r-- | lib/xvmc/xvmc_unichrome.c | 436 |
7 files changed, 462 insertions, 21 deletions
@@ -36,3 +36,4 @@ debian/substvars debian/xf86-video-unichrome.substvars debian/xf86-video-unichrome compile +*.pc diff --git a/Makefile.am b/Makefile.am index fb495ec..3936a8d 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,30 +1,10 @@ -# Copyright 2005 Adam Jackson. -# -# Permission is hereby granted, free of charge, to any person obtaining a -# copy of this software and associated documentation files (the "Software"), -# to deal in the Software without restriction, including without limitation -# on the rights to use, copy, modify, merge, publish, distribute, sub -# license, and/or sell copies of the Software, and to permit persons to whom -# the Software is furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice (including the next -# paragraph) shall be included in all copies or substantial portions of the -# Software. -# -# 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. IN NO EVENT SHALL -# ADAM JACKSON BE LIABLE FOR 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. - AUTOMAKE_OPTIONS = foreign if BUILD_WRAPPER WRAPPER_DIR = wrapper endif -SUBDIRS = src man $(WRAPPER_DIR) +SUBDIRS = src man lib $(WRAPPER_DIR) EXTRA_DIST = git_version.sh BUILT_SOURCES = git_version.h diff --git a/configure.ac b/configure.ac index e098dc5..cdc86bb 100644 --- a/configure.ac +++ b/configure.ac @@ -207,4 +207,7 @@ AC_OUTPUT([ Makefile src/Makefile man/Makefile + lib/Makefile + lib/xvmc/Makefile + lib/xvmc/libXvMCunichrome.pc ]) diff --git a/lib/Makefile.am b/lib/Makefile.am new file mode 100644 index 0000000..49f28d4 --- /dev/null +++ b/lib/Makefile.am @@ -0,0 +1 @@ +SUBDIRS = xvmc diff --git a/lib/xvmc/Makefile.am b/lib/xvmc/Makefile.am new file mode 100644 index 0000000..a2291b0 --- /dev/null +++ b/lib/xvmc/Makefile.am @@ -0,0 +1,8 @@ +lib_LTLIBRARIES = libXvMCunichrome.la + +libXvMCunichrome_la_SOURCES = xvmc_unichrome.c + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = libXvMCunichrome.pc + +EXTRA_DIST = libXvMCunichrome.pc.in diff --git a/lib/xvmc/libXvMCunichrome.pc.in b/lib/xvmc/libXvMCunichrome.pc.in new file mode 100644 index 0000000..7761ab7 --- /dev/null +++ b/lib/xvmc/libXvMCunichrome.pc.in @@ -0,0 +1,12 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: libXvMCunichrome +Description: XvMC client side library for Unichrome. +Version: @PACKAGE_VERSION@ +Requires: xproto videoproto xv xvmc +Requires.private: x11 xext xv xvmc +Cflags: -I${includedir} +Libs: -L${libdir} -lXvMC -lXvMCunichrome diff --git a/lib/xvmc/xvmc_unichrome.c b/lib/xvmc/xvmc_unichrome.c new file mode 100644 index 0000000..6cee12f --- /dev/null +++ b/lib/xvmc/xvmc_unichrome.c @@ -0,0 +1,436 @@ +/* + * Copyright 2009 Luc Verhaegen. + * + * Permission is hereby granted, free of charge, to any person obtaining a + * copy of this software and associated documentation files (the "Software"), + * to deal in the Software without restriction, including without limitation + * the rights to use, copy, modify, merge, publish, distribute, sub license, + * and/or sell copies of the Software, and to permit persons to whom the + * Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * 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. IN NO EVENT SHALL + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR 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 <stdio.h> + +#include <X11/Xlibint.h> +#include <X11/extensions/Xvproto.h> +#include <X11/extensions/XvMCproto.h> +#include <X11/extensions/XvMClib.h> +#include <X11/extensions/Xext.h> +#include <X11/extensions/extutil.h> +#include <X11/extensions/Xv.h> +#include <X11/extensions/vldXvMC.h> + +/* + * + */ +_X_EXPORT Status +XvMCCreateContext(Display *display, XvPortID port, int surface_type_id, + int width, int height, int flags, XvMCContext *context) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCDestroyContext(Display *display, XvMCContext *context) +{ + printf("%s\n", __func__); + + return Success; +} + + +/* + * + */ +_X_EXPORT Status +XvMCCreateSurface(Display *display, XvMCContext *context, XvMCSurface *surface) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCDestroySurface(Display *display, XvMCSurface *surface) +{ + printf("%s\n", __func__); + + return Success; +} + +/* + * + */ +_X_EXPORT Status +XvMCPutSurface(Display *display, XvMCSurface *surface, Drawable draw, + short src_x, short src_y, unsigned short src_w, + unsigned short src_h, short dst_x, short dst_y, + unsigned short dst_w, unsigned short dst_h, int flags) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCHideSurface(Display *display, XvMCSurface *surface) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCCreateSubpicture(Display *display, XvMCContext *context, + XvMCSubpicture *subpicture, unsigned short width, + unsigned short height, int xvimage_id) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCClearSubpicture(Display *display, XvMCSubpicture *subpicture, + short x, short y, unsigned short width, + unsigned short height, unsigned int flags) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCCompositeSubpicture(Display *display, XvMCSubpicture *subpicture, + XvImage *image, short src_x, short src_y, + unsigned short width, unsigned short height, + short dst_x, short dst_y) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCDestroySubpicture(Display *display, XvMCSubpicture *subpicture) +{ + printf("%s\n", __func__); + + return Success; +} + + +/* + * + */ +_X_EXPORT Status +XvMCSetSubpicturePalette(Display *display, XvMCSubpicture *subpicture, + unsigned char *palette) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCBlendSubpicture(Display *display, XvMCSurface *surface, + XvMCSubpicture *subpicture, short sub_x, short sub_y, + unsigned short sub_width, unsigned short sub_h, + short surface_x, short surface_y, + unsigned short surface_width, unsigned short surface_h) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCBlendSubpicture2(Display *display, XvMCSurface *source, XvMCSurface *target, + XvMCSubpicture *subpicture, short sub_x, short sub_y, + unsigned short sub_width, unsigned short sub_h, + short surface_x, short surface_y, + unsigned short surface_width, unsigned short surface_h) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCSyncSurface(Display *display, XvMCSurface *surface) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCFlushSurface(Display *display, XvMCSurface *surface) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCGetSurfaceStatus(Display *display, XvMCSurface *surface, int *stat) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCRenderSurface(Display *display, XvMCContext *context, + unsigned int picture_structure, XvMCSurface *target, + XvMCSurface *past, XvMCSurface *future, unsigned int flags, + unsigned int num_macroblocks, unsigned int first_macroblock, + XvMCMacroBlockArray *macroblock_array, XvMCBlockArray *blocks) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCSyncSubpicture(Display *display, XvMCSubpicture *subpicture) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCFlushSubpicture(Display *display, XvMCSubpicture *subpicture) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCGetSubpictureStatus(Display *display, XvMCSubpicture *subpicture, int *stat) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCCreateBlocks(Display *display, XvMCContext *context, + unsigned int num_blocks, XvMCBlockArray *blocks) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCDestroyBlocks(Display *display, XvMCBlockArray *blocks) +{ + printf("%s\n", __func__); + + return Success; +} + + +/* + * + */ +_X_EXPORT Status +XvMCCreateMacroBlocks(Display *display, XvMCContext *context, + unsigned int num_blocks, XvMCMacroBlockArray *blocks) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCDestroyMacroBlocks(Display *display, XvMCMacroBlockArray *blocks) +{ + printf("%s\n", __func__); + + return Success; +} + +/* + * + */ +_X_EXPORT XvAttribute * +XvMCQueryAttributes(Display *display, XvMCContext *context, int *number) +{ + printf("%s\n", __func__); + + return NULL; +} + + +/* + * + */ +_X_EXPORT Status +XvMCSetAttribute(Display *display, XvMCContext *context, + Atom Attribute, int value) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCGetAttribute(Display *display, XvMCContext *context, + Atom Attribute, int *value) +{ + printf("%s\n", __func__); + + +} + + + +/* + * + */ +_X_EXPORT Status +XvMCBeginSurface(Display *display, XvMCContext *context, XvMCSurface *target, + XvMCSurface *past, XvMCSurface *future, + const XvMCMpegControl *control) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCLoadQMatrix(Display *display, XvMCContext *context, + const XvMCQMatrix *qmatrix) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCPutSlice(Display *display, XvMCContext *context, + char *slice, int size) +{ + printf("%s\n", __func__); + + return BadImplementation; +} + + +/* + * + */ +_X_EXPORT Status +XvMCPutSlice2(Display *display, XvMCContext *context, + char *slice, int size, int slicecode) +{ + printf("%s\n", __func__); + + return BadImplementation; +} |