Ticket #11922: 0001-Add-SyncToNode-test-to-NodeTest-and-update-it-to-act.patch

File 0001-Add-SyncToNode-test-to-NodeTest-and-update-it-to-act.patch, 2.8 KB (added by Barrett, 5 years ago)

This new patch just fix a line going over 80 characters.

  • src/tests/kits/media/nodetest/ConsumerNode.cpp

    From e9cc01abe7c9377e072dfda008690c3592154ecb Mon Sep 17 00:00:00 2001
    From: Dario Casalinuovo <b.vitruvio@gmail.com>
    Date: Sat, 28 Mar 2015 15:31:39 +0100
    Subject: [PATCH 01/13] Add SyncToNode test to NodeTest and update it to actual
     API to make it build without warnings.
    
    ---
     src/tests/kits/media/nodetest/ConsumerNode.cpp | 4 ++--
     src/tests/kits/media/nodetest/Jamfile          | 2 +-
     src/tests/kits/media/nodetest/ProducerNode.cpp | 4 ++--
     src/tests/kits/media/nodetest/main.cpp         | 6 ++++++
     4 files changed, 11 insertions(+), 5 deletions(-)
    
    diff --git a/src/tests/kits/media/nodetest/ConsumerNode.cpp b/src/tests/kits/media/nodetest/ConsumerNode.cpp
    index 6b39adc..e9fb7a9 100644
    a b  
    1111
    1212ConsumerNode::ConsumerNode()
    1313    :
     14    BMediaNode("ConsumerNode"),
    1415    BBufferConsumer(B_MEDIA_RAW_AUDIO),
    15     BMediaEventLooper(),
    16     BMediaNode("ConsumerNode")
     16    BMediaEventLooper()
    1717{
    1818    out("ConsumerNode::ConsumerNode\n");
    1919}
  • src/tests/kits/media/nodetest/Jamfile

    diff --git a/src/tests/kits/media/nodetest/Jamfile b/src/tests/kits/media/nodetest/Jamfile
    index ad9f633..f477909 100644
    a b SimpleTest NodeTest  
    77    ConsumerNode.cpp
    88    ProducerNode.cpp
    99
    10     : be media
     10    : be media [ TargetLibsupc++ ]
    1111;
    1212
  • src/tests/kits/media/nodetest/ProducerNode.cpp

    diff --git a/src/tests/kits/media/nodetest/ProducerNode.cpp b/src/tests/kits/media/nodetest/ProducerNode.cpp
    index 9465e8b..13e47b4 100644
    a b  
    1414
    1515ProducerNode::ProducerNode()
    1616    :
     17    BMediaNode("ProducerNode"),
    1718    BBufferProducer(B_MEDIA_RAW_AUDIO),
    1819    BMediaEventLooper(),
    19     BMediaNode("ProducerNode"),
    2020    mBufferGroup(0),
    2121    mBufferProducerSem(-1),
    2222    mBufferProducer(-1),
    ProducerNode::BufferProducer()  
    443443        buffer->Header()->start_time = TimeSource()->Now() + DELAY / 2;
    444444        out("ProducerNode: SendBuffer, sheduled time = %5.4f\n",
    445445            buffer->Header()->start_time / 1E6);
    446         rv = SendBuffer(buffer, mOutput.destination);
     446        rv = SendBuffer(buffer, mOutput.source, mOutput.destination);
    447447        if (rv != B_OK) {
    448448        }
    449449    }
  • src/tests/kits/media/nodetest/main.cpp

    diff --git a/src/tests/kits/media/nodetest/main.cpp b/src/tests/kits/media/nodetest/main.cpp
    index a6f686d..481277e 100644
    a b int main()  
    210210    rv = roster->StartNode(sourceNode, start);
    211211    val(rv);
    212212
     213    out("Testing SyncToNode performance time set is 5 sec\n");
     214    rv = roster->SyncToNode(sourceNode,
     215        producer->TimeSource()->PerformanceTimeFor(
     216            BTimeSource::RealTime() + 5000000), B_INFINITE_TIMEOUT);
     217    val(rv);
     218
    213219    out("########################## PRESS ENTER TO QUIT ##########################\n");
    214220    getchar();
    215221