1 | import { Texture } from '../textures/Texture';
|
2 | import { BaseRenderTexture } from './BaseRenderTexture';
|
3 | import type { MSAA_QUALITY } from '@pixi/constants';
|
4 | import type { Rectangle } from '@pixi/math';
|
5 | import type { Framebuffer } from '../framebuffer/Framebuffer';
|
6 | import type { IBaseTextureOptions } from '../textures/BaseTexture';
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 |
|
30 |
|
31 |
|
32 |
|
33 |
|
34 |
|
35 |
|
36 |
|
37 |
|
38 |
|
39 |
|
40 |
|
41 |
|
42 | export declare class RenderTexture extends Texture {
|
43 | baseTexture: BaseRenderTexture;
|
44 | |
45 |
|
46 |
|
47 |
|
48 |
|
49 |
|
50 | filterFrame: Rectangle | null;
|
51 | |
52 |
|
53 |
|
54 |
|
55 | filterPoolKey: string | number | null;
|
56 | |
57 |
|
58 |
|
59 |
|
60 | constructor(baseRenderTexture: BaseRenderTexture, frame?: Rectangle);
|
61 | /**
|
62 | * Shortcut to `this.baseTexture.framebuffer`, saves baseTexture cast.
|
63 | * @readonly
|
64 | */
|
65 | get framebuffer(): Framebuffer;
|
66 | /**
|
67 | * Shortcut to `this.framebuffer.multisample`.
|
68 | * @default PIXI.MSAA_QUALITY.NONE
|
69 | */
|
70 | get multisample(): MSAA_QUALITY;
|
71 | set multisample(value: MSAA_QUALITY);
|
72 | /**
|
73 | * Resizes the RenderTexture.
|
74 | * @param desiredWidth - The desired width to resize to.
|
75 | * @param desiredHeight - The desired height to resize to.
|
76 | * @param resizeBaseTexture - Should the baseTexture.width and height values be resized as well?
|
77 | */
|
78 | resize(desiredWidth: number, desiredHeight: number, resizeBaseTexture?: boolean): void;
|
79 | /**
|
80 | * Changes the resolution of baseTexture, but does not change framebuffer size.
|
81 | * @param resolution - The new resolution to apply to RenderTexture
|
82 | */
|
83 | setResolution(resolution: number): void;
|
84 | /**
|
85 | * A short hand way of creating a render texture.
|
86 | * @param options - Options
|
87 | * @param {number} [options.width=100] - The width of the render texture
|
88 | * @param {number} [options.height=100] - The height of the render texture
|
89 | * @param {PIXI.SCALE_MODES} [options.scaleMode=PIXI.BaseTexture.defaultOptions.scaleMode] - See {@link PIXI.SCALE_MODES}
|
90 | * for possible values
|
91 | * @param {number} [options.resolution=PIXI.settings.RESOLUTION] - The resolution / device pixel ratio of the texture
|
92 | * being generated
|
93 | * @param {PIXI.MSAA_QUALITY} [options.multisample=PIXI.MSAA_QUALITY.NONE] - The number of samples of the frame buffer
|
94 | * @returns The new render texture
|
95 | */
|
96 | static create(options?: IBaseTextureOptions): RenderTexture;
|
97 | }
|