RetroArch
Classes | Macros | Typedefs | Functions | Variables
ps2_gfx.c File Reference
#include "../video_driver.h"
#include "../../driver.h"
#include "../../verbosity.h"
#include <kernel.h>
#include <gsKit.h>
#include <gsInline.h>
Include dependency graph for ps2_gfx.c:

Classes

struct  ps2_video
 

Macros

#define GS_TEXT   GS_SETREG_RGBAQ(0x80,0x80,0x80,0x80,0x00)
 
#define GS_BLACK   GS_SETREG_RGBAQ(0x00,0x00,0x00,0x00,0x00)
 
#define NTSC_WIDTH   640
 
#define NTSC_HEIGHT   448
 

Typedefs

typedef struct ps2_video ps2_video_t
 

Functions

static GSGLOBAL * init_GSGlobal (void)
 
static GSTEXTURE * prepare_new_texture (void)
 
static void init_ps2_video (ps2_video_t *ps2)
 
static void deinitTexture (GSTEXTURE *texture)
 
static void color_correction32 (uint32_t *buffer, uint32_t dimensions)
 
static void color_correction16 (uint16_t *buffer, uint32_t dimensions)
 
static void transfer_texture (GSTEXTURE *texture, const void *frame, int width, int height, bool rgb32, int filter, bool color_correction)
 
static void vram_alloc (GSGLOBAL *gsGlobal, GSTEXTURE *texture)
 
static void prim_texture (GSGLOBAL *gsGlobal, GSTEXTURE *texture, int zPosition, bool force_aspect)
 
static voidps2_gfx_init (const video_info_t *video, const input_driver_t **input, void **input_data)
 
static bool ps2_gfx_frame (void *data, const void *frame, unsigned width, unsigned height, uint64_t frame_count, unsigned pitch, const char *msg, video_frame_info_t *video_info)
 
static void ps2_gfx_set_nonblock_state (void *data, bool toggle)
 
static bool ps2_gfx_alive (void *data)
 
static bool ps2_gfx_focus (void *data)
 
static bool ps2_gfx_suppress_screensaver (void *data, bool enable)
 
static bool ps2_gfx_has_windowed (void *data)
 
static void ps2_gfx_free (void *data)
 
static bool ps2_gfx_set_shader (void *data, enum rarch_shader_type type, const char *path)
 
static void ps2_gfx_set_rotation (void *data, unsigned rotation)
 
static void ps2_gfx_viewport_info (void *data, struct video_viewport *vp)
 
static bool ps2_gfx_read_viewport (void *data, uint8_t *buffer, bool is_idle)
 
static void ps2_set_filtering (void *data, unsigned index, bool smooth)
 
static void ps2_set_aspect_ratio (void *data, unsigned aspect_ratio_idx)
 
static void ps2_apply_state_changes (void *data)
 
static void ps2_set_texture_frame (void *data, const void *frame, bool rgb32, unsigned width, unsigned height, float alpha)
 
static void ps2_set_texture_enable (void *data, bool enable, bool fullscreen)
 
static void ps2_gfx_get_poke_interface (void *data, const video_poke_interface_t **iface)
 

Variables

static const video_poke_interface_t ps2_poke_interface
 
video_driver_t video_ps2
 

Macro Definition Documentation

◆ GS_BLACK

#define GS_BLACK   GS_SETREG_RGBAQ(0x00,0x00,0x00,0x00,0x00)

◆ GS_TEXT

#define GS_TEXT   GS_SETREG_RGBAQ(0x80,0x80,0x80,0x80,0x00)

◆ NTSC_HEIGHT

#define NTSC_HEIGHT   448

◆ NTSC_WIDTH

#define NTSC_WIDTH   640

Typedef Documentation

◆ ps2_video_t

typedef struct ps2_video ps2_video_t

Function Documentation

◆ color_correction16()

static void color_correction16 ( uint16_t buffer,
uint32_t  dimensions 
)
static
Here is the caller graph for this function:

◆ color_correction32()

static void color_correction32 ( uint32_t buffer,
uint32_t  dimensions 
)
static
Here is the caller graph for this function:

◆ deinitTexture()

static void deinitTexture ( GSTEXTURE *  texture)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_GSGlobal()

static GSGLOBAL* init_GSGlobal ( void  )
static
Here is the caller graph for this function:

◆ init_ps2_video()

static void init_ps2_video ( ps2_video_t ps2)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ prepare_new_texture()

static GSTEXTURE* prepare_new_texture ( void  )
static
Here is the caller graph for this function:

◆ prim_texture()

static void prim_texture ( GSGLOBAL *  gsGlobal,
GSTEXTURE *  texture,
int  zPosition,
bool  force_aspect 
)
static
Here is the caller graph for this function:

◆ ps2_apply_state_changes()

static void ps2_apply_state_changes ( void data)
static

◆ ps2_gfx_alive()

static bool ps2_gfx_alive ( void data)
static
Here is the call graph for this function:

◆ ps2_gfx_focus()

static bool ps2_gfx_focus ( void data)
static
Here is the call graph for this function:

◆ ps2_gfx_frame()

static bool ps2_gfx_frame ( void data,
const void frame,
unsigned  width,
unsigned  height,
uint64_t  frame_count,
unsigned  pitch,
const char *  msg,
video_frame_info_t video_info 
)
static
Here is the call graph for this function:

◆ ps2_gfx_free()

static void ps2_gfx_free ( void data)
static
Here is the call graph for this function:

◆ ps2_gfx_get_poke_interface()

static void ps2_gfx_get_poke_interface ( void data,
const video_poke_interface_t **  iface 
)
static
Here is the call graph for this function:

◆ ps2_gfx_has_windowed()

static bool ps2_gfx_has_windowed ( void data)
static
Here is the call graph for this function:

◆ ps2_gfx_init()

static void* ps2_gfx_init ( const video_info_t video,
const input_driver_t **  input,
void **  input_data 
)
static
Here is the call graph for this function:

◆ ps2_gfx_read_viewport()

static bool ps2_gfx_read_viewport ( void data,
uint8_t buffer,
bool  is_idle 
)
static
Here is the call graph for this function:

◆ ps2_gfx_set_nonblock_state()

static void ps2_gfx_set_nonblock_state ( void data,
bool  toggle 
)
static
Here is the call graph for this function:

◆ ps2_gfx_set_rotation()

static void ps2_gfx_set_rotation ( void data,
unsigned  rotation 
)
static
Here is the call graph for this function:

◆ ps2_gfx_set_shader()

static bool ps2_gfx_set_shader ( void data,
enum rarch_shader_type  type,
const char *  path 
)
static
Here is the call graph for this function:

◆ ps2_gfx_suppress_screensaver()

static bool ps2_gfx_suppress_screensaver ( void data,
bool  enable 
)
static
Here is the call graph for this function:

◆ ps2_gfx_viewport_info()

static void ps2_gfx_viewport_info ( void data,
struct video_viewport vp 
)
static
Here is the call graph for this function:

◆ ps2_set_aspect_ratio()

static void ps2_set_aspect_ratio ( void data,
unsigned  aspect_ratio_idx 
)
static

◆ ps2_set_filtering()

static void ps2_set_filtering ( void data,
unsigned  index,
bool  smooth 
)
static

◆ ps2_set_texture_enable()

static void ps2_set_texture_enable ( void data,
bool  enable,
bool  fullscreen 
)
static

◆ ps2_set_texture_frame()

static void ps2_set_texture_frame ( void data,
const void frame,
bool  rgb32,
unsigned  width,
unsigned  height,
float  alpha 
)
static
Here is the call graph for this function:

◆ transfer_texture()

static void transfer_texture ( GSTEXTURE *  texture,
const void frame,
int  width,
int  height,
bool  rgb32,
int  filter,
bool  color_correction 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ vram_alloc()

static void vram_alloc ( GSGLOBAL *  gsGlobal,
GSTEXTURE *  texture 
)
static
Here is the caller graph for this function:

Variable Documentation

◆ ps2_poke_interface

const video_poke_interface_t ps2_poke_interface
static
Initial value:
= {
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
}
static void ps2_set_aspect_ratio(void *data, unsigned aspect_ratio_idx)
Definition: ps2_gfx.c:342
static void ps2_set_texture_enable(void *data, bool enable, bool fullscreen)
Definition: ps2_gfx.c:360
#define NULL
Pointer to 0.
Definition: gctypes.h:65
static void ps2_apply_state_changes(void *data)
Definition: ps2_gfx.c:347
static void ps2_set_texture_frame(void *data, const void *frame, bool rgb32, unsigned width, unsigned height, float alpha)
Definition: ps2_gfx.c:352
static void ps2_set_filtering(void *data, unsigned index, bool smooth)
Definition: ps2_gfx.c:335

◆ video_ps2

video_driver_t video_ps2
Initial value:
= {
"ps2",
NULL,
NULL,
}
static void ps2_gfx_set_rotation(void *data, unsigned rotation)
Definition: ps2_gfx.c:313
static bool ps2_gfx_read_viewport(void *data, uint8_t *buffer, bool is_idle)
Definition: ps2_gfx.c:327
static void * ps2_gfx_init(const video_info_t *video, const input_driver_t **input, void **input_data)
Definition: ps2_gfx.c:188
static bool ps2_gfx_set_shader(void *data, enum rarch_shader_type type, const char *path)
Definition: ps2_gfx.c:303
static void ps2_gfx_free(void *data)
Definition: ps2_gfx.c:288
static void ps2_gfx_viewport_info(void *data, struct video_viewport *vp)
Definition: ps2_gfx.c:320
static void ps2_gfx_set_nonblock_state(void *data, bool toggle)
Definition: ps2_gfx.c:257
#define NULL
Pointer to 0.
Definition: gctypes.h:65
static bool ps2_gfx_alive(void *data)
Definition: ps2_gfx.c:263
static void ps2_gfx_get_poke_interface(void *data, const video_poke_interface_t **iface)
Definition: ps2_gfx.c:394
static bool ps2_gfx_has_windowed(void *data)
Definition: ps2_gfx.c:282
static bool ps2_gfx_focus(void *data)
Definition: ps2_gfx.c:269
static bool ps2_gfx_suppress_screensaver(void *data, bool enable)
Definition: ps2_gfx.c:275
static bool ps2_gfx_frame(void *data, const void *frame, unsigned width, unsigned height, uint64_t frame_count, unsigned pitch, const char *msg, video_frame_info_t *video_info)
Definition: ps2_gfx.c:217