google glass camera parameter settings - android-camera

I'm working on an app that includes a custom camera application on Glass. I want to be able to hard-set different camera parameters, but I'm having difficulty figuring out which ones I actually have access to.
I tried calling parameters.flatten() and got a whole bunch of options that I thought I would be able to use, but when I tried testing them, nothing happened. (For example, when I tried setting the color effect to sepia, the result was still in normal color). Is there any documentation or code I can look at that will tell me which parameter options I actually have?

There are a few open issues on our issue tracker about camera parameters that do not behave as expected:
Issue 302: GDK: Camera effects not registered or take affect
Issue 303: GDK: Request: Additional camera focus modes (with auto focus)
Issue 304: GDK: Camera scene mode does not register or take affect
You may want to follow those so that you can be updated as the GDK evolves.

Related

How to set the screen resolution in Unreal Engine 4?

I am making a settings menu for my game. I have created every graphics setting I want, except changing the screen resolution. This is what I tried first. I didn't know what I should provide for the target, though.
What I tried first
For some reason, this didn't work. I'm guessing I should have provided a different target. Can somebody help me with this?
Since this is one of the highest results on google I figured I'd reply here.
Using console commands to set resolution absolutely DOES NOT WORK for shipping builds where console commands are disabled. It's better to use Get Game User Settings + Set Screen Resolution + Apply Resolution Settings nodes.
Is this a PC game? If so, this is the node I've used for altering resolution in the past, utilizing the r.setRes command:
If you have variable [width] x [height] parameters, have a function build the string and pass the return value to that node. Note: after the WxH, the f stands for fullscreen.
Credit for image: https://answers.unrealengine.com/questions/26895/how-can-i-change-games-resolution-in-blueprints.html

Why is the play button on my title screen not starting the game?

I managed to open the demo game that I need to see/play, however, it looks like the title screen isn't loading correctly. Clicking on the "Play" button should allow the user to start the game, but when I try clicking on it, nothing happens.
I'm not sure why this is happening because I downloaded the exact same files as the ones that were used in the demo and I also tried deleting/redownloading the files a couple of times. I also double checked the console messages and there aren't any errors/warnings for any scripts. I'll attach a screenshot of what I see and the link to the game files themselves if anyone wants to try it on their end.
Also, if this helps, I'm using Unity version 2018.3.2f1.
Here is a link to the project if you want to try it out yourself (I'd post the code, but I don't want to put a giant block of code up without a clear direction; however, I believe the main menu content is in the "Manager.cs" file): https://drive.google.com/file/d/1ekXt948b612dmyT1AZReUOuzh2XbnSDG/view?usp=sharing
This is what the game looks like if it helps:
After reading through the code in the other scripts, I realized that the error was coming from the specific region that was being used as a "hitbox" on the screen for the play button. And because I was setting my aspect ratio differently than what the developer used, the positioning of the "hitbox" did not line up correctly on my screen. So instead, I had to change the aspect ratio to fixed resolution and specific canvas sizes (width and length).

How do I create a test app to create many screenshots in UE4?

I'd like to create a test application for my Unreal Engine based game to create screenshots. I'd like to place many (possibly thousands) of cameras throughout the maps and then have my test application enumerate them all and take a screen capture at each camera location.
I came across Taking Screenshots, but wanted to first check to see if this isn't already built into UE4 in the editor, or some tool. I'm also aware of the Screenshot Comparison Tool, but that doesn't seem to be what I need because I don't really want to use UE4 to do the image matching, but instead just want a directory full of images that I can do with what I want.
Any suggestions?
This is not directly what you want to do but I found this article very interesting: https://www.unrealengine.com/en-US/blog/capturing-stereoscopic-360-screenshots-videos-movies-unreal-engine-4?sessionInvalidated=true
It explains how people at Ninja Theory Ltd proceeded to produce their 360 video trailer which is, in the end, producing two 360 screenshots per frame.
So what they did was having everything exported in a folder (as a sequence of images) and then did what they wanted with it. (In this case put them all together with ffmpeg to make a video)
They used a plugin, I do not know if it can be tweaked not to make 360 captures but the built-in "take screenshot" from UE4 could work for you.
More specifically to what you need, you could probably store all positions/transform in an array, loop over it when you want to make the screenshot. Each step, you place your Camera at the specific position, make sure it is the current active camera to change the "view" and take a screenshot.
Taking screenshots and setting parameters such as export folder, resolution etc. ... can be called via console commands and console commands can be executed from code or blueprint using the "execute console command" node (there is an example in the article).
I hope it helps.
I think the best bet you have is rendering camera to a texture.
this way you can have multiple inactive camera then iterate through them, activate them, capture their screen view and going to the next one.
for basic tutorial have a look at
https://www.youtube.com/watch?v=a9iho861SlY

Allow content to display outside of LogicalDisplay Rect AOSP/LineageOS

I'm working on adding second screen functionality to AOSP for the LG V20.
So far, I've managed to set up the offsets so normal content doesn't overflow into the second screen area, and I've added the second screen window type (SIGNBOARD). The offsets are managed in LogicalDisplay.
For a lot of this, I've been following how LG originally did it (in Android 7.0, so things are slightly different on 7.1). The problem I have now is that nothing displays in the second screen area: I see some stuff LG did involving SurfaceControl, but that doesn't seem to be the actual solution, and I'm worried it might be in the native code.
I've tried Googling, but this doesn't seem to be documented anywhere, at least nowhere I could find.
So the question becomes: How can I force content to display outside of the bounds of the LogicalDisplay area?
These are the changes I've made so far: https://github.com/zacharee/android_frameworks_base/commit/cec4839c8cb1396810ce65d7ad9cae094f363ac4

Firebreath NPAPI plugin rendering video to top level browser window (HWND)

I am working on a audio/video rendering plugin that is using FireBreath and we have a need to get HTML elements to overlay on top of the video. I am aware that to do this I need to use the windowless mode in FireBreath. However since I am using DirectX to render the video I cannot initialize DirectX with the HDC handle (it requires a HWND) that I get when I am instructed to render in windowless mode.
Also for other software security reasons I cannot render the video to an off-screen surface then Blt the bits to the HDC.
The alternative I was trying to accomplish is to use the Hardware Overlay feature in DirectX and use the browser's TOP level HWND to initialize DirectX, then use the HDC and coordinates to tell directX where in the TOP browser window to render the video frame. And render it directly to the top parent browser window.
I have tired a proof of concept, but I am seeing my video frames getting erased quite often after I draw them and thus the video appears to be flickering. I am trying to understand why that might be and I am wondering if this is not a viable solution given my parameters.
Also I am wide open to suggestions on how to accomplish this given my constraints.
Any help would be greatly appreciated!
In the FireBreath-dev group, John Tan wrote:
As what I know, you practically have no control precisely when the screen is going to draw. What can only be done is:
1) Inform the browser to repaint by issuing the windowless invalidatewindow
2) browser draw event arrives with the hdc. Draw on the hdc
John is completely correct. In addition, the HDC could potentially (perhaps likely will) be different each time your draw is called. I don't know of anyone who has successfully gotten directx drawing using windowless mode, and you have absolutely no guarantee that what you are doing will ever work as even if you got it working the browser may change the way or order that it draws in in a way that would break it.
You might want to look at the async surface API; I don't know which browsers this works on but I suspect likely only Firefox and IE. It was implemented in this commit.
I haven't used this at all, so I can't tell you how it works, but it was intended to solve exactly the problem you're describing. Your main issue will be browser support. What documentation there is is here.
Hope this helps