TurboBadger full integration

I had another thread posted in “dev talk” section because there were some issues that I needed to resolve, but it’s all fixed now.

edit final: new repository created https://github.com/Lumak/Urho3D-1.4-TurboBadger


Features

  • no unique shader required
  • no unique render path required
  • no unique graphics settings required
  • uses Urho3D’s default UIBatch render process
  • delivers TurboBadger’s batch data in its format, so it pumps data as fast as Turbo Badger can send them

Image (Turbo Badger demo shown in Urho3D):

1 Like

I just been informed that this code is not compatible with the latest Urhod3D master branch, as reported by Hevedy:

I’m still on 1.4 and will not be merging with the master branch anytime soon. I hope there are others who can help him with his build errors. I’ll try to help him with 1.4 linking problem.

I think it might be a good idea to wait for the 1.5 release before adopting to the changes.

added a download link to the integration, including tb and its data.

Why not make a public repository?

I don’t see any reason why I should create a repository for this. I don’t see anyone interest in this judging by the number of comments on this thread (only you commented about waiting), so I’m just going to provide a public downloadable link.

A repo takes a minute to setup and makes it so much easier to look at the code. Even if there aren’t any comments to “show interest”, it doesn’t mean that people will be any less interested in your work. For example, a libGDX demo that I created and posted on the site only got a few comments, but has racked up well over 20k downloads.

Github (or really any public source control host) is a great place to keep a portfolio of your work if you plan on applying to developer positions.

I’ll comment :smiley: You did an awesome work ! I can’t see the reason why devs won’t implement this as an official subsystem ? Looks professional , there are way more widgets , and could boost the editor’s appereance and it would attract more users.

Count me in! I would agree on this as well. :slight_smile: It is another good UI framework option and setting up a repo where you can improve and fully integrate it is a big plus! I’m also thinking of using this as an alternative to Qt, due to its hefty payload.

Btw, thanks again for the download links and assistance Lumak! :smiley:

In terms of “higher end” editor, one thing TurboBadger needs is support for multiple top level windows. Being able to drag windows in and out of tabs would also be huge. Urho would also have to support multiple top level windows (probably with styling, as default style isn’t good for a an editor window like this)

  • Josh

Trying to figure out the interest of people through the comments here might be really misleading… Believe me, I spent a considerable amount of my time last month (January 2016) trying to implement Turbo Badger as a stand alone library to Urho3D and guess what? I achieved it using your Urho3D_TurboBadger implementation, the exact same one you pulled from github. I had a local copy of the last snapshot and was looking for the best time to tinker with it.
When I realized that jenge and the folks at Atomic Game Engine (which bred from Urho3D) had Turbo Badger Integrated, I was more than motivated to give it a shot.

I’ve only tested this on Windows Machine, OpenGL build was great, D3D9 was good but D3D11 had a bit of rendering issues (and I’m not really good at all those graphic pipeline stuffs :unamused: ) What consumed a vast portion of my time and mental energy was how to integrate TB as part of other Third Party library and how its interface would be wrapped and exposed for use in Urho3D. Is it going to replace the existing UI system or will it be part of custom UI structure that would be implemented in Urho3D?

So… Quite a lot of people are interested in this project, even though some of us are yet to comment :wink:

I definitely want an external TurboBadger integration that doesn’t modify Urho3D, so there’s no need for a fork to maintain.

Nice, if only we can do so well with games that we create.

Thank you. TurboBadger does have nice UI graphics.

Yeah Qt is also LGPL, and you’re welcome.

I haven’t look into creating an editor, but I agree that having multiple top level windows in any editor would be beneficial.

It’s great to hear that someone is making use of my repository from last year. I haven’t built D3D11 yet to see what’s going on with that, but I’ll attempt to build it and see sometime this week.

The Urho3D-1.4-TurboBadger repository will be a standalone integration to an app, and not integrated with Urho3D lib. It’s good to hear comments like this so I can save myself the work trying to do the opposite.

[size=150]New Repository Created[/size]
Just because you asked - link https://github.com/Lumak/Urho3D-1.4-TurboBadger

Nice work on the implementation. :slight_smile:

I think the Urho-TurboBadger integration posted by thebluefish also fits this bill.
topic1413.html
I migrated over half a year ago and only looked forward, aside from some work in the shared linking department. :mrgreen:

Re. multi-windows… others are more knowledgeable on this, but TB does have multiple internal windows (enough for me, in an editor), drop support, and is rather flexible in general.

Hi,
This is great stuff.
I hope you have time to port this to the Urho trunk version.

Best regards,

Ignore my previous message.
I got it to work in 1.5.

Just change these to new Urho3d name convention.

class UTBRendererBatcher : public UIElement, public TBRendererBatcher
{
	URHO3D_OBJECT( UTBRendererBatcher, UIElement)
...}



URHO3D_EVENT(E_TBMSG, TBMessageNamespace)
{
	URHO3D_PARAM(P_TBWIDGET, Widget);  // TBWidget pointer
}


//=============================================================================
//=============================================================================
class UTBListener : public Object, public TBWidgetListener
{
	URHO3D_OBJECT(UTBListener, Object);
public:
	UTBListener(Context *context);

	~UTBListener();

	void CreateMsgWindow();
	virtual void OnWidgetRemove(TBWidget *parent, TBWidget *child);
	virtual bool OnWidgetInvokeEvent(TBWidget *widget, const TBWidgetEvent &ev);

	TBWidget* GetTBMessageWidget()
	{
		return (TBWidget*)pTBMessageWindow_;
	}
protected:
	void SendEventMsg();

protected:
	TBMessageWindow     *pTBMessageWindow_;

};



	// create TB render batcher
	Graphics *graphics = GetSubsystem<Graphics>();
	UTBRendererBatcher::Create(GetContext(), graphics->GetWidth(), graphics->GetHeight());
	UTBRendererBatcher::Singleton().Init("Data/TB/");

	// create a msg win
	pTBListener_ = new UTBListener(GetContext());
	pTBListener_->CreateMsgWindow();

	SubscribeToEvent(E_TBMSG, URHO3D_HANDLER(NVuDuMain, HandleTBMessage));

How to make it interact with Urho object?

Pull request or let lumark add it to the repository, which should also remove the urho version number from the name, from “Urho3D-1.4-TurboBadger”, to “Urho3D-TurboBadger”.

I think Lumak can update it. As it is easy for him to add changes to the code.

One more thing for those who want to see their game object. Just comment out the below line inside the UTBRendererBatcher.cpp

// root_.SetSkinBg(TBIDC(“background”));

Cheers

Hi. I’ve tried to build it using cmake, but got some error (I’m not familiar with CMAKE, only used it to build URHO so far).

[quote]New Repository Created
Just because you asked - link github.com/Lumak/Urho3D-1.4-TurboBadger[/quote]
I extracted the archive then tried to build it with cmake… Here the result:

[code]C:\Users\Christian\Desktop\Urho3D-1.4-TurboBadger-master\Source\ThirdParty\TurboBadger>cmake_codelite …/turbo
– The C compiler identification is GNU 5.1.0
– The CXX compiler identification is GNU 5.1.0
– Check for working C compiler: C:/TDM-GCC-64/bin/gcc.exe
– Check for working C compiler: C:/TDM-GCC-64/bin/gcc.exe – works
– Detecting C compiler ABI info
– Detecting C compiler ABI info - done
– Detecting C compile features
– Detecting C compile features - done
– Check for working CXX compiler: C:/TDM-GCC-64/bin/g++.exe
– Check for working CXX compiler: C:/TDM-GCC-64/bin/g++.exe – works
– Detecting CXX compiler ABI info
– Detecting CXX compiler ABI info - done
– Detecting CXX compile features
– Detecting CXX compile features - done
CMake Error at CMakeLists.txt:36 (setup_library):
Unknown CMake command “setup_library”.

CMake Warning (dev) in CMakeLists.txt:
No cmake_minimum_required command is present. A line of code such as

cmake_minimum_required(VERSION 3.4)

should be added at the top of the file. The version specified may be lower
if you wish to support older CMake versions for this project. For more
information run “cmake --help-policy CMP0000”.
This warning is for project developers. Use -Wno-dev to suppress it.

– Configuring incomplete, errors occurred!
See also “C:/Users/Christian/Desktop/Urho3D-1.4-TurboBadger-master/Source/ThirdParty/turbo/CMakeFiles/CMakeOutput.log”.[/code]

EDIT: Ok seen more of the structure of your files. This need to be added to the files of URHO and modify the makefiles so URHO add the new sub-directories to the build. I will have to download 1.4 to really test this, but understand more a little about CMAKE now. I would really like to have this in URHO3D as an option that could be activated. (Same for IMGUI), both GUI have their use and your worked to integrate them in URHO. Having a way to activate them in the build via cmake flag would be really nice.

Yes, all of my code exchanges are built as a sample in the sample folder. Good to see that you figured it out.