mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-28 20:30:25 +01:00
python: Pretty-printing of blend state.
This commit is contained in:
parent
165b824343
commit
c2b0484e58
2 changed files with 19 additions and 1 deletions
|
|
@ -41,13 +41,15 @@
|
|||
#include "pipe/p_screen.h"
|
||||
#include "pipe/p_context.h"
|
||||
#include "pipe/p_shader_tokens.h"
|
||||
#include "cso_cache/cso_context.h"
|
||||
#include "os/os_stream.h"
|
||||
#include "util/u_inlines.h"
|
||||
#include "util/u_draw_quad.h"
|
||||
#include "util/u_tile.h"
|
||||
#include "util/u_math.h"
|
||||
#include "util/u_format.h"
|
||||
#include "util/u_dump.h"
|
||||
#include "util/u_memory.h"
|
||||
#include "cso_cache/cso_context.h"
|
||||
#include "tgsi/tgsi_text.h"
|
||||
#include "tgsi/tgsi_dump.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -58,6 +58,22 @@
|
|||
};
|
||||
|
||||
|
||||
%extend pipe_blend_state
|
||||
{
|
||||
%cstring_output_allocate_size(char **STRING, int *LENGTH, os_free(*$1));
|
||||
void __str__(char **STRING, int *LENGTH)
|
||||
{
|
||||
struct os_stream *stream;
|
||||
|
||||
stream = os_str_stream_create(1);
|
||||
util_dump_blend_state(stream, $self);
|
||||
|
||||
*STRING = os_str_stream_get_and_close(stream);
|
||||
*LENGTH = strlen(*STRING);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
%extend pipe_framebuffer_state {
|
||||
|
||||
pipe_framebuffer_state(void) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue