I have the following scenario:
For example:
Video1:
Stream1:
format mpeg
bitrate 700kb/s
resolution 1024x764
Stream2:
format mpeg
bitrate 600kb/s
resolution 800x600
Video2:
Stream1:
format mpeg
bitrate 700kb/s
resolution 1024x764
Stream2:
format mpeg
bitrate 600kb/s
resolution 800x600
This is what I was consider holding the data in:
QVector<QVector<QStringList>>
Where QStringList are the value pairs (format, mpeg).
Inside QVector holds the multiple pairs for the stream.
Outside QVector holds the everything i.e. each entry/index is data for a single video file.
I'm not sure whether this is the best way to hold the data a I guess a collection inside a collection inside a collection is not going to be very efficient.
Any opinions on alternatives?
Why not write classes as you need?
class Stream
{
Format format;
Resolution res;
Bitrate br;
};
class Video
{
QVector<Stream> v_stream;
};
class VideoContainer
{
QVector<Video> v_video;
};
QVector required to continuous location of data such as classical C-array. For general purposes recommended QList instead of QVector which also provides fast index-based access but based on pointers.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With