summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/context.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: raise max texture sizes to 16KBrian Paul2010-12-021-0/+1
| | | | | | | | | | | This allows 16K x 16K 2D textures, for example, but we don't want to allow that for 3D textures. The new gl_constants::MaxTextureMBytes field is used to prevent allocating too large of texture image. This allows a 16K x 32 x 32 3D texture, for example, but prevents 16K^3. Drivers can override this limit. The default is currently 1GB. Apps should use the proxy texture mechanism to determine the actual max texture size.
* mesa: replace #defines with new gl_shader_type enumBrian Paul2010-11-231-1/+1
|
* mesa: fix regression from b4bb6680200b5a898583392f4c831c02f41e63f7Xiang, Haihao2010-11-231-0/+7
| | | | | | | Pending commands to the previous context aren't flushed since commit b4bb668 Reported-by: Oleksiy Krivoshey <[email protected]> Signed-off-by: Xiang, Haihao <[email protected]>
* mesa: Don't spam the console in a debug build unless some spam is requested.Eric Anholt2010-11-181-2/+4
| | | | | | It's annoying to use test suites under a Mesa debug build because pretty output is cluttered with stderr's continuous reports that you're still using the debug driver.
* mesa: minor clean-ups in context codeBrian Paul2010-11-161-9/+26
|
* mesa: remove always-false conditional in check_compatible()Brian Paul2010-11-021-3/+0
| | | | The two gl_config pointers can never be equal.
* mesa: Allow contexts of different APIs to coexist.Chia-I Wu2010-11-021-27/+29
| | | | | | | | | | | | | | | | | | This effectively redoes 1741ddb747ca0be284315adb4b6fe67ddf292d03 in a way that allows contexts of different APIs to coexist. First, the changes to the remap table are reverted. The remap table (driDispatchRemapTable) is always initialized in the same way regardless of the context API. es_generator.py is updated to use a local remap table, whose sole purpose is to help initialize its dispatch table. The local remap table and the global one are always different, as they use different glapidispatch.h. But the dispatch tables initialized by both remap tables are always compatible with glapi (libGL.so). Finally, the semantics of one_time_init are changed to per-api one-time initialization.
* Merge branch 'glapi-reorg'Chia-I Wu2010-10-291-2/+1
|\ | | | | | | | | | | | | | | | | Conflicts: src/mapi/glapi/glapi_sparc.S src/mapi/glapi/glapi_x86.S src/mapi/glapi/glapidispatch.h src/mapi/glapi/glapioffsets.h src/mapi/glapi/glprocs.h
| * mesa: Remove unnecessary glapitable.h includes.Chia-I Wu2010-10-271-2/+1
| | | | | | | | | | | | | | | | | | With 07b85457d95bcc70588584e9380c51cd63aa3a2b, glapitable.h is included by core mesa only to know the size of _glapi_table. It is not necessary as the same info is given by _gloffset_COUNT. This change makes _glapi_table opaque to core mesa. All operations on it are supposed to go through one of the SET/GET/CALL macros.
* | mesa: state/queries for GL_MIN/MAX_PROGRAM_TEXEL_OFFSET_EXTBrian Paul2010-10-281-0/+4
| |
* | Track separate programs for each stageIan Romanick2010-10-271-47/+103
|/ | | | | The assumption is that all stages are the same program or that varyings are passed between stages using built-in varyings.
* mesa: do integer FB / shader validation check in _mesa_valid_to_render()Brian Paul2010-10-261-1/+11
|
* mesa: Remove FEATURE_ARB_shading_language_120 macro.Kenneth Graunke2010-10-201-4/+0
| | | | Everything should be able to support 1.20 at this point.
* glsl: Slightly change the semantic of _LinkedShadersIan Romanick2010-10-141-12/+10
| | | | | | | | | | | | | | | Previously _LinkedShaders was a compact array of the linked shaders for each shader stage. Now it is arranged such that each slot, indexed by the MESA_SHADER_* defines, refers to a specific shader stage. As a result, some slots will be NULL. This makes things a little more complex in the linker, but it simplifies things in other places. As a side effect _NumLinkedShaders is removed. NOTE: This may be a candidate for the 7.9 branch. If there are other patches that get backported to 7.9 that use _LinkedShader, this patch should be cherry picked also.
* Drop the "neutral" tnl moduleKristian Høgsberg2010-10-141-5/+0
| | | | | | | Just always check for FLUSH_UPDATE_CURRENT and call Driver.BeginVertices when necessary. By using the unlikely() macros, this ends up as a 10% performance improvement (for isosurf, anyway) over the old, complicated function pointer swapping.
* mesa: Silence unused variable warningIan Romanick2010-10-131-0/+1
|
* Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg2010-10-131-40/+40
|
* Drop GLframebuffer typedef and just use struct gl_framebufferKristian Høgsberg2010-10-131-4/+4
|
* Rename GLvisual and __GLcontextModes to struct gl_configKristian Høgsberg2010-10-131-15/+15
|
* gl: Remove unused GLcontextModes fieldsKristian Høgsberg2010-10-131-1/+0
|
* Get rid of GL/internal/glcore.hKristian Høgsberg2010-10-131-1/+1
| | | | | | | __GLcontextModes is always only used as an implementation internal struct at this point and we shouldn't install glcore.h anymore. Anything that needs __GLcontextModes should just include the struct in its headers files directly.
* mesa: Validate assembly shaders when GLSL shaders are usedIan Romanick2010-10-121-12/+40
| | | | | | | | | | If an GLSL shader is used that does not provide all stages and assembly shaders are provided for the missing stages, validate the assembly shaders. Fixes bugzilla #30787 and piglit tests glsl-invalid-asm0[12]. NOTE: this is a candidate for the 7.9 branch.
* mesa: Remove unnecessary headers.Vinson Lee2010-09-241-1/+0
|
* mesa: Remove EXT_convolution.Eric Anholt2010-09-231-2/+0
| | | | More optional code.
* mesa: Remove SGI_color_matrix.Eric Anholt2010-09-231-2/+0
| | | | Another optional ARB_imaging subset extension.
* mesa: Remove SGI_color_table.Eric Anholt2010-09-231-2/+0
| | | | Another optional ARB_imaging subset extension.
* mesa: Remove EXT_histogram.Eric Anholt2010-09-231-2/+0
| | | | This has always been optional, and not useful.
* mesa: don't advertise bogus GL_ARB_shading_language_120 extensionBrian Paul2010-09-211-0/+15
| | | | | | | | | | | Instead of using the invalid GL_ARB_shading_language_120 extension to determine the GLSL version, use a new ctx->Const.GLSLVersion field. Updated the intel and r600 drivers, but untested. See fd.o bug 29910 NOTE: This is a candidate for the 7.9 branch (but let's wait and see if there's any regressions).
* mesa: Less FEATURE_ARB_sync tests.Chia-I Wu2010-09-141-6/+0
| | | | | Add dummy static inline definitions to syncobj.h when FEATURE_ARB_sync is 0, and remove most FEATURE_ARB_sync tests.
* Revert "glapi: Implement optional dispatch logging"Kristian Høgsberg2010-09-091-33/+2
| | | | | | This reverts commit b9abc6139a310677a37754ea7172d976dbf56979 and the follow on fixes (7aae704 and 6fe1b47). It's changing the glapi/driver ABI and causes a number of problems for debug/non-debug builds.
* mesa: Only reference logging symbols in debug buildsKristian Høgsberg2010-09-091-0/+11
|
* mesa: Don't reuse DummyFramebuffer as the incomplete framebufferKristian Høgsberg2010-09-091-0/+3
| | | | | | Binding framebuffer 0 on a context that doesn't have a winsys drawable will try to bind the incomplete framebuffer. That fails when that's also the dummy framebuffer.
* glapi: Implement optional dispatch loggingKristian Høgsberg2010-09-091-2/+22
| | | | | | | There's a useful feature buried in glapi to log all API calls to stderr. Unfortunately it requires editing the code and then it's enabled unconditionally for that build. This patch builds in API logging for debug builds and makes it run-time switchable by setting MESA_DEBUG=dispatch.
* mesa: Fix many printf-like warnings.Eric Anholt2010-09-011-1/+1
| | | | | | | | Most of these are just typecasting to long to match the arg type. I don't really care too much about getting a GLsizei or whatever appropriate type in. However, there were a number of real bugs, like missing arguments or passing floats to integer format specifiers. My favorite: printflike("%s, argument") is missing an argument.
* mesa: use atexit() handler to release GLSL compiler memoryBrian Paul2010-08-271-0/+9
| | | | | | | | This releases a bunch of memory that was showing up as leaks with valgrind. If atexit() isn't widely supported we may need to add some #ifdef tests around the call.
* mesa: Silence uninitialized variable warnings in dummy_enum_func.Vinson Lee2010-08-191-10/+10
|
* mesa: use switch stmt in init_program_limits()Brian Paul2010-08-101-5/+10
|
* mesa: initial support for ARB_geometry_shader4Zack Rusin2010-06-281-1/+19
| | | | | | laying down the foundation for everything and implementing most of the stuff. linking, gl_VerticesIn and multidimensional inputs are left.
* mesa: initialize extension string when context is first boundBrian Paul2010-06-251-0/+2
| | | | | | | | ...instead of waiting until glGetString(GL_EXTENSIONS) is called. This fixes a problem where the MESA_EXTENSION_OVERRIDE env var is ignored if the app never calls glGetString(GL_EXTENSIONS). NOTE: this is a candidate patch for the 7.8 branch.
* mesa: rename src/mesa/shader/ to src/mesa/program/Brian Paul2010-06-101-2/+2
|
* mesa: refactor shader api / object codeBrian Paul2010-06-101-1/+1
| | | | | Remove the unneeded ctx->Driver hooks for shader-related functions. Move state and API-related things into main/.
* mesa: Optimize get.c by using a table-driven approachKristian Høgsberg2010-05-111-0/+1
|
* mesa: Only initialize TNL for OpenGLKristian Høgsberg2010-05-031-4/+5
|
* mesa: Only initialize save dispatch table for OpenGLKristian Høgsberg2010-05-031-12/+10
|
* mesa: increase MAX_DRAW_BUFFERS to 8Brian Paul2010-05-031-0/+3
| | | | Required for GL 3.x
* mesa: Move api_exec_es*.c into mesa/mainKristian Høgsberg2010-04-271-5/+43
| | | | | This requires renaming a few functions to have unique names so that they can all live within the same driver.
* mesa: Move struct _glapi_table allocation out of context.cKristian Høgsberg2010-04-221-13/+13
| | | | | | We now allocate the table from api_exec.c and dlist.c where we fill out the table. This way, context.c doesn't need to know the actual contents of struct _glapi_table.
* mesa: Move API specific context intialization into context.cKristian Høgsberg2010-04-221-3/+25
|
* mesa: Track the OpenGL API we're implementing in the contextKristian Høgsberg2010-04-221-11/+41
| | | | | | | | | | | | | | | | This introduces a new way to create or initialize a context: _mesa_create_context_for_api and _mesa_initialize_context_for_api which in addition to the current arguments take an api enum to indicate which OpenGL API the context should implement. At this point the API field in GLcontext isn't used anywhere, but later commits will key certain functionality off of it. The _mesa_create_context and _mesa_initialize_context functions are kept in place as wrappers around the *_for_api versions, passing in API_OPENGL to get the same behavior as before.
* mesa: add GL 3.2 GL_CONTEXT_PROFILE_MASK queryBrian Paul2010-04-201-0/+3
|