{"id":19817151,"url":"https://github.com/nvpro-samples/dx12_present_barrier","last_synced_at":"2025-08-23T06:04:43.252Z","repository":{"id":86083439,"uuid":"517822623","full_name":"nvpro-samples/dx12_present_barrier","owner":"nvpro-samples","description":"This sample demonstrates the usage of the new NvAPI interface to synchronize present calls between windows on the same system as well as on distributed systems.","archived":false,"fork":false,"pushed_at":"2024-07-24T12:06:53.000Z","size":59,"stargazers_count":8,"open_issues_count":0,"forks_count":3,"subscribers_count":11,"default_branch":"main","last_synced_at":"2025-05-01T11:36:23.597Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nvpro-samples.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-07-25T21:14:24.000Z","updated_at":"2025-04-16T22:44:35.000Z","dependencies_parsed_at":"2024-01-17T18:29:41.908Z","dependency_job_id":"4b8c51ad-ac09-4ce7-8141-a7f33d93093c","html_url":"https://github.com/nvpro-samples/dx12_present_barrier","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nvpro-samples/dx12_present_barrier","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvpro-samples%2Fdx12_present_barrier","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvpro-samples%2Fdx12_present_barrier/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvpro-samples%2Fdx12_present_barrier/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvpro-samples%2Fdx12_present_barrier/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nvpro-samples","download_url":"https://codeload.github.com/nvpro-samples/dx12_present_barrier/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nvpro-samples%2Fdx12_present_barrier/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271745662,"owners_count":24813515,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-23T02:00:09.327Z","response_time":69,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T10:11:50.980Z","updated_at":"2025-08-23T06:04:43.223Z","avatar_url":"https://github.com/nvpro-samples.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dx12_present_barrier\n\n![A screenshot of the dx12_present_barrier sample running. At the top, a green bar shows that the swap barrier is in present barrier sync across systems using framelock. Green and red bars scroll across the screen in perpendicular directions. A Present Barrier Stats window in the upper left reads \"SyncMode: SYNC_SYSTEM; PresentCount: 670; PresentInSyncCount: 664; FlipInSyncCount: 663; RefreshCount: 1132.\"](doc/dx12_present_barrier.jpg)\n\nThis sample demonstrates the usage of the new NvAPI interface to synchronize\npresent calls between windows on the same system as well as on distributed\nsystems. It can also be used to check if systems are configured to support\nsynchronized present through DirectX 12 present barrier. A general overview of\nthe interface can be found on the [NVIDIA developer blog](https://developer.nvidia.com/blog/synchronizing-present-calls-between-applications-on-distributed-systems-with-directx-12/).\n\n## System Requirements\n* NVIDIA RTX / Quadro series card (GeForce is NOT supported)\n* 472.12 driver or newer\n* NVAPI R470 or newer (can be downloaded from [here](https://developer.nvidia.com/nvapi))\n\n## Sample Features\n\nThe app draws a couple of moving bars and lines to visually check the\nsynchronization quality. In the upper left corner a window with present barrier\nstatistics is shown. There are several keyboard shortcuts that can be used at\nruntime.\n* V          - Toggle vsync\n* S          - Toggle scrolling of the lines\n* T          - Toggle present barrier\n* Q          - Toggle usage of the Quadro Sync frame counter\n* W          - Increase sleep interval between presets by 1ms\n* Alt + W    - Reset sleep interval between presents to zero (effectively disabling it)\n* Shift + W  - Decrease sleep interval between presents by 1ms\n* 2          - Toggle stereoscopic rendering\n\nA bar at the top of the window indicates the present barrier status.\n* red     - The swap chain is not in present barrier sync\n* yellow  - The swap chain is in present barrier sync with other clients on the local system\n* green   - The swap chain is in present barrier sync across systems through framelock\n\n## Build and Run\n\nClone https://github.com/nvpro-samples/nvpro_core.git\nnext to this repository (or pull latest `master` if you already have it):\n\n`mkdir build \u0026\u0026 cd build \u0026\u0026 cmake .. # Or use CMake GUI`\n\nIf there are missing dependencies (e.g. glfw), run `git submodule\nupdate --init --recursive --checkout --force` in the `nvpro_core`\nrepository.\n\nThen start the generated `.sln` in VS or run `make -j`.\n\nRun `dx12_present_barrier` or `../../bin_x64/Release/dx12_present_barrier.exe`\n\nYou are advised not to run the debug build unless you have the\nrequired validation layers.\n\n## LICENSE\n\nCopyright 2022 NVIDIA CORPORATION. Released under Apache License,\nVersion 2.0. See \"LICENSE\" file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnvpro-samples%2Fdx12_present_barrier","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnvpro-samples%2Fdx12_present_barrier","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnvpro-samples%2Fdx12_present_barrier/lists"}