st/egl: fix a crash in Android backend
[mesa.git] / src / gallium / state_trackers / vdpau / bitmap.c
index b570f2752e4c47370652082dbbdf110d85d1eb53..8c7dbe529e854ee2670e2c8ae05832d809c3cb9a 100644 (file)
  **************************************************************************/
 
 #include <vdpau/vdpau.h>
+
 #include "vdpau_private.h"
-#include <util/u_debug.h>
 
+/**
+ * Create a VdpBitmapSurface.
+ */
 VdpStatus
 vlVdpBitmapSurfaceCreate(VdpDevice device,
                          VdpRGBAFormat rgba_format,
@@ -36,19 +39,25 @@ vlVdpBitmapSurfaceCreate(VdpDevice device,
                          VdpBool frequently_accessed,
                          VdpBitmapSurface *surface)
 {
-   debug_printf("[VDPAU] Creating a bitmap surface\n");
+   VDPAU_MSG(VDPAU_TRACE, "[VDPAU] Creating a bitmap surface\n");
    if (!surface)
       return VDP_STATUS_INVALID_POINTER;
 
    return VDP_STATUS_NO_IMPLEMENTATION;
 }
 
+/**
+ * Destroy a VdpBitmapSurface.
+ */
 VdpStatus
 vlVdpBitmapSurfaceDestroy(VdpBitmapSurface surface)
 {
    return VDP_STATUS_NO_IMPLEMENTATION;
 }
 
+/**
+ * Retrieve the parameters used to create a VdpBitmapSurface.
+ */
 VdpStatus
 vlVdpBitmapSurfaceGetParameters(VdpBitmapSurface surface,
                                 VdpRGBAFormat *rgba_format,
@@ -61,14 +70,18 @@ vlVdpBitmapSurfaceGetParameters(VdpBitmapSurface surface,
    return VDP_STATUS_NO_IMPLEMENTATION;
 }
 
+/**
+ * Copy image data from application memory in the surface's native format to
+ * a VdpBitmapSurface.
+ */
 VdpStatus
 vlVdpBitmapSurfacePutBitsNative(VdpBitmapSurface surface,
                                 void const *const *source_data,
                                 uint32_t const *source_pitches,
-                                VdpRect const *destination_rect )
+                                VdpRect const *destination_rect)
 {
    if (!(source_data && source_pitches && destination_rect))
-       return VDP_STATUS_INVALID_POINTER;
+      return VDP_STATUS_INVALID_POINTER;
 
    return VDP_STATUS_NO_IMPLEMENTATION;
 }