blog

Qt and bgfx

Qt and bgfx

For some time I work on integration of bgfx renderer with Qt framework (my repository is here: http://github.com/ppiecuch/bgfx). It is almost completed (at least on OS X platform). I am trying to make it working with Qt Resources system, Qt’s QThread and simplify integration as much as possible. Now integration consists including three files only: amalgamted.cpp bx-amalgamted.cpp bimg-amalgamted.cpp

Projects

Amazing Spider AstroBlaster Falling Sand Cosmetics Tester Word War vi NeuroCube More my work at github.com
Fluid simulations

Fluid simulations

I have refreshed several fluid simulations projects, based on c++ and Qt (Qt is my primary toolkit). You can find they on my github: https://github.com/ppiecuch/Shallow-water-fluid-simulator.git https://github.com/ppiecuch/flowed https://github.com/ppiecuch/FluidSolver They are self-contained - you need only Qt SDK (tested with Qt 5.6) installed. Should work both on OS X and Windows.

About

Software developer, graphics designer, and games-development fan from Poznań, Poland. I love making stuff in code, 2D, and 3D. Nowadays, I mostly work with C++ and Qt at home and Swift/iOS at work - although I’m known to pick up C#/.NET/Xamarin, Java/Android SDK, Python, and JavaScript/Angular, HTML, and CSS too from time to time. I’d even use Shell Script if it gets the job done. I do a lot of 3d graphics development and design - using Ogre3D and Unreal Engine with modeling in Blender/SketchUp and composing in Photoshop.

Qt + boost build integration

Sometimes it is good to be able to include boost library without need to compile the whole package beforehand - just by including simple .pri file like this: # Wed Aug 24 09:21:20 CEST 2016 INCLUDEPATH += $$PWD/. SOURCES += "$$PWD/libs/regex/src/c_regex_traits.cpp" "$$PWD/libs/regex/src/cpp_regex_traits.cpp" "$$PWD/libs/regex/src/cregex.cpp" "$$PWD/libs/regex/src/fileiter.cpp" "$$PWD/libs/regex/src/icu.cpp" "$$PWD/libs/regex/src/instances.cpp" "$$PWD/libs/regex/src/posix_api.cpp" win32:SOURCES += unix:SOURCES += LIBS += -lz -lbz2 Here is a simple script that generates boost-mpi.pri script and set of headers and sources from Boost library located at /Volumes/USBSTORE/(Dev)/boost_1_61_0 path:
New Vector demo

New Vector demo

For some time I continue a project for retro-vector OpenGL drawing library called Vector - you can find it on my github: http://github.com/ppiecuch/Vector. I have added some new demo ported from [http://v.st project](http://v.st project). Looks quite retro. I am using Qt for UI/OpenGL setup. It is very handy and easy if you are doing a lot of cross-platform development (and it is free for personal use).
QLMesh - mipmaps preview for compressed textures

QLMesh - mipmaps preview for compressed textures

For the new version of QLMesh I have added preview of compressed textures. No big thing, but with mipmaps support it is quite handy solution. Turned out to be not so complex: CGContextRef kcontext = QLPreviewRequestCreatePDFContext(preview, NULL, NULL, properties); ... CGImageRef cimage = ...; // Fill 3/4 of the rect const float enlarge = 1.0 + 0.48*i*i; CGRect canvasRect = CGRectMake((image[0].width - w*enlarge)/2, (image[0].height - h*enlarge)/2, w*enlarge, h*enlarge); CGContextBeginPage(kcontext, &pageRect); CGContextDrawImage(kcontext, canvasRect, cimage); CGContextEndPage(kcontext);
QLMesh - control application

QLMesh - control application

Part of the QLMesh is control application for quicklook plugin. Usually that would not be anything worth to write an blog entry about, however for MacStore applications this is a very different story. MacStore applications are all sanboxed. There are ways to communicate and share data between such applications, eg. using App groups, but quicklook plugins do not support that feature. After struggling for some time with this problem I came out with this simple solution: