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

Filter by
Sorted by
Tagged with
1 vote
1 answer
67 views

I am currently implementing a map editor for a 2D platformer and run into trouble with my viewport and mouse movement. I have two viewports: one main viewport in the top 2/3 of the screen which has a ...
Canox's user avatar
  • 113
0 votes
1 answer
250 views

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
  • 19
1 vote
1 answer
585 views

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
  • 19
0 votes
0 answers
416 views

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
103 views

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
  • 333
3 votes
1 answer
2k views

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
  • 275
1 vote
1 answer
174 views

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
81 views

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
  • 143
0 votes
0 answers
430 views

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
117 views

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
1k views

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
176 views

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

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
513 views

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

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,078
0 votes
1 answer
281 views

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
1 vote
1 answer
2k views

So, I'm implementing SSAO as part of my rendering pipeline using OpenGL/GLSL. It works pretty well when I have a camera that takes up the entire screen. However, when my camera is smaller than the ...
Danny's user avatar
  • 123
0 votes
0 answers
78 views

I am currently experimenting with the DIY holograms. Does anyone know to split my windows into 4 perpendicular identical displays like this but for Windows? I am using Unreal Engine & I want it to ...
Ahmed Amr Salah's user avatar
2 votes
1 answer
3k views

The shortcuts in Unity are more similar to Maya (Alt+Middle for 3d orientation, LeftClick select, etc). I've looked into Edit -> Shortcuts but couldnt find them. Is there any way to do this?
votka35's user avatar
  • 21
0 votes
0 answers
91 views

Could anyone please give me a hint on how to determine how much of an object is seen by a camera. There have to be a threshold value (e.g. 30% of an object is seen). If value is below the threshold ...
Hillbilly Joe's user avatar
0 votes
1 answer
141 views

For some reason when the game runs in the regular viewport (not it's own) a grey haze slowly appears. This never used to happen. The level architecture (code) changed recently and then this started ...
TinyTRex's user avatar
0 votes
0 answers
67 views

I'm currently working on a 2D game where I'm trying to pre-populate my level with encounters, I want the enemies already in the room when the player enters. Right now the encounter is triggered upon ...
Tristan Barona's user avatar
1 vote
1 answer
2k views

All tutorials I've found about this link to the splitscreen demo, but it is made under Godot version 2 and does not work in version 3. I want to render the world in the main viewport and its ...
Robotex's user avatar
  • 251
0 votes
0 answers
2k views

For this project I am using GLFW, glad and glm. My window looks like this: The dimensions of the window are correct, but the viewport is stretched, making my square into a rectangle. How do I use a ...
user avatar
0 votes
1 answer
125 views

With this code I intended to visually delimit the complete view of the circuit and the two controlled cars: ...
Boneco Sinforoso's user avatar
0 votes
0 answers
74 views

Implementing a viewport is just a rectangular space on the back buffer usually a 2d texture set to the size of the client window that we render to. However in direct3d when we describe the viewport ...
Ryan J.S's user avatar
0 votes
1 answer
55 views

I have an adm object, which draws the path in the room like this (Object ADM - Draw Event): ...
Boneco Sinforoso's user avatar
0 votes
1 answer
576 views

I am using x and z axis to go left/right ; up/down respectively. The Camera is on the y-axis. I have the following code so far - private float playerWidth; private float playerDepth; ...
firepro20's user avatar
2 votes
1 answer
504 views

The question is just a logical extension of this question. So, how should I render a cylindrical world space onto a flat, 2D view port in Unity? Thank you.
iamyourfriend's user avatar
0 votes
1 answer
1k views

Some additional remarks before I address the issue: How Viewports work in Unity: Whatever the dimensions of the screen's rect, the viewports coordinates are mapped in normalized coordinates, where 0 ...
LifGwaethrakindo's user avatar
0 votes
1 answer
274 views

I'm facing very strange issue. My code for world pos reconstruction works correctly when the viewport size is equal to window size (or framebuffer size in other words). Below is the part for ...
Harry's user avatar
  • 690
0 votes
1 answer
1k views

I've been getting started with personal experimentation and have been working on a project for a few days now using SDL2. It is a 2D game, and at this stage I have it rendering game objects in a fixed-...
Sam's user avatar
  • 1
2 votes
0 answers
892 views

I am making an app that has a custom viewport Rect like so: When I check the sizes of this viewport rectangle in pixels with Camera.pixelHeight; Camera.pixelWidth, ...
FutureCake's user avatar
2 votes
2 answers
319 views

Is it possible in Unity to make some sort of bounding box (with a running application) within the current viewpoint of the actual screen? Let me explain: I'm working on a project which uses a ...
runningfrmyellow's user avatar
0 votes
1 answer
261 views

I am working on porting a low-res game over to Unity. In my previous engine, I had the option to set a native resolution (say, 160 x 144), and it would automatically stretch when the player entered ...
DyingIsFun's user avatar
  • 1,337
0 votes
0 answers
437 views

I try programming a splix.io clone as an electron app and do the visualization via the html5 canvas. The movement across the tiles should look fluent like the original, so I target 60 frames a second. ...
Medolie's user avatar
0 votes
1 answer
601 views

I am playing around adapting the example code at Mozilla Dev Network: Square tilemaps implementation: Scrolling maps to fit with a server I wrote myself. There's a link to the original source code at ...
Fedor Alexander Steeman's user avatar
0 votes
2 answers
261 views

I have a 3d camera that is viewing a character that is moving. As the character is moving i want the camera to adjust itself so as to keep the character in the left third of the camera view. I ...
SRG's user avatar
  • 101
-3 votes
1 answer
292 views

I want to make a 2D Minecraft game and I have drawn the grass blocks and you can dig but when the palyer moves the dirt moves too. It draws on every block wich the player touches a dirt block because ...
ProgrammerProgrammerIOSAN's user avatar
0 votes
1 answer
673 views

I have a 2D tile based engine with infinite procedural chunk generation. But I can't invent an algorithm, that will fill only chunk tiles on view port (and destroy old). Pls help ViewPort size can ...
Michael Kors's user avatar
1 vote
2 answers
635 views

I'm new to libgdx and especially to using OrthographicCameras. I'm trying to understand how useful they are. The question is, suppose I have a game map 500 units wide. I have an OrtographicCamera ...
Tom Milberg's user avatar
1 vote
1 answer
954 views

I'm having a bit of an issue when it comes to 3D- and 2D camera(s), in relation to a game's window resolution. I want to let the player choose from different window resolutions, either from a menu or ...
Daniel_1985's user avatar
0 votes
1 answer
316 views

I'm building a 2D game engine that uses tilesets to build levels. I recently added functionality to handle wraparounds (ie. where the right edge of the map connects to the left edge.) The engine ...
Mason Wheeler's user avatar
0 votes
2 answers
589 views

Before someone mark it duplicate - I am aware that there are few questions already on this topic but the explanations are all theoretical and no graphical elaboration was provided which I think will ...
Harry_S's user avatar
  • 105
1 vote
0 answers
895 views

I'm rendering the camera output to an rendertexture on a plane. This works fine. But I want to put GameObjects on the rendertexture on positions of world objects that are visible on the camera. <...
Martijn Mellens's user avatar
1 vote
0 answers
100 views

I am in the process of learning javascript for game design, and wanted to make a separate achievement page that the user can navigate to that will allow them to check their achievements on various ...
Kerma's user avatar
  • 11
0 votes
2 answers
5k views

I am really enjoying making the switch to Unity. But here I have found one of those rare moments where it appears to make things more difficult (at least it is for me as I am crap at understanding the ...
Big T Larrity's user avatar
3 votes
1 answer
2k views

I'm reading the book LibGDX game development by example and the author tends to follow a pattern like ...
Persson's user avatar
  • 33
-1 votes
1 answer
202 views

Let's take typical modern RTS game which features a large map (say 256x256 tiles). There's also a minimap in the GUI, typically up to 256x256 pixels in size. (Let's take these numbers for upcoming ...
Kromster's user avatar
  • 10.7k
3 votes
4 answers
3k views

I learn matrix transformations for game design and I struggle with some basic concepts. I see the actual multiplication taking place before rendering in this sequence: MODEL into WORLD: multiply each ...
coobit's user avatar
  • 291