1
0
Fork 0

cogl: Remove various DepthState functions

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3804>
This commit is contained in:
Bilal Elmoussaoui 2024-06-12 00:58:51 +02:00 committed by Bilal Elmoussaoui
parent bb29fa68fe
commit 014ea91a9d
2 changed files with 1 additions and 82 deletions

View file

@ -56,13 +56,6 @@ cogl_depth_state_set_test_enabled (CoglDepthState *state,
state->test_enabled = enabled;
}
gboolean
cogl_depth_state_get_test_enabled (CoglDepthState *state)
{
g_return_val_if_fail (state->magic == COGL_DEPTH_STATE_MAGIC, FALSE);
return state->test_enabled;
}
void
cogl_depth_state_set_write_enabled (CoglDepthState *state,
gboolean enabled)
@ -71,13 +64,6 @@ cogl_depth_state_set_write_enabled (CoglDepthState *state,
state->write_enabled = enabled;
}
gboolean
cogl_depth_state_get_write_enabled (CoglDepthState *state)
{
g_return_val_if_fail (state->magic == COGL_DEPTH_STATE_MAGIC, FALSE);
return state->write_enabled;
}
void
cogl_depth_state_set_test_function (CoglDepthState *state,
CoglDepthTestFunction function)
@ -86,13 +72,6 @@ cogl_depth_state_set_test_function (CoglDepthState *state,
state->test_function = function;
}
CoglDepthTestFunction
cogl_depth_state_get_test_function (CoglDepthState *state)
{
g_return_val_if_fail (state->magic == COGL_DEPTH_STATE_MAGIC, FALSE);
return state->test_function;
}
void
cogl_depth_state_set_range (CoglDepthState *state,
float near,
@ -102,13 +81,3 @@ cogl_depth_state_set_range (CoglDepthState *state,
state->range_near = near;
state->range_far = far;
}
void
cogl_depth_state_get_range (CoglDepthState *state,
float *near_out,
float *far_out)
{
g_return_if_fail (state->magic == COGL_DEPTH_STATE_MAGIC);
*near_out = state->range_near;
*far_out = state->range_far;
}

View file

@ -40,7 +40,7 @@ G_BEGIN_DECLS
/**
* CoglDepthState:
*
*
* Functions for describing the depth testing state of your GPU.
*/
typedef struct {
@ -92,18 +92,6 @@ COGL_EXPORT void
cogl_depth_state_set_test_enabled (CoglDepthState *state,
gboolean enable);
/**
* cogl_depth_state_get_test_enabled:
* @state: A #CoglDepthState struct
*
* Gets the current depth test enabled state as previously set by
* cogl_depth_state_set_test_enabled().
*
* Returns: The pipeline's current depth test enabled state.
*/
COGL_EXPORT gboolean
cogl_depth_state_get_test_enabled (CoglDepthState *state);
/**
* cogl_depth_state_set_write_enabled:
* @state: A #CoglDepthState struct
@ -125,17 +113,6 @@ COGL_EXPORT void
cogl_depth_state_set_write_enabled (CoglDepthState *state,
gboolean enable);
/**
* cogl_depth_state_get_write_enabled:
* @state: A #CoglDepthState struct
*
* Gets the depth writing enable state as set by the corresponding
* cogl_depth_state_set_write_enabled().
*
* Returns: The current depth writing enable state
*/
COGL_EXPORT gboolean
cogl_depth_state_get_write_enabled (CoglDepthState *state);
/**
* cogl_depth_state_set_test_function:
@ -156,18 +133,6 @@ COGL_EXPORT void
cogl_depth_state_set_test_function (CoglDepthState *state,
CoglDepthTestFunction function);
/**
* cogl_depth_state_get_test_function:
* @state: A #CoglDepthState struct
*
* Gets the current depth test enable state as previously set via
* cogl_depth_state_set_test_enabled().
*
* Returns: The current depth test enable state.
*/
COGL_EXPORT CoglDepthTestFunction
cogl_depth_state_get_test_function (CoglDepthState *state);
/**
* cogl_depth_state_set_range:
* @state: A #CoglDepthState object
@ -201,19 +166,4 @@ cogl_depth_state_set_range (CoglDepthState *state,
float near_val,
float far_val);
/**
* cogl_depth_state_get_range:
* @state: A #CoglDepthState object
* @near_val: A pointer to store the near component of the depth range
* @far_val: A pointer to store the far component of the depth range
*
* Gets the current range to which normalized depth values are mapped
* before writing to the depth buffer. This corresponds to the range
* set with cogl_depth_state_set_range().
*/
COGL_EXPORT void
cogl_depth_state_get_range (CoglDepthState *state,
float *near_val,
float *far_val);
G_END_DECLS