Comments (11)
Not sure if this would involve being able to overlay native WPF or Windows Forms controls? I have just asked a question regarding it, based on your work http://stackoverflow.com/questions/26611170/embed-button-control-into-existing-direct3d-application
Thanks for sharing!
from direct3dhook.
I am trying to understand and finish implementing the ImageElement in your Overlay engine, to draw with Direct3D 11 a 2D red rectangle texture as achieved with Direct3D 9 here thanks to you - #27
However, I am pretty stuck due to my lack of knowledge.
Firstly I edited the ImageElement class like this:
public class ImageElement:Element
{
// public System.IO.Stream ImageStream { get; set; }
public string ImageLocation { get; set; }
public float Alpha { get; set; }
public System.Drawing.PointF Location { get; set; }
}
Then I instantiated one at https://github.com/spazzarama/Direct3DHook/blob/master/Capture/Hook/DXHookD3D11.cs#L367
var imageElement = new ImageElement();
string dir = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
string filename = dir + @"\gridW1024H768.jpg";
imageElement.ImageLocation = filename;
imageElement.Alpha = 1;
imageElement.Location = new PointF(50, 50);
overlay.Elements.Add(imageElement);
But how do you then initialize the texture here https://github.com/spazzarama/Direct3DHook/blob/master/Capture/Hook/DX11/DXOverlayEngine.cs#L110
else if (imageElement != null)
{
// TODO: load image element into texture
}
And finally how do you actually draw it here https://github.com/spazzarama/Direct3DHook/blob/master/Capture/Hook/DX11/DXOverlayEngine.cs#L147
else if (imageElement != null)
{
}
from direct3dhook.
I think I have written the ImageElement for D3D 11 in another project, I'll see what state it is in and bring across to this project if all good.
EDIT:
There's a few changes I made to the DX11 DXSprite, DXOverlayEngine, and a few additional classes. I'll look to getting these committed in the next week.
from direct3dhook.
thanks ahead!
from direct3dhook.
these improvements do not exist on any other branch do they?
from direct3dhook.
any luck with the commits Justin?
from direct3dhook.
I've mostly finished putting it together from a number of projects here, unfortunately I'm busy for the next week or so, will try to get it sorted after then.
from direct3dhook.
I've got it all together, will try to commit before next week.
from direct3dhook.
Image overlay support for D3D11 has been committed, this also has preliminary support for GPU image resizing. ddb3096
from direct3dhook.
thanks ever so much, I'll give it a whirl soon!
from direct3dhook.
Closing as API now added to display overlay. Other improvements to be in new issues.
from direct3dhook.
Related Issues (20)
- Attempt to update image element every frame in d3d11? HOT 4
- Memory leak in hooked application HOT 7
- Question: Interactive UI Overlay HOT 2
- Strange exception HOT 1
- Failed injection in League of Legends HOT 9
- Error in InitialiseHook: System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception. HOT 1
- can I use this for simulate dirext input for games?
- Сhange of path *.dll
- cann't inject wow,error code:93913088 HOT 1
- Screenshot background window HOT 3
- Black screen when capturing from multiple clients HOT 8
- Captures Complete but Do Not Display, Overlay Does Not Display
- Region settings not correct. HOT 1
- Memory leak on screenshot HOT 5
- Memory leak on image draw HOT 2
- I need some help HOT 31
- Memory leak after unreasonable ammount of DrawOverlayInGame calls and large ImageElement HOT 7
- When creating an ImageElement with the "Bitmap bitmap" override, DXHookD3D11 throws an exception HOT 1
- What is CaptureInterface.StartRecording()? HOT 1
- Memory leakage HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from direct3dhook.