Skip to main content

Questions tagged [viewport]

An area (typically rectangular) expressed in rendering-device-specific coordinates, e.g. pixels for screen coordinates, in which the objects of interest are going to be rendered

0 votes
1 answer
67 views

How to convert a dynamic VIewportTexture to a "static" one?

Assume there is a viewport that "looks" at some Sprite2D. This viewport's view is providing the texture for a Sprite3D ...
Noideas's user avatar
  • 17
1 vote
1 answer
86 views

How to use Subviewports to render a texture for Sprite3D?

Godot 4.2 Background: In my game prototype, I have a following player entity: Paperdoll2D has a script that dynamically adds the weapon/armor/etc Sprite2D nodes to the main sprite to "dress-up&...
Noideas's user avatar
  • 17
0 votes
0 answers
175 views

Viewport blurry when playing as character

In Unreal Engine 5, whenever I run the game, the viewport becomes very blurry with strange artifacting and twitching. This only happens when I'm attached to the player controller. If I eject from it, ...
Candle's user avatar
  • 141
0 votes
0 answers
58 views

Is it possible to activate/deactivate depth writes in geometry shader?

I'm trying to achieve rendering to multiple targets with multiple viewports. Currently it does not work possibly because I have a single depth buffer so a first write to it with a specific viewport ...
philB's user avatar
  • 139
3 votes
1 answer
1k views

How do I render a pixel art game in a modern (scalable, smooth, crisp, hdpi friendly) way with Godot?

In modern pixel art games, one will usually find the following features: dpi agnostic: Having an HDPI screen does not mean the game is tiny. "large" pixels: Game-pixels are big, made up of ...
Seph Reed's user avatar
  • 235
1 vote
1 answer
126 views

How to render picture-in-picture effect with libGDX camera

libGDX cameras are mostly used for layered rendering with different "world unit size," but I wonder is there a way of showing the view of for example a libGDX Orthographic camera in the ...
CallOfVoid's user avatar
0 votes
1 answer
62 views

Viewport offset from top also creates a gap at the bottom

I am trying to do something really basic with sf::View. On a 1280x720 pixel window. I need to place a viewport which is 560x560 with a 160px gap from the top. What ...
Aaron Z's user avatar
  • 43
0 votes
0 answers
305 views

Setting glOrtho and glViewport so top-left of window has coordinates (0,0)

I haven't used OpenGL for a long time and have trouble setting up a 2D screen where the upper left window coordinates are (0,0) and the width and height of the ...
stuv_2028's user avatar
0 votes
1 answer
72 views

Multiple viewport resizing

I wonder how multiple viewports are handled in engines in terms of render targets buffers. Especially in the case of their resizing (for example changing the size of windows/viewports in Editor dock ...
justix's user avatar
  • 11
1 vote
2 answers
963 views

How to make a collision object within a viewport detect mouse inputs?

I am working on a 2D game with a spatial node (a 3d node) inside a viewport. Nodes within the viewport should be able to detect user input from what I can find online, but for some reason it doesn't ...
Qusk2's user avatar
  • 11
1 vote
0 answers
146 views

Drawing angle between 2 rays

Currently, we can draw rays in real time, like this: ...
BumbleBee's user avatar
2 votes
1 answer
645 views

Spritesheet with unstable width

I'm working on my 2d game engine using HTML5 and Canvas. I have a sprite sheet, and each frame of this sprite sheet has its own size. Considering that the Viewport is following this sprite sheet (in ...
cs.edoardo's user avatar
0 votes
1 answer
433 views

Calculating view matrix from rotation, elevation and location

I have the rotation(A), elevation(B) and location(C) of a camera in a left handed 3d space. +...
fctorial's user avatar
  • 101
2 votes
1 answer
1k views

How to access a ViewportTexture's depth data as an image?

I make use of ViewportTextures, kind of like rendering security cameras on screens. Now, I'd need to access the depth textures to do some comparison of images / pixels. How do I access the depth data ...
manabreak's user avatar
  • 1,048
0 votes
1 answer
191 views

OpenGL translation based on “scaled” pixels? (Not physical pixels)

My (2D!) game runs in a “scaling mode” so to speak, and I’ve yet to find anyone asking this question anywhere. Basically, I want to achieve a sort of “scaling algorithm” whether graphics are ...
Redful Oakside's user avatar

15 30 50 per page
1
2 3 4 5
9