1220
Link: @CplusplusQt Embedded: @EMBCpp • Allowed Topics: C++ and everything related to Qt • Use only English • No Private Message without asking user's permission • No NSFW • No Spam • No unauthorized Bots • No Offtopic • No Self Promotions
Just point at Big Buck Bunny — it's commonly used for testing video stuff.
Читать полностью…
When I copy the frame into a new image (with QPainter) and then save this new picture, everything is as expected.
Читать полностью…
I wrote a suggestion for Qt: https://bugreports.qt.io/browse/QTBUG-141989
Читать полностью…
I'd probably implement it with grabbing the frame whenever it changes and then drawing it after rotation in the paint event.
Читать полностью…
I investigated this a bit last night and this morning, and I haven't figured out a good way to do this.
The way to do this that is most optimized would be to do the video playback in Qt Quick, and embed it in your Widgets app using a QQuickWidget — this way you get optimized rendering.
I don't know of a "pure widgets" way to do it, but another way that occurred to me is to do it in a QGraphicsScene - as that provides a way to transform Qt Widgets.
Hey - question about video playback. How do you change orientation of the video? I couldn't find anything to that end in QMediaPlayer or QVideoSink.
Читать полностью…
and interesting thing: if you make the same set and pass func as simple i64* ptr — it may be optimized and may be optimized completely if you use instead of vector<> MyStruct*
Читать полностью…
but this is preference, not reliable. use constexpr or templates hell (but it's crazy)
Читать полностью…
and x3 mem, but for small arrs copy approach is the best
Читать полностью…
never overuse constexpr or templates
calc, save to file, read. — anything that's faster can be cached, etc
I think this does it all at compile time:
#include <ranges>Читать полностью…
#include <array>
#include <iostream>
auto evenArray = std::views::iota(0, 10) | std::views::filter([](const auto& even) { return even % 2 == 0; })
| std::ranges::to<std::array>();
static_assert(even_numbers.size() == 5, "Incorrect size");
https://github.com/keithel/multimedia-video-modify-orientation
Читать полностью…
Unfortunately, I don't have a video right now that I could share for a bug report.
Читать полностью…
A separate observation: When grabbing a frame and saving it to disk (as a png or jpg), for SOME videos, the saved image will be much brighter than the video.
Читать полностью…
I suppose a QOpenGLWidget subclass could be more efficient
Читать полностью…
But then, the playback isn't really optimized. It's then all software.
Читать полностью…
I'll shoot a link to the repo I used for my testing... I haven't implemented the QGraphicsScene approach.
Читать полностью…
If it doesn't exist, I'll just create a derived class that does. 😉
Читать полностью…
some simple deobfuscation theory of handlers graph from simple stack base vm's that ommit scratch)
Читать полностью…
btw, templates are a feature to copy-past functions with different type but where overload not enough
if you can't understand stl decl from a quick glance — you dont know them to use right. to say, few one can use them
lambda'll break optimization chain to flatten it — inline pass, then check deps graph and precalc it
Читать полностью…
Welcome to the group, @faddistyoungman! :-)
Wanna share your story of how you started with Qt, QML or C++? Maybe some nice feature that made you stick with it.
Rules are set on the description of the group. :)
Other people of course may have different opinions about what can be "immediately understood"! 😊
Читать полностью…