I'm using this method to capture the screen in LIBGDX. Most of the time I get a black screen. When I do get something though it does not capture all the contents of the screen. I have a few scene2D tables that are not captured and some of the elements on the screen (like fonts) are flipped horizontally.
I've tried all the solutions on the internet on screen capturing but I only get a black screen, OR, with the above method, scarcely any result. Is there any chance I can capture LIBGDX screens (loaded with shaders) properly?
Related
Here is my issue, the way my game works is that you click on the edges of the screen to navigate. This is done through an Overlay Canvas using OnPointerClick. I colored the navigation areas, and scale the canvas according to screen size and the navigation areas appear on their screen as they should. Yet they CANNOT click any of the elements for some reason. They have another monitor that works without issue. They've noted that their larger monitor is AMD. I've also confirmed that the ability to navigate in game has not been hindered. I have never had this issue (or any other testers) on 1920x1080 monitors.
I have completely exhausted what the issue can be, they cannot even navigate on a bare bones tutorial. Any ideas would be GREATLY appreciated.
Here is an image of their screen and the respective clickable navigation areas.
[img]https://i.imgur.com/NVQkA8g.png[/img]
Unity 2019.2.14f1
Put a Image component without sprite, because without that, you will not detect any click. You can set the alpha to 0 after you see that working.
Also check the anchors of the navigation areas.
What exactly is Gdk Screen represent?
My guess was that Screen represent whole display area of the pc and Window represent display area of certain application.
Then what is the meaning of adding provider to the screen in code shown below.I think i m interested in styling only current application window.
css_provider = Gtk.CssProvider()
css_provider.load_from_data(css.encode())
context = Gtk.StyleContext()
screen = Gdk.Screen.get_default()
context.add_provider_for_screen(screen, css_provider,
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION)
Adds a global style provider to screen, which will be used in style
construction for all Gtk.StyleContexts under screen
this is in the documentation of add_provider_for_screen().
Am i not understanding What screen is properly?
Yes Gtk.screen is the system screen and it handle all the physical screens(multiple monitors). This is that there is one screen for all the monitors(or is the common case); with this in mind, monitors doesn't need to have the same dimensions and, once the application is running it cannot change the style by itself, so this is the screen job. This prevents the application to display annoying sizes along the screen.
So, since 5 pixels are not always 5 pixels, style is something that needs be managed by the screen and not by the window, and all of that without considering the color management.
We're having this weird problem with a game we're porting to mobile: All UI elements work fine, except when you run it on a phone with notches (iPhoneX for instance). When that happens the interface gets rescaled to fit the device's safe area, which creates two black bars on the extremes (which is ok for now). Then, the area in which you have to click to activate any buttons doesn't correspond to the button graphics themselves anymore.
It's as if the input detection area is stretched to cover the entire area of the phone, but the graphics are scaled down, "dislocating" the input touch areas.
The picture below shows the problem:
Notice the red scribbles showing the area that's outside the safe areas, and the green circle showing where the input for the button actually went.
Additional info: for the levels to work properly we have to force the resolution to 1080 using Screen.SetResolution(). Could this have anything to do with the problem?
I am working on a 2D project and I want to zoom in my map by scrollwheel. I am sure that my code is working (because during the play mode, field of view changes when scrollwheel is rotated) but no change on the screen is observed.
Besides, during play mode even if I change the field of view manually (from the editor), the screen view remains same. That is, although field of view is observed to be seen changing but the screen view is not.
What are the possible reasons for that?
Here is the screenshot of the editor attached:
Possibly because you're using screen space canvas. Put the canvas in the world space for field of view to have any effect.
How do I show the on screen keyboard of mobile devices on top of the canvas in Unity3D? My canvas now shrinks in size because of the on screen keyboard, which is not what I want.
I don't believe there is an inbuilt feature for this you would have to do it manually using OnGUI(). To draw something on top of something else just put the script in the order you want it drawn. That means the last peice of gui script will be ontop.