Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,10 @@

Micsig provide an Android apk for remote control of their networked scopes. I noticed video compression and delved into reverse engineering the protocol.

Build requirements (Ubuntu):
`sudo apt install libavcodec-dev libswscale-dev qtcreator qtbase5-dev qt5-qmake qtmultimedia5-dev qtdeclarative5-dev cmake icoutils`

Runtime requirements (Ubuntu):
`sudo apt install qml-module-qtmultimedia qml-module-qt-labs-settings qml-module-qtquick-layouts qml-module-qtquick-controls qml-module-qtquick-controls2`

![Screenshot](https://github.com/GothAck/oscope/blob/master/docs/screen-scope.png?raw=true)
2 changes: 1 addition & 1 deletion cmake/Icons.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function(icons)
foreach(res IN LISTS ARGN)
add_custom_target(icon_${res}
COMMAND mkdir -p icons/hicolor/${res}x${res}
COMMAND inkscape -z -e icons/hicolor/${res}x${res}/oscope.png -w ${res} -h ${res} ${CMAKE_CURRENT_SOURCE_DIR}/resources/oscope.svg
COMMAND inkscape -z --export-type=png --export-filename=icons/hicolor/${res}x${res}/oscope.png -w ${res} -h ${res} ${CMAKE_CURRENT_SOURCE_DIR}/resources/oscope.svg
BYPRODUCTS ${CMAKE_CURRENT_BINARY_DIR}/icons/hicolor/${res}x${res}/oscope.png
)
list(APPEND icon_targets "icon_${res}")
Expand Down
5 changes: 2 additions & 3 deletions src/socket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ Socket::Socket(Scope *parent) :
_buffer(new QBuffer(this))
{
_buffer->open(QBuffer::WriteOnly);
memset(&pic_raw, 0, sizeof(pic_raw));

avcodec_register_all();
pkt = av_packet_alloc();
codec = avcodec_find_decoder(AV_CODEC_ID_H264);
parser = av_parser_init(codec->id);
Expand Down Expand Up @@ -111,6 +108,8 @@ bool Socket::decode() {
vidFrame->unmap();
emit frameAvailable(vidFrame);
}

return true;
}

bool Socket::onFrame(QByteArray frame) {
Expand Down
1 change: 0 additions & 1 deletion src/socket.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ private slots:
AVCodecParserContext *parser = nullptr;
AVCodecContext *c= nullptr;
AVFrame *picture = nullptr;
AVPicture pic_raw;
AVPacket *pkt = nullptr;

int num_nals = 0;
Expand Down