docs: update gpu docs (#10562)

This commit is contained in:
Alex Rudenko 2023-07-17 14:13:13 +02:00 committed by GitHub
parent de09b058ba
commit 6f31c52217
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -172,13 +172,13 @@ yum update nss -y
## Chrome headless disables GPU compositing ## Chrome headless disables GPU compositing
Chrome/Chromium requires `--use-gl=egl` to Chrome/Chromium requires `--enable-gpu` to
[enable GPU acceleration in headless mode](https://github.com/chromium/chromium/commit/19671359ae25aa1e30bde90f8ff92453eeaac2ba). [enable GPU acceleration in headless mode](https://crbug.com/1416283).
```ts ```ts
const browser = await puppeteer.launch({ const browser = await puppeteer.launch({
headless: true, headless: true,
args: ['--use-gl=egl'], args: ['--enable-gpu'],
}); });
``` ```

View File

@ -24,7 +24,7 @@ import {EventEmitter} from '../common/EventEmitter.js';
import type {Target} from '../common/Target.js'; // TODO: move to ./api import type {Target} from '../common/Target.js'; // TODO: move to ./api
import type {BrowserContext} from './BrowserContext.js'; import type {BrowserContext} from './BrowserContext.js';
import type {Page} from './Page.js'; // TODO: move to ./api import type {Page} from './Page.js';
/** /**
* BrowserContext options. * BrowserContext options.