I'm just trying to run some samples, I ceate a new project and build a ui.layout of my own, in ui.layout there is a TaharezLook/FrameWindow named "demo", everything is OK except that, if I scale up the main window, and move the "demo" window, there will be residue shadows, the shadows don't show up in the original area(before scale up), how to solve this problem?
There is still one more problem, I modify the CEGuiGLFWSharedBase::d_newWindowWidth and CEGuiBaseApplication::s_defaultWindowWidth, but it doesn't work, the window remains the same size no matter what value newWindowWidth is of.
(This one is because the compiler replace the static const d_newWindowWidth with its old value)
Waiting for a solution, and thanks.
ps: when I move my cursor to the edge of the window, all the shadows dispear.
here is a snapshot of the problem:
http://v2.freep.cn/3tb_140523213707l3w2512293.jpg
[Solved] Residue Shadow when moving a window
Moderators: CEGUI MVP, CEGUI Team
[Solved] Residue Shadow when moving a window
Last edited by felixbrot on Fri May 23, 2014 14:12, edited 3 times in total.
Re: Residue Shadow when moving a window
System::notifyDisplaySizeChanged()
Is this function being called on those size changes?
Is this function being called on those size changes?
CrazyEddie: "I don't like GUIs"
Re: Residue Shadow when moving a window
Ident wrote:System::notifyDisplaySizeChanged()
Is this function being called on those size changes?
yes, the function is called. I didn't change much, the code following is from the sample. Comparing the original sample, I remove the 17 demos and made a ui.layout instead, these changes are mostly in SamplesFramework.cpp.
while (!d_sampleApp->isQuitting() &&
glfwGetWindowParam(GLFW_OPENED))
{
if (d_windowSized)
{
d_windowSized = false;
CEGUI::System::getSingleton().
notifyDisplaySizeChanged(
CEGUI::Sizef(static_cast<float>(d_newWindowWidth),
static_cast<float>(d_newWindowHeight)));
}
drawFrame();
}
Re: Residue Shadow when moving a window
You are not supposed (it is not intended this way) to build your application based on the SamplesFramework, although you can do that I guess. At best you should extract code from there but write your own application otherwise.
Are you sure you render correctly including clearing the FBO?
Do you ever change OpenGL states?
Are you sure you render correctly including clearing the FBO?
Do you ever change OpenGL states?
CrazyEddie: "I don't like GUIs"
Re: Residue Shadow when moving a window
Ident wrote:You are not supposed (it is not intended this way) to build your application based on the SamplesFramework, although you can do that I guess. At best you should extract code from there but write your own application otherwise.
Are you sure you render correctly including clearing the FBO?
Do you ever change OpenGL states?
I'm not sure, but I think I did'nt change any codes on those things.
I don't know much how to build one CEGUI programe, so I start with modifying sample project, it's a new project and I copy some cpp from the sample, I load my ui.layout in SamplesFramework::initialise().
If I start my window with 800*600 and then scale it up to 1280* 720, the 800*600 area always(before and after scaling) works fine, shadows only appear in the extended area, and if I move the cursor to the edge of any window, the shadows disappear.
Now I have to put a big window on the background, and move other windows in it.
The 800*600 area and area in a window are fine, only the extended area without any window on it doesn't refresh in time.
I uploaded a pic of the problem, I hope it will help find out where I did wrong.
Re: Residue Shadow when moving a window
I create a new empty project, and copy only necessary codes to create my window, it works all good.
But I'm still cofusing, what makes it wrong in my old one.
But I'm still cofusing, what makes it wrong in my old one.
Re: Residue Shadow when moving a window
Thank you all, I've found the reason. The code below is not necessary in my project, after I comment them, everything works fine now.
CEGUI::System::getSingleton().getDefaultGUIContext().
subscribeEvent(CEGUI::RenderingSurface::EventRenderQueueStarted,
CEGUI::Event::Subscriber(&CEGuiBaseApplication::sampleBrowserOverlayHandler,
this));
CEGUI::System::getSingleton().getDefaultGUIContext().
subscribeEvent(CEGUI::RenderingSurface::EventRenderQueueStarted,
CEGUI::Event::Subscriber(&CEGuiBaseApplication::sampleBrowserOverlayHandler,
this));
Who is online
Users browsing this forum: No registered users and 16 guests
