summaryrefslogtreecommitdiffstats
path: root/src/video_core/engines/maxwell_3d.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* maxwell_3d: Fix macro binding cursorReinUsesLisp2019-09-011-1/+1
|
* Merge pull request #2704 from FernandoS27/conditionalbunnei2019-07-241-1/+44
|\ | | | | maxwell3d: Implement Conditional Rendering
| * maxwell3d: Implement Conditional RenderingFernando Sahmkow2019-07-171-1/+44
| | | | | | | | | | | | Conditional Rendering takes care of conditionaly clearing or drawing depending on a set of queries. This PR implements the query checks to stablish if things can be rendered or not.
* | Maxwell3D: Reorganize and address feedbackFernando Sahmkow2019-07-201-2/+2
| |
* | GL_State: Feedback and fixesFernando Sahmkow2019-07-171-1/+7
| |
* | Maxwell3D: Address FeedbackFernando Sahmkow2019-07-171-3/+3
| |
* | Maxwell3D: Implement State Dirty Flags.Fernando Sahmkow2019-07-171-6/+4
| |
* | Maxwell3D: Rework CBData UploadFernando Sahmkow2019-07-171-0/+11
| |
* | Maxwell3D: Rework the dirty system to be more consistant and scaleableFernando Sahmkow2019-07-171-11/+63
|/
* gl_rasterizer: Minor style changesReinUsesLisp2019-07-061-0/+1
|
* video_core/engines: Move ConstBufferInfo out of Maxwell3DReinUsesLisp2019-06-081-7/+1
|
* Merge pull request #2441 from ReinUsesLisp/al2pbunnei2019-05-191-0/+1
|\ | | | | shader: Implement AL2P and ALD.PHYS
| * gl_shader_decompiler: Declare all possible varyings on physical attribute usageReinUsesLisp2019-05-031-0/+1
| |
* | video_core/engines/maxwell_3d: Add is_trivially_copyable_v check for RegsLioncash2019-05-141-0/+2
| | | | | | | | | | | | | | std::memset is used to clear the entire register structure, which requires that the Regs struct be trivially copyable (otherwise undefined behavior is invoked). This prevents the case where a non-trivial type is potentially added to the struct.
* | Merge pull request #2429 from FernandoS27/computebunnei2019-05-091-1/+24
|\ \ | |/ |/| Corrections and Implementation on GPU Engines
| * Refactors and name corrections.Fernando Sahmkow2019-05-011-1/+1
| |
| * Add Documentation Headers to all the GPU EnginesFernando Sahmkow2019-04-231-0/+6
| |
| * Implement Maxwell3D Data UploadFernando Sahmkow2019-04-231-1/+18
| |
* | Merge pull request #2322 from ReinUsesLisp/wswitchbunnei2019-04-291-2/+3
|\ \ | |/ |/| video_core: Silent -Wswitch warnings
| * video_core: Silent -Wswitch warningsReinUsesLisp2019-04-181-2/+3
| |
* | Move ConstBufferAccessor to Maxwell3d, correct mistakes and clang format.Fernando Sahmkow2019-04-081-0/+2
| |
* | Implement Bindless Handling on SetupTextureFernando Sahmkow2019-04-081-0/+4
|/
* Merge pull request #2317 from FernandoS27/syncbunnei2019-04-061-1/+15
|\ | | | | Implement SyncPoint Register in the GPU.
| * Implement SyncPoint Register in the GPU.Fernando Sahmkow2019-04-061-1/+15
| |
* | video_core/engines: Make memory manager members privateLioncash2019-04-061-1/+2
| | | | | | | | | | These aren't used externally by anything, so they can be made private data members.
* | video_core/engines: Remove unnecessary inclusions where applicableLioncash2019-04-061-1/+4
|/ | | | | | Replaces header inclusions with forward declarations where applicable and also removes unused headers within the cpp file. This reduces a few more dependencies on core/memory.h
* Merge pull request #2163 from ReinUsesLisp/bitset-dirtybunnei2019-02-281-7/+8
|\ | | | | maxwell_3d: Use std::bitset to manage dirty flags
| * maxwell_3d: Use std::bitset to manage dirty flagsReinUsesLisp2019-02-261-7/+8
| |
* | common/math_util: Move contents into the Common namespaceLioncash2019-02-271-1/+1
|/ | | | | These types are within the common library, so they should be within the Common namespace.
* video_core: Remove usages of System::GetInstance() within the enginesLioncash2019-02-161-1/+8
| | | | | Avoids the use of the global accessor in favor of explicitly making the system a dependency within the interface.
* gl_rasterizer_cache: Use dirty flags for the depth bufferReinUsesLisp2019-01-071-0/+2
|
* gl_rasterizer_cache: Use dirty flags for color buffersReinUsesLisp2019-01-071-0/+3
|
* gl_shader_cache: Use dirty flags for shadersReinUsesLisp2019-01-071-0/+3
|
* Fixed uninitialized memory due to missing returns in canaryDavid Marcec2018-12-191-0/+2
| | | | Functions which are suppose to crash on non canary builds usually don't return anything which lead to uninitialized memory being used.
* gl_rasterizer: Enable clip distances when set in register and in shaderReinUsesLisp2018-11-291-0/+1
|
* Merge pull request #1808 from Tinob/masterbunnei2018-11-281-1/+15
|\ | | | | Fix clip distance and viewport
| * Add support for Clip Distance enabled registerRodolfo Bogado2018-11-271-1/+15
| |
* | Merge pull request #1786 from Tinob/DepthClampbunnei2018-11-281-1/+9
|\ \ | | | | | | Add Depth Clamp Support
| * | Implement depth clampRodolfo Bogado2018-11-271-1/+9
| |/
* / gpu: Rewrite GPU command list processing with DmaPusher class.bunnei2018-11-271-1/+1
|/ | | | - More accurate impl., fixes Undertale (among other games).
* Merge pull request #1794 from Tinob/masterbunnei2018-11-271-1/+9
|\ | | | | Add support for viewport_transfom_enable register
| * Add support for viewport_transfom_enable registerRodolfo Bogado2018-11-241-1/+9
| |
* | Merge pull request #1723 from degasus/dirty_flagsbunnei2018-11-271-0/+5
|\ \ | | | | | | gl_rasterizer: Skip VB upload if the state is clean.
| * | gl_rasterizer: Skip VB upload if the state is clean.Markus Wick2018-11-171-0/+5
| | |
* | | GPU States: Implement Polygon Offset. This is used in SMO all the time. (#1784)Marcos2018-11-271-4/+26
| | | | | | | | | | | | | | | | | | | | | | | | * GPU States: Implement Polygon Offset. This is used in SMO all the time. * Clang Format fixes. * Initialize polygon_offset in the constructor.
* | | gl_shader_decompiler: Implement S2R's Y_DIRECTIONReinUsesLisp2018-11-251-0/+1
| |/ |/|
* | Add support for clear_flags registerRodolfo Bogado2018-11-241-1/+11
| |
* | maxwell_3d: Implement alternate blend equations.bunnei2018-11-221-0/+7
| | | | | | | | - Used by Undertale.
* | small fix for alphaToOne bit locationRodolfo Bogado2018-11-171-2/+2
| |
* | fix for gcc compilationRodolfo Bogado2018-11-171-60/+61
| |
* | add AlphaToCoverage and AlphaToOneRodolfo Bogado2018-11-171-1/+7
| |
* | add support for fragment_color_clampRodolfo Bogado2018-11-171-1/+4
| |
* | fix viewport and scissor behaviorRodolfo Bogado2018-11-171-10/+16
|/
* Try to fix problems with stencil test in some games, relax translation to opengl enums to avoid crashing and only generate logs of the errors.Rodolfo Bogado2018-11-111-0/+8
|
* Merge pull request #1654 from degasus/dirty_flagsbunnei2018-11-111-0/+6
|\ | | | | gl_rasterizer: Skip VAO binding if the state is clean.
| * gl_rasterizer: Skip VAO binding if the state is clean.Markus Wick2018-11-061-0/+6
| |
* | Add support to color mask to avoid issues in blending caused by wrong values in the alpha channel in some render targets.Rodolfo Bogado2018-11-051-3/+20
| |
* | Implement multi-target viewports and blendingRodolfo Bogado2018-11-051-2/+12
|/
* maxwell_3d: Restructure macro upload to use a single macro code memory.bunnei2018-11-011-4/+21
| | | | | - Fixes an issue where macros could be skipped. - Fixes rendering of distant objects in Super Mario Odyssey.
* Implement sRGB Support, including workarounds for nvidia driver issues and QT sRGB supportRodolfo Bogado2018-10-281-1/+6
|
* gl_rasterizer: Implement primitive restart.bunnei2018-10-261-1/+9
|
* maxwell_3d: Add code for initializing register defaults.bunnei2018-10-261-0/+2
|
* Implemented Alpha TestingFernandoS272018-10-221-1/+3
|
* Implement 3D TexturesFernandoS272018-10-181-1/+4
|
* Merge pull request #1458 from FernandoS27/fix-render-target-block-settingsbunnei2018-10-111-2/+22
|\ | | | | Fixed block height settings for RenderTargets and Depth Buffers
| * Add memory Layout to Render Targets and Depth BuffersFernandoS272018-10-101-2/+14
| |
| * Fixed block height settings for RenderTargets and Depth Buffers, and added block width and block depthFernandoS272018-10-101-2/+10
| |
* | Assert Scissor testsFernandoS272018-10-091-1/+16
|/
* gl_rasterizer: Implement quads topologyReinUsesLisp2018-10-041-0/+6
|
* Merge pull request #1411 from ReinUsesLisp/point-sizebunnei2018-09-291-1/+6
|\ | | | | video_core: Implement point_size and add point state sync
| * video_core: Implement point_size and add point state syncReinUsesLisp2018-09-281-1/+6
| |
* | gl_state: Pack sampler bindings into a single ARB_multi_bindReinUsesLisp2018-09-281-0/+1
|/
* video_core: Add asserts for CS, TFB and alpha testingReinUsesLisp2018-09-261-2/+10
| | | | | | Add asserts for compute shader dispatching, transform feedback being enabled and alpha testing. These have in common that they'll probably break rendering without logging.
* Port #4182 from Citra: "Prefix all size_t with std::"fearlessTobi2018-09-151-14/+14
|
* gl_rasterizer: Implement multiple color attachments.bunnei2018-09-101-1/+21
|
* gl_rasterizer: Implement a VAO cache.Markus Wick2018-09-051-2/+7
| | | | | | This patch caches VAO objects instead of re-emiting all pointers per draw call. Configuring this pointers is known as a fast task, but it yields too many GL calls. So for better performance, just bind the VAO instead of 16 pointers.
* maxwell_3d: Update to include additional stencil registers.bunnei2018-08-231-20/+50
|
* GPU: Added registers for the logicop functionality.Subv2018-08-211-1/+28
|
* GLRasterizer: Implemented instanced vertex arrays.Subv2018-08-181-1/+14
| | | | Before each draw call, for every enabled vertex array configured as instanced, we take the current instance id and divide it by its configured divisor, then we multiply that by the corresponding stride and increment the start address by the resulting amount. This way we can simulate the vertex array being incremented once per instance without actually using OpenGL's instancing functions.
* Rasterizer: Implemented instanced rendering.Subv2018-08-151-0/+3
| | | | | | We keep track of the current instance and update an uniform in the shaders to let them know which instance they are. Instanced vertex arrays are not yet implemented.
* Merge pull request #1024 from Subv/blend_glbunnei2018-08-121-0/+21
|\ | | | | GPU/Maxwell3D: Implemented an alternative set of blend factors.
| * GPU/Maxwell3D: Implemented an alternative set of blend factors.Subv2018-08-121-0/+21
| | | | | | | | These are used by nouveau and some games like SMO.
* | RasterizerGL: Ignore invalid/unset vertex attributes.Subv2018-08-121-0/+5
|/ | | | This should make the es2gears example not crash anymore.
* maxwell_3d: Use correct const buffer size and check bounds.bunnei2018-08-081-1/+1
| | | | - Fixes mem corruption with Super Mario Odyssey and Pokkén Tournament DX.
* video_core: Eliminate the g_renderer global variableLioncash2018-08-041-1/+7
| | | | | | | | | | | | | | We move the initialization of the renderer to the core class, while keeping the creation of it and any other specifics in video_core. This way we can ensure that the renderer is initialized and doesn't give unfettered access to the renderer. This also makes dependencies on types more explicit. For example, the GPU class doesn't need to depend on the existence of a renderer, it only needs to care about whether or not it has a rasterizer, but since it was accessing the global variable, it was also making the renderer a part of its dependency chain. By adjusting the interface, we can get rid of this dependency.
* maxwell_3d: Add depth buffer enable, width, and height registers.bunnei2018-07-221-2/+14
|
* video_core: Use nested namespaces where applicableLioncash2018-07-211-4/+2
| | | | Compresses a few namespace specifiers to be more compact.
* GPU: Added register definitions for the stencil parameters.Subv2018-07-171-2/+25
|
* gl_rasterizer: Fix check for if a shader stage is enabled.bunnei2018-07-131-3/+8
|
* GPU: Allow using the old NV04 values for the depth test function.Subv2018-07-051-9/+21
| | | | | | These seem to be just a valid as the GL token values. Thanks @ReinUsesLisp This restores graphical output to Disgaea 5
* GPU: Flip the triangle front face winding if the GPU is configured to not flip the triangles.Subv2018-07-041-3/+19
| | | | | | OpenGL's default behavior is already correct when the GPU is configured to flip the triangles. This fixes 1-2 Switch's splash screen.
* Merge pull request #609 from Subv/clear_buffersbunnei2018-07-041-2/+27
|\ | | | | GPU: Implemented the CLEAR_BUFFERS register.
| * GPU: Added registers for the CLEAR_BUFFERS and CLEAR_COLOR methods.Subv2018-07-031-2/+27
| |
* | GPU: Use only the least significant 3 bits when reading the depth test func.Subv2018-07-031-9/+9
|/ | | | Some games set the full GL define value here (including nouveau), but others just seem to set those last 3 bits.
* Merge pull request #608 from Subv/depthbunnei2018-07-031-4/+52
|\ | | | | GPU: Implemented the depth buffer and depth test + culling
| * GPU: Added registers for depth test and cull mode.Subv2018-07-021-3/+51
| |
| * GPU: Implemented the Z24S8 depth format and load the depth framebuffer.Subv2018-07-021-1/+1
| |
* | GPU: Added register definitions for the vertex buffer base element.Subv2018-07-021-1/+6
|/
* maxwell_3d: Add a struct for RenderTargetConfig.bunnei2018-06-271-17/+19
|
* GPU: Added registers for normal and independent blending.Subv2018-06-091-5/+26
|
* GPU: Implement sampling multiple textures in the generated glsl shaders.Subv2018-06-061-0/+3
| | | | | | All tested games that use a single texture show no regression. Only Texture2D textures are supported right now, each shader gets its own "tex_fs/vs/gs" sampler array to maintain independent textures between shader stages, the textures themselves are reused if possible.
* GPU: Calculate the correct viewport dimensions based on the scale and translate registers.Subv2018-06-041-12/+28
| | | | This is how nouveau calculates the viewport width and height. For some reason some games set 0xFFFF in the VIEWPORT_HORIZ and VIEWPORT_VERT registers, maybe those are a misnomer and actually refer to something else?
* GPU: Reduce the number of registers of Maxwell3D to 0xE00.Subv2018-04-251-2/+2
| | | | The rest are just macro shim registers.
* GPU: Move the Maxwell3D macro uploading code to the inside of the Maxwell3D processor.Subv2018-04-251-4/+13
| | | | It doesn't belong in the PFIFO handler.
* Merge pull request #386 from Subv/gpu_querybunnei2018-04-241-1/+27
|\ | | | | GPU: Added asserts to our code for handling the QUERY_GET GPU command.
| * GPU: Added asserts to our code for handling the QUERY_GET GPU command.Subv2018-04-241-1/+27
| | | | | | | | | | This is based on research from nouveau. Many things are currently unknown and will require hwtests in the future. This commit also stubs QueryMode::Write2 to do the same as Write. Nouveau code treats them interchangeably, it is currently unknown what the difference is.
* | GPU: Support multiple enabled vertex arrays.Subv2018-04-231-0/+5
|/ | | | | | The vertex arrays will be copied to the stream buffer one after the other, and the attributes will be set using the ARB_vertex_attrib_binding extension. yuzu now thus requires OpenGL 4.3 or the ARB_vertex_attrib_binding extension.
* gl_shader_gen: Support vertical/horizontal viewport flipping. (#347)bunnei2018-04-181-1/+10
| | | | | | * gl_shader_gen: Support vertical/horizontal viewport flipping. * fixup! gl_shader_gen: Support vertical/horizontal viewport flipping.
* renderer_opengl: Implement BlendEquation and BlendFunc.bunnei2018-04-181-1/+47
|
* gl_rasterizer: Implement indexed vertex mode.bunnei2018-04-171-1/+43
|
* GPU: Added a function to determine whether a shader stage is enabled or not.Subv2018-04-151-0/+3
|
* maxwell_3d: Make memory_manager public.bunnei2018-04-141-2/+1
|
* maxwell_3d: Fix shader_config decodings.bunnei2018-04-141-6/+3
|
* GPU: Use the MacroInterpreter class to execute the GPU macros instead of HLEing them.Subv2018-04-011-21/+5
|
* GPU: Implemented a gpu macro interpreter.Subv2018-04-011-0/+3
| | | | | | The Ryujinx macro interpreter and envydis were used as reference. Macros are programs that are uploaded by the games during boot and can later be called by writing to their method id in a GPU command buffer.
* gl_rasterizer: Add a SyncViewport method.bunnei2018-03-271-0/+10
|
* gl_rasterizer: Normalize vertex array data as appropriate.bunnei2018-03-271-0/+4
|
* maxwell_3d: Use names that match envytools for VertexType.bunnei2018-03-271-8/+8
|
* maxwell_3d: Add VertexAttribute struct and cleanup.bunnei2018-03-271-121/+160
|
* gl_rasterizer: Implement AnalyzeVertexArray.bunnei2018-03-271-0/+35
|
* maxwell: Add RenderTargetFormat enum.bunnei2018-03-271-3/+4
|
* GPU: Load the sampler info (TSC) when retrieving active textures.Subv2018-03-261-1/+7
|
* GPU: Added a function to retrieve the active textures for a shader stage.Subv2018-03-241-6/+10
| | | | TODO: A shader may not use all of these textures at the same time, shader analysis should be performed to determine which textures are actually sampled.
* GPU: Added viewport registers to Maxwell3D's reg structure.Subv2018-03-241-1/+18
|
* maxwell_3d: Add some format decodings and string helper functions.bunnei2018-03-231-3/+107
|
* GPU: Added vertex attribute format registers.Subv2018-03-211-1/+14
|
* GPU: Added registers for the number of vertices to render.Subv2018-03-211-2/+13
|
* GPU: Added Z buffer registers to Maxwell3D's reg structure.Subv2018-03-191-1/+17
|
* GPU: Added the render target (RT) registers to Maxwell3D's reg structure.Subv2018-03-191-1/+32
|
* GPU: Added the TSC registers to the Maxwell3D register structure.Subv2018-03-191-1/+15
|
* GPU: Added the TIC registers to the Maxwell3D register structure.Subv2018-03-191-1/+16
|
* GPU: Implement macro 0xE1A BindTextureInfoBuffer in HLE.Subv2018-03-191-1/+11
| | | | This macro simply sets the current CB_ADDRESS to the texture buffer address for the input shader stage.
* GPU: Implement the BindStorageBuffer macro method in HLE.Subv2018-03-181-1/+15
| | | | | | This macro binds the SSBO Info Buffer as the current ConstBuffer. This buffer is usually bound to c0 during shader execution. Games seem to use this macro instead of directly writing the address for some reason.
* GPU: Handle writes to the CB_DATA method.Subv2018-03-181-0/+3
| | | | | | Writing to this method will cause the written value to be stored in the currently-set ConstBuffer plus CB_POS. This method is usually used to upload uniforms or other shader-visible data.
* GPU: Store uploaded GPU macros and keep track of the number of method parameters.Subv2018-03-181-4/+8
|
* GPU: Macros are specific to the Maxwell3D engine, so handle them internally.Subv2018-03-181-8/+19
|
* GPU: Renamed ShaderType to ShaderStage as that is less confusing.Subv2018-03-181-7/+7
|
* GPU: Store shader constbuffer bindings in the GPU state.Subv2018-03-181-3/+25
|
* GPU: Corrected some register offsets and removed superfluous macro registers.Subv2018-03-181-9/+3
|
* GPU: Make the SetShader macro call do the same as the real macro's code.Subv2018-03-181-2/+25
| | | | | | It'll now set the CB_SIZE, CB_ADDRESS and CB_BIND registers when it's called. Presumably this SetShader function is binding the constant shader uniforms to buffer 1 (c1[]).
* GPU: Corrected the parameter documentation for the SetShader macro call.Subv2018-03-171-6/+6
| | | | | | Register 0xE24 is actually a macro that sets some shader parameters in the register structure. Macros are uploaded to the GPU at startup and have their own ISA, we'll probably write an interpreter for this in the future.
* Merge pull request #242 from Subv/set_shaderbunnei2018-03-171-2/+16
|\ | | | | GPU: Handle the SetShader method call (0xE24) and store the shader config.
| * GPU: Handle the SetShader method call (0xE24) and store the shader config.Subv2018-03-171-2/+16
| |
* | GPU: Added the vertex array registers.Subv2018-03-171-2/+33
|/
* Merge pull request #241 from Subv/gpu_method_callbunnei2018-03-171-1/+21
|\ | | | | GPU: Process command mode 5 (IncreaseOnce) differently from other commands
| * GPU: Process command mode 5 (IncreaseOnce) differently from other commands.Subv2018-03-171-1/+21
| | | | | | | | | | | | Accumulate all arguments before calling the desired method. Note: Maybe we should do the same for the NonIncreasing mode?
* | GPU: Added Maxwell registers for Shader Program control.Subv2018-03-171-2/+55
|/
* GPU: Intercept writes to the VERTEX_END_GL register.Subv2018-03-051-1/+9
| | | | | | This is the register that gets written after a game calls DrawArrays(). We should collect all GPU state and draw using our graphics API here.
* maxwell_3d: Make constructor explicitLioncash2018-02-141-1/+1
|
* GPU: Partially implemented the QUERY_* registers in the Maxwell3D engine.Subv2018-02-121-1/+55
| | | | Only QueryMode::Write is supported at the moment.
* Make a GPU class in VideoCore to contain the GPU state.Subv2018-02-121-3/+7
| | | | Also moved the GPU MemoryManager class to video_core since it makes more sense for it to be there.
* GPU: Added a command processor to decode the GPU pushbuffers and forward the commands to their respective engines.Subv2018-02-121-0/+18