summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2017-02-01 16:48:31 -0700
committerBrian Paul <[email protected]>2017-02-03 11:48:25 -0700
commit2fac98f86555bce9d229bc7c6ead5b9b084835bd (patch)
tree69110162cc2d6940b8d2c1e09e1a270483e3fe8c /src
parent84dbf683781241038d847b9db81f153ab59e27f6 (diff)
mesa: whitespace fixes in context.c
Remove trailing whitespace, replace tabs with spaces. Trivial.
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/context.c62
1 files changed, 31 insertions, 31 deletions
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 76763489b9f..16e25a9bc25 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -161,7 +161,7 @@ GLfloat _mesa_ubyte_to_float_color_tab[256];
/**
* Swap buffers notification callback.
- *
+ *
* \param ctx GL context.
*
* Called by window system just before swapping buffers.
@@ -187,7 +187,7 @@ _mesa_notifySwapBuffers(struct gl_context *ctx)
/**
* Allocates a struct gl_config structure and initializes it via
* _mesa_initialize_visual().
- *
+ *
* \param dbFlag double buffering
* \param stereoFlag stereo buffer
* \param depthBits requested bits per depth buffer value. Any value in [0, 32]
@@ -203,7 +203,7 @@ _mesa_notifySwapBuffers(struct gl_context *ctx)
* \param blueBits same as above.
* \param alphaBits same as above.
* \param numSamples not really used.
- *
+ *
* \return pointer to new struct gl_config or NULL if requested parameters
* can't be met.
*
@@ -315,7 +315,7 @@ _mesa_initialize_visual( struct gl_config *vis,
* Destroy a visual and free its memory.
*
* \param vis visual.
- *
+ *
* Frees the visual structure.
*/
void
@@ -397,8 +397,8 @@ one_time_init( struct gl_context *ctx )
#if defined(DEBUG) && defined(__DATE__) && defined(__TIME__)
if (MESA_VERBOSE != 0) {
- _mesa_debug(ctx, "Mesa %s DEBUG build %s %s\n",
- PACKAGE_VERSION, __DATE__, __TIME__);
+ _mesa_debug(ctx, "Mesa %s DEBUG build %s %s\n",
+ PACKAGE_VERSION, __DATE__, __TIME__);
}
#endif
}
@@ -745,9 +745,9 @@ check_context_limits(struct gl_context *ctx)
/* check that we don't exceed the size of various bitfields */
assert(VARYING_SLOT_MAX <=
- (8 * sizeof(ctx->VertexProgram._Current->info.outputs_written)));
+ (8 * sizeof(ctx->VertexProgram._Current->info.outputs_written)));
assert(VARYING_SLOT_MAX <=
- (8 * sizeof(ctx->FragmentProgram._Current->info.inputs_read)));
+ (8 * sizeof(ctx->FragmentProgram._Current->info.inputs_read)));
/* shader-related checks */
assert(ctx->Const.Program[MESA_SHADER_FRAGMENT].MaxLocalParams <= MAX_PROGRAM_LOCAL_PARAMS);
@@ -1130,7 +1130,7 @@ _mesa_initialize_dispatch_tables(struct gl_context *ctx)
* Note that the driver needs to pass in its dd_function_table here since
* we need to at least call driverFunctions->NewTextureObject to create the
* default texture objects.
- *
+ *
* Called by _mesa_create_context().
*
* Performs the imports and exports callback tables initialization, and
@@ -1228,7 +1228,7 @@ _mesa_initialize_context(struct gl_context *ctx,
* _mesa_choose_tex_format().
*/
memset(&ctx->TextureFormatSupported, GL_TRUE,
- sizeof(ctx->TextureFormatSupported));
+ sizeof(ctx->TextureFormatSupported));
ctx->Cache = disk_cache_create();
@@ -1248,13 +1248,13 @@ _mesa_initialize_context(struct gl_context *ctx,
* "Initially all texture generation modes are set to REFLECTION_MAP_OES"
*/
for (i = 0; i < MAX_TEXTURE_UNITS; i++) {
- struct gl_texture_unit *texUnit = &ctx->Texture.Unit[i];
- texUnit->GenS.Mode = GL_REFLECTION_MAP_NV;
- texUnit->GenT.Mode = GL_REFLECTION_MAP_NV;
- texUnit->GenR.Mode = GL_REFLECTION_MAP_NV;
- texUnit->GenS._ModeBit = TEXGEN_REFLECTION_MAP_NV;
- texUnit->GenT._ModeBit = TEXGEN_REFLECTION_MAP_NV;
- texUnit->GenR._ModeBit = TEXGEN_REFLECTION_MAP_NV;
+ struct gl_texture_unit *texUnit = &ctx->Texture.Unit[i];
+ texUnit->GenS.Mode = GL_REFLECTION_MAP_NV;
+ texUnit->GenT.Mode = GL_REFLECTION_MAP_NV;
+ texUnit->GenR.Mode = GL_REFLECTION_MAP_NV;
+ texUnit->GenS._ModeBit = TEXGEN_REFLECTION_MAP_NV;
+ texUnit->GenT._ModeBit = TEXGEN_REFLECTION_MAP_NV;
+ texUnit->GenR._ModeBit = TEXGEN_REFLECTION_MAP_NV;
}
break;
case API_OPENGLES2:
@@ -1279,7 +1279,7 @@ fail:
/**
* Free the data associated with the given context.
- *
+ *
* But doesn't free the struct gl_context struct itself.
*
* \sa _mesa_initialize_context() and init_attrib_groups().
@@ -1365,7 +1365,7 @@ _mesa_free_context_data( struct gl_context *ctx )
* Destroy a struct gl_context structure.
*
* \param ctx GL context.
- *
+ *
* Calls _mesa_free_context_data() and frees the gl_context object itself.
*/
void
@@ -1380,7 +1380,7 @@ _mesa_destroy_context( struct gl_context *ctx )
/**
* Copy attribute groups from one context to another.
- *
+ *
* \param src source context
* \param dst destination context
* \param mask bitwise OR of GL_*_BIT flags
@@ -1495,7 +1495,7 @@ _mesa_copy_context( const struct gl_context *src, struct gl_context *dst,
*
* \return GL_TRUE if compatible, GL_FALSE otherwise.
*/
-static GLboolean
+static GLboolean
check_compatible(const struct gl_context *ctx,
const struct gl_framebuffer *buffer)
{
@@ -1547,6 +1547,7 @@ _mesa_check_init_viewport(struct gl_context *ctx, GLuint width, GLuint height)
}
}
+
static void
handle_first_current(struct gl_context *ctx)
{
@@ -1561,7 +1562,8 @@ handle_first_current(struct gl_context *ctx)
/* According to GL_MESA_configless_context the default value of
* glDrawBuffers depends on the config of the first surface it is bound to.
- * For GLES it is always GL_BACK which has a magic interpretation */
+ * For GLES it is always GL_BACK which has a magic interpretation.
+ */
if (!ctx->HasConfig && _mesa_is_desktop_gl(ctx)) {
if (ctx->DrawBuffer != _mesa_get_incomplete_framebuffer()) {
GLenum buffer;
@@ -1643,7 +1645,7 @@ _mesa_make_current( struct gl_context *newCtx,
}
}
- if (curCtx &&
+ if (curCtx &&
(curCtx->WinSysDrawBuffer || curCtx->WinSysReadBuffer) &&
/* make sure this context is valid for flushing */
curCtx != newCtx &&
@@ -1700,7 +1702,7 @@ _mesa_make_current( struct gl_context *newCtx,
/* XXX only set this flag if we're really changing the draw/read
* framebuffer bindings.
*/
- newCtx->NewState |= _NEW_BUFFERS;
+ newCtx->NewState |= _NEW_BUFFERS;
_mesa_check_init_viewport(newCtx,
drawBuffer->Width, drawBuffer->Height);
@@ -1708,10 +1710,10 @@ _mesa_make_current( struct gl_context *newCtx,
if (newCtx->FirstTimeCurrent) {
handle_first_current(newCtx);
- newCtx->FirstTimeCurrent = GL_FALSE;
+ newCtx->FirstTimeCurrent = GL_FALSE;
}
}
-
+
return GL_TRUE;
}
@@ -1750,7 +1752,7 @@ _mesa_share_state(struct gl_context *ctx, struct gl_context *ctxToShare)
/**
* \return pointer to the current GL context for this thread.
- *
+ *
* Calls _glapi_get_context(). This isn't the fastest way to get the current
* context. If you need speed, see the #GET_CURRENT_CONTEXT macro in
* context.h.
@@ -1767,7 +1769,7 @@ _mesa_get_current_context( void )
*
* It'll either be the immediate-mode execute dispatcher or the display list
* compile dispatcher.
- *
+ *
* \param ctx GL context.
*
* \return pointer to dispatch_table.
@@ -1793,7 +1795,7 @@ _mesa_get_dispatch(struct gl_context *ctx)
*
* \param ctx GL context.
* \param error error code.
- *
+ *
* Records the given error code and call the driver's dd_function_table::Error
* function if defined.
*
@@ -1871,6 +1873,4 @@ _mesa_Flush(void)
}
-
-
/*@}*/