[hydra-commits] ken.hunt: branch techdemo/ken.hunt/benchmark r661 - in /techdemo/team/ken.hun...
SVN commits to the Hydra project
hydra-commits at lists.digium.com
Thu Jun 3 18:25:16 CDT 2010
Author: ken.hunt
Date: Thu Jun 3 18:25:15 2010
New Revision: 661
URL: https://origsvn.digium.com/svn-view/hydra?view=rev&rev=661
Log:
test
Added:
techdemo/team/ken.hunt/benchmark/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/bin/
techdemo/team/ken.hunt/benchmark/bin/install_debug.bat (with props)
techdemo/team/ken.hunt/benchmark/bin/media.config (with props)
techdemo/team/ken.hunt/benchmark/build/
techdemo/team/ken.hunt/benchmark/build/runcmake.bat (with props)
techdemo/team/ken.hunt/benchmark/ice/
techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/ice/driver/
techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/ice/driver/sink/
techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp (with props)
techdemo/team/ken.hunt/benchmark/ice/driver/source/
techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp (with props)
techdemo/team/ken.hunt/benchmark/ice/slice/
techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt (with props)
techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice (with props)
techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cpp
- copied, changed from r651, techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cp
Removed:
techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cp
Modified:
techdemo/team/ken.hunt/benchmark/rtp/CMakeLists.txt
Added: techdemo/team/ken.hunt/benchmark/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,10 @@
+cmake_minimum_required(VERSION 2.6)
+
+include(cmake/Hydra_v3.cmake)
+
+hydra_project(benchmark 3.4 CXX)
+
+set(BUILD_SHARED_LIBS TRUE)
+
+add_subdirectory(rtp)
+add_subdirectory(ice)
Propchange: techdemo/team/ken.hunt/benchmark/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/bin/install_debug.bat
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/bin/install_debug.bat?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/bin/install_debug.bat (added)
+++ techdemo/team/ken.hunt/benchmark/bin/install_debug.bat Thu Jun 3 18:25:15 2010
@@ -1,0 +1,5 @@
+
+echo off
+copy /Y /B ..\build\ice\driver\sink\Debug\icesink.exe .
+copy /Y /B ..\build\ice\driver\source\Debug\icesource.exe .
+copy /Y /B ..\build\ice\slice\Debug\MediaIf_CXXd.dll .
Propchange: techdemo/team/ken.hunt/benchmark/bin/install_debug.bat
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/bin/install_debug.bat
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/bin/install_debug.bat
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/bin/media.config
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/bin/media.config?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/bin/media.config (added)
+++ techdemo/team/ken.hunt/benchmark/bin/media.config Thu Jun 3 18:25:15 2010
@@ -1,0 +1,12 @@
+
+Sink.Endpoints=udp -h 127.0.0.1 -p 10011
+
+MediaSink=MediaSink:udp -h 127.0.0.1 -p 10011
+
+# Fixed or Random
+MediaSink.NumPackets=10000
+MediaSink.SizeType=Fixed
+MediaSink.FixedSize=8000
+
+# Variable or Large
+MediaSink.RandomType=Large
Propchange: techdemo/team/ken.hunt/benchmark/bin/media.config
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/bin/media.config
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/bin/media.config
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/build/runcmake.bat
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/build/runcmake.bat?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/build/runcmake.bat (added)
+++ techdemo/team/ken.hunt/benchmark/build/runcmake.bat Thu Jun 3 18:25:15 2010
@@ -1,0 +1,6 @@
+ at ECHO OFF
+REM -Wdev: Enable developer warnings.
+REM --build <sourcedir> : for out-of-source building
+
+cmake -Wdev --build ..
+
Propchange: techdemo/team/ken.hunt/benchmark/build/runcmake.bat
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/build/runcmake.bat
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/build/runcmake.bat
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,3 @@
+
+add_subdirectory(slice)
+add_subdirectory(driver)
Propchange: techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,3 @@
+
+add_subdirectory(sink)
+add_subdirectory(source)
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,10 @@
+set(COMPONENT icesink)
+
+hydra_component_init(${COMPONENT} CXX)
+hydra_component_add_slice(${COMPONENT} MediaIf)
+hydra_component_add_file(${COMPONENT} sink.cpp)
+
+# hydra_component_add_boost_libraries(${COMPONENT} thread)
+
+hydra_component_build_standalone(${COMPONENT})
+hydra_component_install(${COMPONENT})
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp (added)
+++ techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp Thu Jun 3 18:25:15 2010
@@ -1,0 +1,124 @@
+#include <IceUtil/IceUtil.h>
+#include <Ice/Ice.h>
+
+#include "MediaIf.h"
+
+using namespace std;
+using namespace Hydra::Media;
+
+class MediaSinkImpl : public MediaSink
+{
+public:
+ MediaSinkImpl() : mCounter(0), mRunning(false) {}
+ virtual void SendFrame(const MediaFrame &frame, const Ice::Current&)
+ {
+ if (frame.header.Type == START)
+ {
+ if (!mRunning)
+ {
+ mRunning = true;
+ cout << "Received start of stream indicator." << endl;
+ mCounter = 0;
+
+ start = IceUtil::Time::now();
+ }
+ }
+
+ if (frame.header.Type == AUDIO)
+ {
+ mCounter++;
+ }
+
+ if (frame.header.Type == FINAL)
+ {
+ if (mRunning)
+ {
+ mRunning = false;
+
+ cout << "Received end of stream indicator." << endl;
+ IceUtil::Time end = IceUtil::Time::now();
+ IceUtil::Time diff = end - start;
+
+ cout << " " << mCounter << " packets received, Elapsed time:" << diff << " seconds." << endl;
+ }
+ }
+ }
+
+ virtual void SendBytes(const ::std::pair<const ::Ice::Byte*, const ::Ice::Byte*>& byteArr, const Ice::Current&)
+ {
+ if (byteArr.first[0] == '1')
+ {
+ if (!mRunning)
+ {
+ mRunning = true;
+ cout << "Received start of bytes indicator." << endl;
+ mCounter = 0;
+
+ start = IceUtil::Time::now();
+ }
+ }
+
+ if (byteArr.first[0] == '0')
+ {
+ mCounter++;
+ }
+
+ if (byteArr.first[0] == '2')
+ {
+ if (mRunning)
+ {
+ mRunning = false;
+
+ cout << "Received end of bytes indicator." << endl;
+ IceUtil::Time end = IceUtil::Time::now();
+ IceUtil::Time diff = end - start;
+
+ cout << " " << mCounter << " packets received, Elapsed time:" << diff << " seconds." << endl;
+ }
+ }
+ }
+
+private:
+ long mCounter;
+ bool mRunning;
+ IceUtil::Time start;
+};
+typedef IceUtil::Handle<MediaSinkImpl> MediaSinkImplPtr;
+
+class Sink : public Ice::Application
+{
+public:
+ Sink() {}
+
+ virtual int run(int, char*[]);
+private:
+ std::string mAppName;
+ MediaSinkPtr mSink;
+};
+
+static Sink app;
+int main(int argc, char* argv[])
+{
+ app.callbackOnInterrupt();
+ return app.main(argc, argv);
+}
+
+/**
+ * Overload of the Ice::Application::run method.
+ */
+int Sink::run(int argc, char* argv[])
+{
+ mAppName = argv[0];
+ Ice::ObjectAdapterPtr adapter = communicator()->createObjectAdapter("Sink");
+
+ // Create the servant
+ mSink = new MediaSinkImpl();
+ Ice::ObjectPrx base = adapter->add(mSink, communicator()->stringToIdentity("MediaSink"));
+
+ adapter->activate();
+
+ communicator()->waitForShutdown();
+
+ return EXIT_SUCCESS;
+}
+
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/sink/sink.cpp
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,10 @@
+set(COMPONENT icesource)
+
+hydra_component_init(${COMPONENT} CXX)
+hydra_component_add_slice(${COMPONENT} MediaIf)
+hydra_component_add_file(${COMPONENT} source.cpp)
+
+# hydra_component_add_boost_libraries(${COMPONENT} thread)
+hydra_component_add_ice_libraries(${COMPONENT} IceStorm)
+hydra_component_build_standalone(${COMPONENT})
+hydra_component_install(${COMPONENT})
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp (added)
+++ techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp Thu Jun 3 18:25:15 2010
@@ -1,0 +1,269 @@
+#include <IceUtil/IceUtil.h>
+#include <Ice/Ice.h>
+
+#include "MediaIf.h"
+
+using namespace std;
+using namespace Hydra::Media;
+
+const string MCAST_IP("239.216.30.54");
+const int MCAST_PORT(4000);
+const int SERVER_PORT(5000);
+
+//const int MAX_PACKET_SIZE((1024 * 64) - 1)
+
+// Ice max datagram size
+const int MAX_ICE_DATAGRAM(65507);
+const int MAX_PACKET_SIZE(MAX_ICE_DATAGRAM);
+
+bool mFixedSize(true);
+int mNumPackets(10000);
+bool mRandomLarge(false);
+
+int mPacketSize(MAX_PACKET_SIZE);
+const int NUMVALUES(16);
+const int PSEUDO_RANDOM[] = {10256, 4000, 32066, 48767,
+ 645, 6012, 59276, 62186,
+ 80, 18004, 60356, 24560,
+ 389, 8, 49236, 48752};
+const int PSEUDO_RANDOM_BIG[] = {65422, 62776, 65023, 63946,
+ 65126, 60323, 62186, 58437,
+ 60356, 65485, 63748, 64475,
+ 61576, 59045, 60545, 62843};
+char mTestBuf[MAX_PACKET_SIZE];
+
+/**
+ * A customization of Ice::Application for this simple command line app.
+ */
+class Server : public Ice::Application
+{
+public:
+ Server() : mDone(false) {}
+
+ virtual int run(int, char*[]);
+ virtual void interruptCallback(int);
+
+ void PrintUsage(const string& appName);
+ void PrintSettings();
+ void SendFrames();
+ void SendFrame(FrameType type, int size);
+ void SendByteSeq();
+
+private:
+ bool mDone;
+ std::string mAppName;
+ MediaSinkPrx mMediaSink;
+};
+
+static Server app;
+int main(int argc, char* argv[])
+{
+ app.callbackOnInterrupt();
+ return app.main(argc, argv);
+}
+
+void Server::PrintUsage(const std::string& appName)
+{
+ cout << "Usage: " << appName << " [-i ipaddress] [-p fromport] [-n numpackets] [[-f [fixedsize]]|[-r [V|L]] " << endl;
+ cout << " -f [fixedsize] - Send fixed-size packets. The default fixed size is " << mPacketSize << " bytes. " << endl;
+ cout << " -r [V|L] - Send (pseudo) random-sized packets. Set the S parameter for wide variation, or L for all large packets. " << endl;
+ cout << " -n numpackets - Number of packets to send. Default: " << mNumPackets << endl;
+}
+
+void Server::PrintSettings()
+{
+ cout << "Executing with the following settings:" << endl;
+
+ if (mFixedSize)
+ {
+ cout << " - Packet size: Fixed at " << mPacketSize << endl;
+ }
+ else
+ {
+ if (mRandomLarge)
+ {
+ cout << " - Packet size: Random with Large-sized packets." << endl;
+ }
+ else
+ {
+ cout << " - Packet size: Random with varying sized packets." << endl;
+ }
+ }
+
+ cout << " - Number of packets to send:" << mNumPackets << endl;
+
+}
+
+/**
+ * Overload of the Ice::Application::run method.
+ */
+int Server::run(int argc, char* argv[])
+{
+ mAppName = argv[0];
+
+ try
+ {
+ Ice::CommunicatorPtr ic = communicator();
+ Ice::PropertiesPtr props = ic->getProperties();
+
+ string numPacketStr = props->getProperty("MediaSink.NumPackets");
+ mNumPackets = atoi(numPacketStr.c_str());
+
+ string sizeType = props->getProperty("MediaSink.SizeType");
+ if ((sizeType.compare("Fixed") == 0) ||
+ (sizeType.compare("FIXED") == 0))
+ {
+ mFixedSize = true;
+ }
+ else
+ {
+ mFixedSize = false;
+ }
+
+ string size = props->getProperty("MediaSink.FixedSize");
+ mPacketSize = atoi(size.c_str());
+
+ if (mPacketSize > MAX_PACKET_SIZE)
+ {
+ cout << "Maximum packet size of " << MAX_PACKET_SIZE << " exceeded!" << endl;
+ cout << "Using " << MAX_PACKET_SIZE << endl;
+ mPacketSize = MAX_PACKET_SIZE;
+ }
+
+ string randomType = props->getProperty("MediaSink.RandomType");
+ if ((randomType.compare("Large") == 0) ||
+ (randomType.compare("LARGE") == 0))
+ {
+ mRandomLarge = true;
+ }
+ else
+ {
+ mRandomLarge = false;
+ }
+
+ Ice::ObjectPrx base = ic->propertyToProxy("MediaSink");
+ //mMediaSink = MediaSinkPrx::checkedCast(base);
+
+ // Get a datagram proxy
+ Ice::ObjectPrx datagram = base->ice_datagram();
+ mMediaSink = MediaSinkPrx::uncheckedCast(datagram);
+
+ if (!mMediaSink)
+ throw "Invalid proxy";
+
+ PrintSettings();
+
+ // Test 1
+ SendFrames();
+
+ // Test 2
+ SendByteSeq();
+ }
+ catch(const Ice::Exception &e)
+ {
+ cout << e.what();
+ }
+
+ return EXIT_SUCCESS;
+}
+
+void Server::interruptCallback(int val)
+{
+ cout << "Interrupted..." << endl;
+ mDone = true;
+ _exit(EXIT_SUCCESS);
+}
+
+
+int GetPacketSize(int counter)
+{
+ if (mFixedSize)
+ {
+ return mPacketSize;
+ }
+ int index = counter % NUMVALUES;
+
+ if (mRandomLarge)
+ {
+ return PSEUDO_RANDOM_BIG[index];
+ }
+
+ return PSEUDO_RANDOM[index];
+}
+
+void Server::SendFrame(FrameType type, int size)
+{
+ MediaFrame frame;
+ frame.header.Type = type;
+ frame.data.clear();
+
+ for (int i=0; i < size; i++) // size; i++)
+ {
+ frame.data.push_back('k');
+ }
+
+ mMediaSink->SendFrame(frame);
+
+}
+
+void Server::SendFrames()
+{
+ cout << "Transmitting frames... " << endl;
+
+ // Send 3 packets with START marker
+ SendFrame(START, 1);
+ SendFrame(START, 1);
+ SendFrame(START, 1);
+
+ for (int i=0; i < mNumPackets; i++)
+ {
+ //SEND a packet
+ int size = GetPacketSize(i);
+ SendFrame(AUDIO, size);
+ }
+
+ // Send 3 packets with END marker
+ SendFrame(FINAL, 1);
+ SendFrame(FINAL, 1);
+ SendFrame(FINAL, 1);
+ cout << "Transmission complete." << endl;
+}
+
+void Server::SendByteSeq()
+{
+ ByteSeq markerBytesBuf(1);
+ markerBytesBuf.resize(1);
+ pair<const Ice::Byte*, const Ice::Byte*> markerBytes;
+ markerBytes.first = &markerBytesBuf[0];
+ markerBytes.second = markerBytes.first + markerBytesBuf.size();
+
+ ByteSeq byteSeq(MAX_PACKET_SIZE);
+ pair<const Ice::Byte*, const Ice::Byte*> byteArr;
+ byteArr.first = &byteSeq[0];
+ byteArr.second = byteArr.first + byteSeq.size();
+ byteSeq[0] = '0';
+
+ cout << "Transmitting bytes... " << endl;
+
+ // Send 3 packets with START marker
+ markerBytesBuf[0] = '1';
+ mMediaSink->SendBytes(markerBytes);
+ mMediaSink->SendBytes(markerBytes);
+ mMediaSink->SendBytes(markerBytes);
+
+ for (int i=0; i < mNumPackets; i++)
+ {
+ int size = GetPacketSize(i);
+ byteArr.second = byteArr.first + size;
+ mMediaSink->SendBytes(byteArr);
+ }
+
+ // Send 3 packets with END marker
+ markerBytesBuf[0] = '2';
+ mMediaSink->SendBytes(markerBytes);
+ mMediaSink->SendBytes(markerBytes);
+ mMediaSink->SendBytes(markerBytes);
+
+ cout << "Transmission complete." << endl;
+}
+
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/driver/source/source.cpp
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt (added)
+++ techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,0 +1,3 @@
+hydra_slice_include_directories(.)
+
+hydra_compile_slice(MediaIf.ice)
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/CMakeLists.txt
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice?view=auto&rev=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice (added)
+++ techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice Thu Jun 3 18:25:15 2010
@@ -1,0 +1,37 @@
+
+module Hydra
+{
+ module Media
+ {
+ sequence<byte> ByteSeq;
+
+ enum FrameType
+ {
+ START,
+ FINAL,
+ AUDIO
+ };
+
+ struct MediaFrameHeader
+ {
+ int SampleFrequency;
+ long TimeStamp;
+ FrameType Type;
+ };
+
+ struct MediaFrame
+ {
+ MediaFrameHeader header;
+ ByteSeq data;
+ };
+
+ interface MediaSink
+ {
+ // Test 1
+ void SendFrame(MediaFrame frame);
+
+ // Test 2
+ void SendBytes(["cpp:array"] ByteSeq seq);
+ };
+ };
+};
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: techdemo/team/ken.hunt/benchmark/ice/slice/MediaIf.ice
------------------------------------------------------------------------------
svn:mime-type = text/plain
Modified: techdemo/team/ken.hunt/benchmark/rtp/CMakeLists.txt
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/rtp/CMakeLists.txt?view=diff&rev=661&r1=660&r2=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/rtp/CMakeLists.txt (original)
+++ techdemo/team/ken.hunt/benchmark/rtp/CMakeLists.txt Thu Jun 3 18:25:15 2010
@@ -1,7 +1,3 @@
-cmake_minimum_required(VERSION 2.6)
-
-project(benchmark)
-set(BUILD_SHARED_LIBS TRUE)
set(BENCHMARK_INCLUDE_DIRECTORIES "" CACHE INTERNAL benchmark FORCE)
set(BENCHMARK_LIB_DIRECTORIES "" CACHE INTERNAL benchmark FORCE)
Copied: techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cpp (from r651, techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cp)
URL: https://origsvn.digium.com/svn-view/hydra/techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cpp?view=diff&rev=661&p1=techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cp&r1=651&p2=techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cpp&r2=661
==============================================================================
--- techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cp (original)
+++ techdemo/team/ken.hunt/benchmark/rtp/driver/source/source.cpp Thu Jun 3 18:25:15 2010
@@ -9,11 +9,13 @@
#include "RTPSessionParams.h"
#include "RTPUDPv4Transmitter.h"
-#define MCAST_IP "239.216.30.54"
-#define MCAST_PORT 4000
-#define SERVER_PORT 5000
-
-#define MAX_PACKET_SIZE ((1024 * 64) - 1)
+using namespace std;
+
+const string MCAST_IP("239.216.30.54");
+const int MCAST_PORT(4000);
+const int SERVER_PORT(5000);
+
+const int MAX_PACKET_SIZE((1024 * 64) - 1);
std::string mDestAddress(MCAST_IP);
int mDestPort(MCAST_PORT);
@@ -33,7 +35,6 @@
65126, 60323, 62186, 58437,
60356, 65485, 63748, 64475,
61576, 59045, 60545, 62843};
-using namespace std;
/*-------------------------------------------------------*/
/* ReportError
More information about the asterisk-scf-commits
mailing list