[Interest] Qt Quick + Unreal Engine?

2022-01-19 Thread Ola Røer Thorsen
Hi all,

just wondering if any of you have had any experience with combining Qt
Quick and Unreal Engine 4 (or 5)? My goal would be to use a Qt Quick UI on
top of 3D scenes from Unreal Engine. If you have, it would be interesting
to hear how it went, and if you have any recommendations.

I'm considering using Qt Quick render control inside Unreal Engine (if
possible). Or maybe use Unreal Engine pixel streaming to a video texture
rendered in the background of a Qt Quick window.

Best regards,
Ola
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Qt6] QML automatic type registration in a (shared) library

2022-01-19 Thread Konstantin Shegunov
On Wed, Jan 19, 2022 at 10:44 AM Alexandru Croitor 
wrote:

> I assume you mean you did target_sources(tsc_ui_target INTERFACE dummy.cpp)
> target_link_libraries(your_shared_lib PRIVATE tsc_ui_target)
>

Yes.

It does work if the direct consumer is a shared lib.
> That doesn't quite work if the consuming target is a static lib, that is
> then linked into an executable/shared lib.
>

Fair enough.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Qt6] QML automatic type registration in a (shared) library

2022-01-19 Thread Alexandru Croitor



> On 19. Jan 2022, at 09:30, Konstantin Shegunov  wrote:
> 
> 
> Oh, I just took the easy (perhaps wrong) approach. I pushed from the backing 
> target to the consumer a cpp file, which is a dummy containing the pointer 
> thing. It just contains (Tsc.Ui is my module's URI):

I assume you mean you did target_sources(tsc_ui_target INTERFACE dummy.cpp)
target_link_libraries(your_shared_lib PRIVATE tsc_ui_target)

It does work if the direct consumer is a shared lib.

That doesn't quite work if the consuming target is a static lib, that is then 
linked into an executable/shared lib.
 dummy.o will be archived into the static lib and then discarded when linked 
into a shared lib because nothing is referencing symbols from that object file.

Hence the need for object libraries instead of target_sources.. Hence the need 
for CMake 3.21.





___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Qt6] QML automatic type registration in a (shared) library

2022-01-19 Thread Konstantin Shegunov
On Wed, Jan 19, 2022 at 9:56 AM Alexandru Croitor 
wrote:

> As far as I know, the referenced merge request only implements an
> abstraction for decorations, but does not implement the specific decoration
> of making sure a library is not discarded.
>

Yes, that's my understanding of the discussion as well. LINK_WHAT_YOU_USE
is supposed to do the right thing, however it's documented for ELF only,
and even then I wasn't able to make it work. That's why I started with the
g++ -u someSymbol  and /INCLUDE:someSymbol instead.

There are WIP changes that try to do that.
> See https://codereview.qt-project.org/c/qt/qtdeclarative/+/367149


Oh, I just took the easy (perhaps wrong) approach. I pushed from the
backing target to the consumer a cpp file, which is a dummy containing the
pointer thing. It just contains (Tsc.Ui is my module's URI):

extern TSCUI_API void qml_register_types_Tsc_Ui();

inline volatile auto tscUiTypeRegistration = _register_types_Tsc_Ui;

I haven't tested it with static libraries, as generally I do avoid them,
but does work for for the shared one (as expected).
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest