Edit of asset "2D in 3D Viewport Demo" Accepted

Old/Current New/Edit
Title 2D in 3D Viewport Demo 2D in 3D Viewport Demo
Description A demo showing how a 2D scene can be shown within a 3D scene using viewports.

How it works:

The Pong game is rendered to a custom Viewport node rather than the main Viewport. In the code, `get_texture()` is called on the Viewport to get a ViewportTexture, which is then assigned to the quad's material's albedo texture.

Language: GDScript

Renderer: Compatibility
A demo showing how a 2D scene can be shown within a 3D scene using viewports.

Language: GDScript

Renderer: Compatibility

How it works:

The Pong game is rendered to a custom Viewport node rather than the main Viewport. In the code, `get_texture()` is called on the Viewport to get a ViewportTexture, which is then assigned to the quad's material's albedo texture.
Category Demos Demos
License MIT MIT
Repository Provider Custom Custom
Repository Url https://github.com/godotengine/godot-demo-projects/tree/4.2-31d1c0c/viewport/2d_in_3d https://github.com/godotengine/godot-demo-projects/tree/4.2-31d1c0c/viewport/2d_in_3d
Issues Url https://github.com/godotengine/godot-demo-projects/issues https://github.com/godotengine/godot-demo-projects/issues
Godot version Godot 4.2 Godot 4.2
Version String 4.2-31d1c0c 4.2-31d1c0c
Download Commit https://github.com/godotengine/godot-demo-projects/releases/download/4.2-31d1c0c/viewport_2d_in_3d.zip https://github.com/godotengine/godot-demo-projects/releases/download/4.2-31d1c0c/viewport_2d_in_3d.zip
Download Url (Computed) https://github.com/godotengine/godot-demo-projects/releases/download/4.2-31d1c0c/viewport_2d_in_3d.zip https://github.com/godotengine/godot-demo-projects/releases/download/4.2-31d1c0c/viewport_2d_in_3d.zip
Icon Url https://raw.githubusercontent.com/godotengine/godot-demo-projects/4.2-31d1c0c/viewport/2d_in_3d/icon.webp
https://raw.githubusercontent.com/godotengine/godot-demo-projects/4.2-31d1c0c/viewport/2d_in_3d/icon.webp
Preview Insert
Type image
Image/Video URL https://raw.githubusercontent.com/godotengine/godot-demo-projects/4.2-31d1c0c/viewport/2d_in_3d/screenshots/2d_in_3d.webp
Thumbnail