oshgui's People
Forkers
luk1337 wildbob samshine carlhuth germankingyt anonvodka yuaom fadetrack aktel zanzo420 killvxk fcccode fengjixuchui zk2013 sector1337-zz hypn4 zh4x fysu stevefan1999-personal infistar alehacksp jncfa gamefortech123 ghostnaix learning-hide therdel sector1337 binguoa qazwar nelsonbighead unknown4now wegs96 hacktualoshgui's Issues
Fail to compile library with latest c++ standard
Error: error C3861: "obj_": identifier not found from here. Any fix for this?
Crashing when moving form
I can accurately reproduce this crash every time by moving the form around for 3-5 seconds.
Crash occurs on https://github.com/KN4CK3R/OSHGui/blob/master/Controls/Control.cpp#L513
geometry_ virtual table is nullptr?
I'm not quite sure how to fix this issue. I can provide more information if needed.
Edit: This might be an issue that is caused by some of my changes to OSHGui, I'll continue looking into it
OSHGui with CSGO surface flickering
So I'm currently trying to implement OSHGui using CSGO's surface.
I found your implemenation from some years ago.
However my menu is just flickering when enabled, here is a video to show it better.
I'm initializing OSHGui like so:
std::vector<OSHGui::Drawing::FontPtr> m_fonts;
OSHGui::Application::Initialize(std::make_unique<CSGORenderer>(interfaces::surface, interfaces::engine));
this->m_fonts.resize(renderer_fonts::FONT_MAX);
this->m_fonts[verdana_7] = std::make_unique<CSGOFont>(interfaces::surface, "Verdana", 7);
To draw the GUI I hook PaintTraverse and call it in MatSystemTopPanel.
void renderer::draw()
{
this->m_render_target = this->get_renderer().GetDefaultRenderTarget();
if (!this->m_render_target)
{
return;
}
this->m_geometry = this->get_renderer().CreateGeometryBuffer();
if (!this->m_geometry)
{
return;
}
this->m_render_target->Draw(*this->m_geometry);
}
I'm probably doing something wrong here and I would really appreciate help.
Kind regards.
unresolved external symbol for Drawing::Direct3D9Renderer
I'm new to OSHGui. I'm trying to follow the examples in your website.
I first compiled all external dependencies. Then I compiled the static library.
Then I included the source files and linked the library to my project.
Some class and function names seem to be changed with current lib, compared to the examples on your website. I've (hopefully) fixed these correctly. All compiler errors are gone in Visual Studio. However I still can't compile, im getting this linker error.
Thanks in advance
Still getting mouse inputs while the window is not visible
It still handling the mouse/keyboard input while the form is not visible, is that bug or im just using it wrong ?!
Missing SimpleImageLoader.hpp and ft2build.h
Can't set viewports
Hi!
I ran into an issue when using the current OSHGui renderer. I'm currently calling SetViewport( ) to try and clip an area, but it seems not to work.
The renderer I'm using can be found here: https://github.com/EternityX/DEADCELL-CSGO/blob/master/deadcell/oshgui/renderer.cpp
My only addition to that renderer is the get_device( )
function that simply returns the device.
Here is my code:
// store original viewport to restore later
D3DVIEWPORT9 original_viewport;
g_renderer.get_device( )->GetViewport( &original_viewport );
// clip at position (100, 100), with size (50, 50)
D3DVIEWPORT9 clip = { 100, 100, 50, 50 };
g_renderer.get_device( )->SetViewport( &clip );
g_renderer.filled_rect( OSHGui::Drawing::Color::White( ), 100, 100, 500, 500 );
// restore
g_renderer.get_device( )->SetViewport( &original_viewport );
Is there any way anyone could point me into the right direction, on how I could/should go about this?
Thanks ๐
OSHGui for DirectX 7?
So i'm currently working on a menu for the game "Gothic 1", which is relying on DirectX 7 for drawing.
Unfortunately, other UI librarys such as ImGui or nuklear do not support rendering using DirectX7.
However, by simply looking at this UI, it should (Direct3D7Renderer).
So i simply downloaded the main branch, compiled the /Dependencies and attempted to rewrite the OSHGui Hook Dll with DirectX7 Support.
However, that does not quite work.
For some reason this code:
// 1. create our renderer, Direct3D9 in this case
-> auto renderer = std::make_unique<Direct3D7Renderer>(device);
// 2. and initialize the OSHGui with it
Application::Initialize(std::move(renderer));
breaks every single time. It won't let me compile the code with the following error message:
"Severity Code Description Project File Line Suppression State
Error LNK2001 unresolved external symbol "public: __thiscall OSHGui::Drawing::Direct3D7Renderer::Direct3D7Renderer(struct IDirect3DDevice7 *)" (??0Direct3D7Renderer@Drawing@OSHGui@@QAE@PAUIDirect3DDevice7@@@z) OSHGui Hook DLL C:\Users\XXXX\Desktop\OSHgui\OSHGui-master\Projects\VS2019\OSHGui_Hook_Sample.obj 1
"
Would you be able to provide me a solution for using the Direct3D7Renderer?
I really would like to use a UI that i can make work internally.
I am trying the hardest to avoid external and also using the GDI Implementation of ImGUI, as it is eating performance alot.
Thanks.
DDS Image Support
As far as I know, we can use BMP, JPEG, GIF, PNG, TGA, ICO image files with OSHGui.
* Loads an image from a file. (BMP, JPEG, GIF, PNG, TGA, ICO)
I have already been using jpeg/png without any issues.
Is it possible to load an image in .dds format somehow?
.exe app
Can I use oshgui for exe app? Something like cheat loader? Thanks for answer!
[SUGGESTION] Update FreeType from `2.5.2` to `2.10.1`
The actual FreeType library is quite old, there is a number of bug fixes, security fixes and general improvements that have been released since then.
This change will bump our FreeType version from 2.5.2
to 2.10.1
.
No such interface supported error from D3DX11CreateEffectFromMemory
So, i have added some debug messages to understand what goes wrong when injecting the DLL
Direct3D11Renderer.cpp:
HRESULT hr = D3DX11CompileFromMemory(shaderSource, sizeof(shaderSource), nullptr, nullptr, nullptr, nullptr, "fx_5_0", 0, 0, nullptr, &blob, &errors, nullptr);
if (FAILED(hr))
{
std::string msg = "D3DX11CompileFromMemory failed: ";
if (errors)
{
msg += static_cast<const char*>(errors->GetBufferPointer());
errors->Release();
}
else
{
msg += "Unknown error";
}
throw Misc::Exception(msg);
}
hr = D3DX11CreateEffectFromMemory(blob->GetBufferPointer(), blob->GetBufferSize(), 0, device.Device, &effect);
if (FAILED(hr))
{
std::string msg = "D3DX11CreateEffectFromMemory failed: ";
LPVOID lpMsgBuf;
FormatMessage(
FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
NULL,
hr,
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
(LPTSTR)&lpMsgBuf,
0, NULL );
msg += (char*)lpMsgBuf;
LocalFree(lpMsgBuf);
throw Misc::Exception(msg);
}
Getting message with "No such interface supported" error. What can be the issue?
IDE: VS2019
DXSDK: Microsoft DirectX SDK (June 2010)
Platform: Win11x64
Replacing with new form
How can I replace form with a new one after creating and running an instance.
Style issues
If I set DefaultColor.BackColor(Drawing::Color(255, 245, 208, 255)), It will give me a white window.
Any ideas to fix ๐ญ
auto form = std::make_shared<OSHGui::Form>();
form->SetName("form1");
form->SetText("Form1");
Drawing::Style theme;
theme.DefaultColor.ForeColor = Drawing::Color(255, 31, 97, 106);
theme.DefaultColor.BackColor = Drawing::Color(255, 245, 208, 255);
#define MakeTheme(control, color1, color2) theme.SetControlColorTheme(control, Drawing::Theme::ControlTheme(color1, color2))
form->ApplyStyle(theme);
[SUGGESTION] Support dynamic resizing
Hello,
First of all, thank you this great library, I have keep track of your project since 2011 and this is near perfect for my needs.
I just wanted to say that it would be nice to implement a way to dynamically resize windows, and elements (such as groupboxes).
We would just click and drag on lower right / lower left corner to resize.
Errors with OSHGui
Two more errors(in my project)
Originally posted by @CovERUshKA in #12 (comment)
Compiling Sample Project (to test)
Error LNK1181 cannot open input file 'jsoncpp.lib' OSHGui DLL
Error LNK1181 cannot open input file 'jsoncpp.lib' OSHGui Static Library
Error LNK1181 cannot open input file 'oshgui.lib' OSHGui Sample
im getting these errors when compiling solution any help?
Unicode Characters
Does oshgui doesn't support Unicode characters like china?
Crashing when trying to draw a text
So every time I try to draw a font with the geometry buffer and using "DrawString" I'm just crashing an getting an exception.
I was able to track it down to here
The function is referenced here
When the renderer tries to create a texture (in my case a font) I'm crashing at the if condition.
The weird thing is that every paramter I pass into "D3DXCreateTexture" is valid and all other things work, like trying to draw a rectangle or the menu without any font.
I'm creating fonts like so:
this->m_fonts.push_back(OSHGui::Drawing::FontManager::LoadFont("Verdana", 12.f, true));
and I draw the text like so:
OSHGui::Drawing::Graphics graphics(*this->m_geometry);
graphics.DrawString(buf, font, shadow_color, x, y);
I'm pretty I'm missing something (probably with FreeType) but I just can't find a solution for this.
Any help, or push in the right direction would be very much appreicated.
Dynamically 'anchoring' elements is broken due to mistake in the code
Take a look at this these lines of code (line ~160-180 in Control.cpp, Control::SetSize
):
size_ = size;
OnSizeChanged();
Invalidate();
const auto offset = size_ - GetSize();
for (auto &control : controls_)
{
const auto anchor = control->GetAnchor();
if (anchor != (AnchorStyles::Top | AnchorStyles::Left))
It changes the member variable size_
and then calculates offset, which is obviously going to be {0, 0}. This breaks dynamic resizing of the parent controls, as the children will not be correctly placed after the resize.
EDIT: fixing this would be as simple as doing size - GetSize()
instead of size_ - GetSize()
Can't remove controls
I have a basic form, consisting of few pictureboxes and labels. I added a button and I'm doing this in it's click handler:
this->RemoveControl(label_CurrentPage);
The code is being executed, however, the label is not removed. No error, nothing.
After removing, I'm also iterating over GetControls() to check the current controls and it's still there.
I cant Compiling via vs 2019 oshgui :(
How i can compile via vs 2019 ? i opened project but cant compiling
OSHGui Externally?
I plan on using OSHGui in one of my upcoming projects. Is OSHGui viable externally? Even outside of cheat development? It's beautifully written but I have no idea where to start as everyone is using it internally for CSGO.
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.