Re: Noesis documentation and few question about 2.1.0 verison (C++)
Could you try with the latest beta? (b12). We fixed an issue related to the memory manager.
Re: Noesis documentation and few question about 2.1.0 verison (C++)
Yes, now memory issue dissapear. But I get another error, but maybe it is my bad code.
I use Dx9 render for Urho and this is how I initialize Noesis:
This is error:
I use Dx9 render for Urho and this is how I initialize Noesis:
Code: Select all
void MyNoesisINI()
{
auto logHandler = [](const char*, uint32_t, uint32_t level, const char* channel,
const char* message)
{
if (strcmp(channel, "") == 0)
{
// [TRACE] [DEBUG] [INFO] [WARNING] [ERROR]
const char* prefixes[] = { "T", "D", "I", "W", "E" };
const char* prefix = level < NS_COUNTOF(prefixes) ? prefixes[level] : " ";
printf("[NOESIS/%s] %s\n", prefix, message);
}
};
Noesis::GUI::Init(nullptr, logHandler, nullptr);
auto xaml = Noesis::GUI::LoadXaml<Noesis::FrameworkElement>("Main.xaml");
noesis_global_view = Noesis::GUI::CreateView(xaml.GetPtr());
noesis_global_view->SetIsPPAAEnabled(true);
Noesis::Ptr<NoesisApp::RenderContext> device = NoesisApp::FindBestRenderContext(); // Line 109
noesis_global_context->SetVGContext(device->GetDevice()->GetVGContext()); // noesis_global_context is Noesis::RenderDevice
noesis_global_view->GetRenderer()->Init(noesis_global_context.GetPtr());
}
Code: Select all
NoesisApp.dll!68b2d18c() Unknown
[Frames below may be incorrect and/or missing, no symbols loaded for NoesisApp.dll]
> Urho-Noesis_d.exe!MyNoesisINI() Line 109 C++
Urho-Noesis_d.exe!MyApp::Start() Line 474 C++
Urho-Noesis_d.exe!Urho3D::Application::Run() Line 79 C++
Urho-Noesis_d.exe!RunApplication() Line 684 C++
Urho-Noesis_d.exe!WinMain(HINSTANCE__ * hInstance, HINSTANCE__ * prevInstance, char * cmdLine, int showCmd) Line 684 C++
[External Code]
Code: Select all
> Urho-Noesis_d.exe!MyNoesisINI() Line 109 C++
- device {mPtr=0x00000000 <NULL> } Noesis::Ptr<NoesisApp::RenderContext>
- mPtr 0x00000000 <NULL> NoesisApp::RenderContext *
- Noesis::BaseComponent <struct at NULL> Noesis::BaseComponent
- Noesis::BaseRefCounted <struct at NULL> Noesis::BaseRefCounted
- Noesis::BaseObject <struct at NULL> Noesis::BaseObject
__vfptr <Unable to read memory> void * *
- mRefCount {...} Noesis::Atomic<int>
- Noesis::Atomic32<int> {val=??? } Noesis::Atomic32<int>
val <Unable to read memory>
logHandler void <lambda>(const char * __formal, unsigned int __formal, unsigned int level, const char * channel, const char * message){...} MyNoesisINI::__l2::void <lambda>(const char *, unsigned int, unsigned int, const char *, const char *)
+ xaml {mPtr=0x00000000 <NULL> } Noesis::Ptr<Noesis::FrameworkElement>
Re: Noesis documentation and few question about 2.1.0 verison (C++)
I rebuild Urho for OpenGL and I got this error:
My code:
If you are interest, I can provide my full source code project for Urho with Noesis. Urho Project working without Noesis.
Btw. I discover that if I use this: error dissappear from previous post (Line 109). Then other my code in previous post I think is bad.
Code: Select all
> ig4icd32.dll!513b7c40() Unknown
[Frames below may be incorrect and/or missing, no symbols loaded for ig4icd32.dll]
[External Code]
Code: Select all
auto xaml = Noesis::GUI::LoadXaml<Noesis::FrameworkElement>("Main.xaml");
noesis_global_view = Noesis::GUI::CreateView(xaml.GetPtr());
noesis_global_view->SetIsPPAAEnabled(true);
noesis_global_device = NoesisApp::GLFactory::CreateDevice();
noesis_global_view->GetRenderer()->Init(noesis_global_device.GetPtr());
Btw. I discover that if I use this:
Code: Select all
NoesisApp::Launcher::RegisterAppComponents();
Re: Noesis documentation and few question about 2.1.0 verison (C++)
That's for registering AppFramework components (Application, Window, RenderContext). You don't need that for integrating with an existing engine. Please, have a lookt at 'IntegrationGLUT' sample. Thanks!Btw. I discover that if I use this:error dissappear from previous post (Line 109). Then other my code in previous post I think is bad.Code: Select allNoesisApp::Launcher::RegisterAppComponents();
Re: Noesis documentation and few question about 2.1.0 verison (C++)
Yes, I followed IntegrationGLUT sample, and what happend I described in my last previous post.
Re: Noesis documentation and few question about 2.1.0 verison (C++)
I assume our IntegrationGLUT is working fine, right? Then the only thing you need to change is the RenderDevice implementation. If your integration doesn't work then a) start from IntegrationGLUT and do changes step by step b) pay attention to every message you receive in the logging handler. Thanks!
Re: Noesis documentation and few question about 2.1.0 verison (C++)
Hmm, I don't try compile it (I'll try it tomorrow), but I played with integrationGLUT.exe and it worked.
What means RenderDevice implementation? That means, I need write own GLRender.h and .cpp? Maybe I am don't understand this RenderDevice, but some library like ImageMagick or similar like libraries have some buffer. I can obtain this buffer and add it in to SDLTexture(as example) and then display it for exmaple. Is the RenderDevice something similar? If you have time, please explain.
What means RenderDevice implementation? That means, I need write own GLRender.h and .cpp? Maybe I am don't understand this RenderDevice, but some library like ImageMagick or similar like libraries have some buffer. I can obtain this buffer and add it in to SDLTexture(as example) and then display it for exmaple. Is the RenderDevice something similar? If you have time, please explain.
Re: Noesis documentation and few question about 2.1.0 verison (C++)
Wanderer, I highly recommend you to build Urho3D (and remove all Urho3D's default UI) as a library and then implement Noesis when developing the application (or game).
Also, you said you are using dx9 for Urho3D; in that case you'll need to write your own RenderDevice implementation.
After you are set with the graphics api (OGL, DX, etc) you initialize noesis with Urho3D's graphics context;
Also, you said you are using dx9 for Urho3D; in that case you'll need to write your own RenderDevice implementation.
After you are set with the graphics api (OGL, DX, etc) you initialize noesis with Urho3D's graphics context;
Re: Noesis documentation and few question about 2.1.0 verison (C++)
I compile IntegrationGLUT sample, and it working without problem.
And now I discover, xaml files are not loaded. I don't use the XamlProvider because I don't know how to use it (there are some examples but without understand), there was SetResourceProvider (in Noesis 2.0.2) and now it is changed.
You mean Urho as dll ?Wanderer, I highly recommend you to build Urho3D (and remove all Urho3D's default UI) as a library
I now use OpenGL for Urho (I change it because there is some RenderDevice for GL implementation).Also, you said you are using dx9 for Urho3D; in that case you'll need to write your own RenderDevice implementation.
And now I discover, xaml files are not loaded. I don't use the XamlProvider because I don't know how to use it (there are some examples but without understand), there was SetResourceProvider (in Noesis 2.0.2) and now it is changed.
Re: Noesis documentation and few question about 2.1.0 verison (C++)
The change is that now instead of setting the three providers (Xaml, Texture and Font) in one shot, you can set them separately. More information about resource providers.And now I discover, xaml files are not loaded. I don't use the XamlProvider because I don't know how to use it (there are some examples but without understand), there was SetResourceProvider (in Noesis 2.0.2) and now it is changed.
Who is online
Users browsing this forum: No registered users and 13 guests