Screenshot of directX app without window - directx

I'm running DirectX application on the server (Windows Server 2003) and it does not have window (normally, running on PC, it has window). The issue is that I want to take screenshot of it from it (and save it to the png picture). When running on PC, this is working:
Surface backBuff = Device.GetBackBuffer(0, 0, BackBufferType.Mono);
SurfaceLoader.Save(fileName, ImageFileFormat.Png, backBuff);
But on server, the only thing I'm given is black picture (with right size).
Is it possible to take screenshot of directX app without window?
Thank you very much for answers

The solution is quite simple: running the app from script that is running under another user than IIS.

Related

Abaqus shows axes with different scaling

I am using Abaqus and performing a simulation in a cube with some particles inside. I ran a the simulation using a Python script, for which results look fine. So I saved some images from the Visualization module showing the strain distribution in the cube. A day later, I ran the same Python script but changed one parameter (maximum displacement applied). But now, when I see the results in the Visualization module, the cube looks like a rectangular prism. So I guess there is some sort of scaling applied to the axes. Also, this scaling is applied globally. If I go to Part or Assembly or Mesh, I will see a rectangular prism instead of a cube. I don't know how this happened if my simulation is done using the script and I did not set any changes in how the results are displayed nor I did this when exporting the images.
I have tried to look for options that are related to the scaling of the axis within Abaqus without success. I also tried to open and close Abacus in case it was something particular of the simulation, but I still see the scaling in the axes. Even if I open the odb file from which I got the images that actually show the cube, now show a rectangular prism.
Something that gave me some hope is that in the visualization "Common Plot Option", in the tab Other, in the tab Scaling, there is an uncheck box with the option "Scale coordinates". If I check the box ans set all coordinates to 1, there are no changes. If I know what the scaling factor is, I could just set the sclaing to cancel out that scaling factor. But again I don't know how it was applied.
UPDATE: I think the issue solved by itself. I have been working remotely and connecting to a Windows machie with Abaqus via the Microsoft Remote Desktop (from a Mac mini). It seems the issue appears when I use Abaqus from the remote desktop. After closing Abaqus in that Windows machine, then using it in a second Windows machine, then back again in the first Windows machine now I see the cube as a cube. I guess the cause is the remote desktop because some software behaves differently and the visualization software Paraview just won't open.
UPDATE 2: I confirmed the issue indeed happens when connecting remotely with Microsoft Remote Desktop from my Mac computer. The issue happens even when using a Python script for generating the figures to avoid opening the user interface. When running the script directly on the computer figures are fine (i.e., the cube looks like a cube). Not sure if when connecting remotely with Microsoft Remote Desktop from a Windows computer the issue will be present.

Windows phone emulator turns grey after several seconds after the program is turned on

I have a problem with Windows Phone emulator in VS13, I am developing a quiz game.
When I run my program, virtual machine turns on, everything goes fine, after that it builds my program and finally it works, but only for several seconds.
I can do whatever I want during these seconds, I've even managed to start the game, but after 7-8 seconds the emulated phone screen turns gray.
I've checked what happens with the virtual machine in Hyper-V manager, it seems to stop due to lack of memory, am I right with this conclusion?
And if I'm right, what can I do to solve this problem with memory apart from upgrading my PC? :)
I'm using Windows 8 installed as a virtual machine via VMWare Workstation.
Here are two screenshots of my gray screen - one is WF emulator and the second one is the same screen, but opened via Hyper-V manager (it says "not enough memory" in the bottom line).

How to change Opencv image viewer?

I have installed OpenCV on my desktop and laptop which they have Ubuntu 14, and i have some problem with its image viewer.
First of all when i type :
./facedetect --cascade="/usr/local/share/OpenCV/haarcascades/haarcascade_frontalface_alt.xml" --nested-cascade="/usr/local/share/OpenCV/haarcascades/haarcascade_eye.xml" --scale=1.5 [address of my image]
It shows my image with its image viewer , but it isn't resizabe on my desktop and it don't show control buttons at top of it on my laptop.
How can i fix these problem or can i change its image viewer ?
Opencv uses in many demo applications its own GUI (highgui), its features are limited and are platform-dependent. For example, I think that the "auto-zoom" feature that enables you to see the pixel values is available only on Windows. And, although recent versions added some Qt support to add somes features (buttons,...), the app has to be build to enable these features, and this is probably not the case in your example.
However, you can always edit the code of these apps (here, the facedetect app) so that it just saves the images on disk, instead of showing them on screen. Then rebuild. Or add yourself the buttons you want, see the manual.

Jmyron and Windows 8

I am running into hardware issues that perhaps someone here knows a workaround. I am using a PC and windows.
For several years I have been making interactive installations using video tracking: the Jmyron library in Processing, which has functioned marvelously for me. I use this set up: cctv type microcameras to a multiplexer, the I digitize this signal via a firewire cable to a pci card. Then Processing reads these quads (sometimes more) as a single window, and it has always worked (from windows xp all the way to 7). Then comes windows 8: Processing seems to prefer the built-in webcam to the firewire bus. On previous version of windows, the firewire bus would naturally override the webcam, provided I had first opened a video capture in Windows Maker, and then shut it down before running the Processing sketch. In Windows 7, which had no native video capture software, I used this great open source video editor called Capture Flux. The webcam never interfered. With Windows 8, no matter what I try, Processing defaults to the webcam, which for my purposes is useless. I have an exhibition coming up real soon, and there is no way I am going to have the time to rewrite all that code for Open CV or other newer libraries.
I am curious if anyone has had similar problems, found a work around? Is there a way of disabling the webcam in Windows 8 (temporarily of course, because I need it to be operational for other applications), or some other solution?
Thank you!
Try this:
type "windows icon+x" choose device manager (or use run/command line: "mmc devmgmt.msc")
look for imaganing devices, find your integrated webcamera
right click on it and choose disable - now processing should skip the device.
Repeat the steps to reenable the device.
Other solution would be using commands in processing:
println (Capture.list()); (google it on processing.org) this way you will get all avaliable devices and you can choose the particular one based on its name.
Hope this helps.

Getting monitor output during bootup

I'm in an unusual spot. The built in screen on the laptop I'm using right now is broken so bad I can barely see anything besides random flickering lights on it. Because of that, I got and plugged in a monitor to my laptop. This moniter works fine once Windows 7 has already loaded.
The issue is: I'm trying to open the BIOS/boot menu to live boot off of my USB, but I can't see anything. How do I make it so that I get visual output on my monitor early enough to open the BIOS/boot menu?
If it's a Dell laptop, try FN&F1 or F1
Dell Forum

Resources