(API Change) Remove pointers from all typedefs
Typedef pointers are unsafe. If you do: typedef struct bla *bla_t; then you cannot use it as a constant, such as: const bla_t, because that constant will be to the pointer itself rather than to the underlying data. I admit this was a fundamental mistake that must be corrected. All typedefs that were pointer types will now have their pointers removed from the type itself, and the pointers will be used when they are actually used as variables/parameters/returns instead. This does not break ABI though, which is pretty nice.
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
|
||||
struct dc_capture {
|
||||
int cur_tex;
|
||||
gs_texture_t textures[NUM_TEXTURES];
|
||||
gs_texture_t *textures[NUM_TEXTURES];
|
||||
bool textures_written[NUM_TEXTURES];
|
||||
int x, y;
|
||||
uint32_t width;
|
||||
@@ -34,6 +34,6 @@ extern void dc_capture_init(struct dc_capture *capture, int x, int y,
|
||||
extern void dc_capture_free(struct dc_capture *capture);
|
||||
|
||||
extern void dc_capture_capture(struct dc_capture *capture, HWND window);
|
||||
extern void dc_capture_render(struct dc_capture *capture, gs_effect_t effect);
|
||||
extern void dc_capture_render(struct dc_capture *capture, gs_effect_t *effect);
|
||||
|
||||
extern gs_effect_t create_opaque_effect(void);
|
||||
extern gs_effect_t *create_opaque_effect(void);
|
||||
|
Reference in New Issue
Block a user