notaz.gp2x.de
/
pcsx_rearmed.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
libretro: allow unlimited cheat length
[pcsx_rearmed.git]
/
plugins
/
gpulib
/
gpu.h
diff --git
a/plugins/gpulib/gpu.h
b/plugins/gpulib/gpu.h
index
717d2fe
..
1582ee1
100644
(file)
--- a/
plugins/gpulib/gpu.h
+++ b/
plugins/gpulib/gpu.h
@@
-13,6
+13,14
@@
#include <stdint.h>
#include <stdint.h>
+//#define RAW_FB_DISPLAY
+
+#define gpu_log(fmt, ...) \
+ printf("%d:%03d: " fmt, *gpu.state.frame_count, *gpu.state.hcnt, ##__VA_ARGS__)
+
+//#define log_anomaly gpu_log
+#define log_anomaly(...)
+
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
extern "C" {
#endif
@@
-34,6
+42,7
@@
extern "C" {
#define BIT(x) (1 << (x))
#define PSX_GPU_STATUS_DHEIGHT BIT(19)
#define BIT(x) (1 << (x))
#define PSX_GPU_STATUS_DHEIGHT BIT(19)
+#define PSX_GPU_STATUS_PAL BIT(20)
#define PSX_GPU_STATUS_RGB24 BIT(21)
#define PSX_GPU_STATUS_INTERLACE BIT(22)
#define PSX_GPU_STATUS_BLANKING BIT(23)
#define PSX_GPU_STATUS_RGB24 BIT(21)
#define PSX_GPU_STATUS_INTERLACE BIT(22)
#define PSX_GPU_STATUS_BLANKING BIT(23)
@@
-53,6
+62,7
@@
struct psx_gpu {
int x, y, w, h;
int x1, x2;
int y1, y2;
int x, y, w, h;
int x1, x2;
int y1, y2;
+ int src_x, src_y;
} screen;
struct {
int x, y, w, h;
} screen;
struct {
int x, y, w, h;
@@
-67,6
+77,8
@@
struct psx_gpu {
uint32_t blanked:1;
uint32_t enhancement_enable:1;
uint32_t enhancement_active:1;
uint32_t blanked:1;
uint32_t enhancement_enable:1;
uint32_t enhancement_active:1;
+ uint32_t enhancement_was_active:1;
+ uint32_t dims_changed:1;
uint32_t *frame_count;
uint32_t *hcnt; /* hsync count */
struct {
uint32_t *frame_count;
uint32_t *hcnt; /* hsync count */
struct {
@@
-76,6
+88,10
@@
struct psx_gpu {
uint32_t hcnt;
} last_list;
uint32_t last_vram_read_frame;
uint32_t hcnt;
} last_list;
uint32_t last_vram_read_frame;
+ uint32_t w_out_old, h_out_old, status_vo_old;
+ int screen_centering_type; // 0 - auto, 1 - game conrolled, 2 - manual
+ int screen_centering_x;
+ int screen_centering_y;
} state;
struct {
int32_t set:3; /* -1 auto, 0 off, 1-3 fixed */
} state;
struct {
int32_t set:3; /* -1 auto, 0 off, 1-3 fixed */
@@
-87,7
+103,7
@@
struct psx_gpu {
uint32_t last_flip_frame;
uint32_t pending_fill[3];
} frameskip;
uint32_t last_flip_frame;
uint32_t pending_fill[3];
} frameskip;
-
uint16_t
*(*get_enhancement_bufer)
+
void
*(*get_enhancement_bufer)
(int *x, int *y, int *w, int *h, int *vram_h);
void *(*mmap)(unsigned int size);
void (*munmap)(void *ptr, unsigned int size);
(int *x, int *y, int *w, int *h, int *vram_h);
void *(*mmap)(unsigned int size);
void (*munmap)(void *ptr, unsigned int size);
@@
-104,11
+120,12
@@
struct rearmed_cbs;
int renderer_init(void);
void renderer_finish(void);
void renderer_sync_ecmds(uint32_t * ecmds);
int renderer_init(void);
void renderer_finish(void);
void renderer_sync_ecmds(uint32_t * ecmds);
-void renderer_update_caches(int x, int y, int w, int h);
+void renderer_update_caches(int x, int y, int w, int h
, int state_changed
);
void renderer_flush_queues(void);
void renderer_set_interlace(int enable, int is_odd);
void renderer_set_config(const struct rearmed_cbs *config);
void renderer_notify_res_change(void);
void renderer_flush_queues(void);
void renderer_set_interlace(int enable, int is_odd);
void renderer_set_config(const struct rearmed_cbs *config);
void renderer_notify_res_change(void);
+void renderer_notify_scanout_x_change(int x, int w);
int vout_init(void);
int vout_finish(void);
int vout_init(void);
int vout_finish(void);
@@
-130,7
+147,7
@@
uint32_t GPUreadStatus(void);
void GPUwriteStatus(uint32_t data);
long GPUfreeze(uint32_t type, struct GPUFreeze *freeze);
void GPUupdateLace(void);
void GPUwriteStatus(uint32_t data);
long GPUfreeze(uint32_t type, struct GPUFreeze *freeze);
void GPUupdateLace(void);
-long GPUopen(
void **dpy
);
+long GPUopen(
unsigned long *disp, char *cap, char *cfg
);
long GPUclose(void);
void GPUvBlank(int is_vblank, int lcf);
void GPUrearmedCallbacks(const struct rearmed_cbs *cbs_);
long GPUclose(void);
void GPUvBlank(int is_vblank, int lcf);
void GPUrearmedCallbacks(const struct rearmed_cbs *cbs_);