[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-multimedia
Subject:    Re: Review Request: phonon phive core frontend api
From:       "Bart Cerneels" <bart.cerneels () kde ! org>
Date:       2012-09-30 7:11:19
Message-ID: 20120930071119.22515.98837 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


> On Sept. 26, 2012, 7:42 p.m., Bart Cerneels wrote:
> > core/Player.h, line 39
> > <http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line39>
> > 
> > Should be addAudioOutput and addVideoOutput if you want to keep them separate.
> 
> Matěj Laitl wrote:
> Why?

The alternative is an abstract Output class, who's polymorphic sub-classes can be \
added. Since there is no intention just yet to make that class it's better to keep \
these method names rather then 2 addOutput() with different arguments.


> On Sept. 26, 2012, 7:42 p.m., Bart Cerneels wrote:
> > core/Player.h, line 51
> > <http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line51>
> > 
> > Metadata should go in the source!
> > 
> > Would be nice in Amarok that we can simply map Track to Phonon::Source in the \
> > metadata handling.
> 
> Matěj Laitl wrote:
> +1.

I discovered on the train back we need operator<() and a global qHash(Phonon::Source) \
for this. On for use as a key in a QMap, the other in a QHash.


> On Sept. 26, 2012, 7:42 p.m., Bart Cerneels wrote:
> > core/Player.h, line 52
> > <http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line52>
> > 
> > no. Total can be unknown and it's a one line calculation.
> 
> Matěj Laitl wrote:
> But Phonon may know the length better than we in Amarok. I would personally like to \
> use some kind fo remainingTime signals to implement bounded playback in Amarok.

Phonon would internally do the same calculation (remaining = total - elapsed). If you \
add the convenience function, shouldn't you also add the notify signal, etc?


> On Sept. 26, 2012, 7:42 p.m., Bart Cerneels wrote:
> > core/Queue.h, line 21
> > <http://git.reviewboard.kde.org/r/106566/diff/1/?file=87104#file87104line21>
> > 
> > Provide some convenience functions for this.
> > iterator, index, append, prepend, etc.
> 
> Matěj Laitl wrote:
> Do we really need em? We just use enqueue() and clear() in Amarok.

Amarok uses it's own queue, other applications probably don't want to make it as \
complex. Besides, I'm hoping that in Phonon 5 we won't need our own queue \
implementation either.


- Bart


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106566/#review19473
-----------------------------------------------------------


On Sept. 25, 2012, 11:06 a.m., Harald Sitter wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/106566/
> -----------------------------------------------------------
> 
> (Updated Sept. 25, 2012, 11:06 a.m.)
> 
> 
> Review request for Amarok and Phonon.
> 
> 
> Description
> -------
> 
> phonon phive core frontend api
> 
> 
> Diffs
> -----
> 
> core/AudioDataOutput.h PRE-CREATION 
> core/AudioDataOutput.cpp PRE-CREATION 
> core/AudioOutput.h PRE-CREATION 
> core/AudioOutput.cpp PRE-CREATION 
> core/BackendCapabilities.h PRE-CREATION 
> core/BackendCapabilities.cpp PRE-CREATION 
> core/OutputEffect.h PRE-CREATION 
> core/OutputEffect.cpp PRE-CREATION 
> core/Player.h PRE-CREATION 
> core/Player.cpp PRE-CREATION 
> core/Queue.h PRE-CREATION 
> core/Queue.cpp PRE-CREATION 
> core/Source.h PRE-CREATION 
> core/Source.cpp PRE-CREATION 
> core/VideoDataOutput.h PRE-CREATION 
> core/VideoDataOutput.cpp PRE-CREATION 
> core/abstract/AbstractAudioOutput.h PRE-CREATION 
> core/abstract/AbstractAudioOutput.cpp PRE-CREATION 
> core/abstract/AbstractMediaStream.h PRE-CREATION 
> core/abstract/AbstractMediaStream.cpp PRE-CREATION 
> core/abstract/AbstractVideoOutput.h PRE-CREATION 
> core/abstract/AbstractVideoOutput.cpp PRE-CREATION 
> core/core.pro PRE-CREATION 
> core/effects/SubtitleEffect.h PRE-CREATION 
> core/effects/SubtitleEffect.cpp PRE-CREATION 
> core/five_global.h PRE-CREATION 
> 
> Diff: http://git.reviewboard.kde.org/r/106566/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Harald Sitter
> 
> 


[Attachment #5 (text/html)]

<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;">  <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/106566/">http://git.reviewboard.kde.org/r/106566/</a>
  </td>
    </tr>
   </table>
   <br />








<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On September 26th, 2012, 7:42 p.m., <b>Bart \
Cerneels</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; \
border-collapse: collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; \
font-size: 9pt; padding: 4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line39" \
style="color: black; font-weight: bold; text-decoration: \
underline;">core/Player.h</a>  <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
"></pre></td>  <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: \
0; ">public:</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">39</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span \
class="n">bool</span> <span class="n">addOutput</span><span class="p">(</span><span \
class="n">AbstractAudioOutput</span> <span class="o">*</span><span \
class="n">audioOutput</span><span class="p">);</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Should be addAudioOutput \
and addVideoOutput if you want to keep them separate.</pre>  </blockquote>



 <p>On September 29th, 2012, 12:16 p.m., <b>Matěj Laitl</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Why?</pre>  \
</blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The \
alternative is an abstract Output class, who&#39;s polymorphic sub-classes can be \
added. Since there is no intention just yet to make that class it&#39;s better to \
keep these method names rather then 2 addOutput() with different arguments.</pre> <br \
/>

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On September 26th, 2012, 7:42 p.m., <b>Bart \
Cerneels</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; \
border-collapse: collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; \
font-size: 9pt; padding: 4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line51" \
style="color: black; font-weight: bold; text-decoration: \
underline;">core/Player.h</a>  <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
"></pre></td>  <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: \
0; ">public:</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">51</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span \
class="cp">#warning metadata missing</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Metadata should go in \
the source!

Would be nice in Amarok that we can simply map Track to Phonon::Source in the \
metadata handling.</pre>  </blockquote>



 <p>On September 29th, 2012, 12:16 p.m., <b>Matěj Laitl</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">+1.</pre>  </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I \
discovered on the train back we need operator&lt;() and a global \
qHash(Phonon::Source) for this. On for use as a key in a QMap, the other in a \
QHash.</pre> <br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On September 26th, 2012, 7:42 p.m., <b>Bart \
Cerneels</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; \
border-collapse: collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; \
font-size: 9pt; padding: 4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/106566/diff/1/?file=87102#file87102line52" \
style="color: black; font-weight: bold; text-decoration: \
underline;">core/Player.h</a>  <span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
"></pre></td>  <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: \
0; ">public:</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">52</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span \
class="cp">#warning remainingTime interface?</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">no. Total can be unknown \
and it&#39;s a one line calculation.</pre>  </blockquote>



 <p>On September 29th, 2012, 12:16 p.m., <b>Matěj Laitl</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">But Phonon may know the \
length better than we in Amarok. I would personally like to use some kind fo \
remainingTime signals to implement bounded playback in Amarok.</pre>  </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Phonon \
would internally do the same calculation (remaining = total - elapsed). If you add \
the convenience function, shouldn&#39;t you also add the notify signal, etc?</pre> \
<br />

<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On September 26th, 2012, 7:42 p.m., <b>Bart \
Cerneels</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  



<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; \
border-collapse: collapse; margin: 2px padding: 2px;">  <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; \
font-size: 9pt; padding: 4px 8px; text-align: left;">  <a \
href="http://git.reviewboard.kde.org/r/106566/diff/1/?file=87104#file87104line21" \
style="color: black; font-weight: bold; text-decoration: underline;">core/Queue.h</a> \
<span style="font-weight: normal;">

     (Diff revision 1)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: 0; \
"></pre></td>  <td colspan="2"><pre style="font-size: 8pt; line-height: 140%; margin: \
0; ">class Queue {</pre></td>

  </tr>
 </tbody>




 
 



 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" \
align="right"><font size="2"></font></th>  <td bgcolor="#c5ffc4" width="50%"><pre \
style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>  <th \
bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid \
#C0C0C0;" align="right"><font size="2">21</font></th>  <td bgcolor="#c5ffc4" \
width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">        <span \
class="kt">void</span> <span class="n">enqueue</span><span class="p">(</span><span \
class="k">const</span> <span class="n">Source</span> <span \
class="o">&amp;</span><span class="n">source</span><span class="p">,</span> <span \
class="k">const</span> <span class="n">Source</span> <span \
class="o">&amp;</span><span class="n">before</span><span class="o">=</span><span \
class="n">Source</span><span class="p">());</span></pre></td>  </tr>

 </tbody>

</table>

  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Provide some convenience \
functions for this. iterator, index, append, prepend, etc.</pre>
 </blockquote>



 <p>On September 29th, 2012, 12:16 p.m., <b>Matěj Laitl</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Do we really need em? We \
just use enqueue() and clear() in Amarok.</pre>  </blockquote>







</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; \
white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Amarok uses \
it&#39;s own queue, other applications probably don&#39;t want to make it as complex. \
Besides, I&#39;m hoping that in Phonon 5 we won&#39;t need our own queue \
implementation either.</pre> <br />




<p>- Bart</p>


<br />
<p>On September 25th, 2012, 11:06 a.m., Harald Sitter wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;">  <tr>
  <td>

<div>Review request for Amarok and Phonon.</div>
<div>By Harald Sitter.</div>


<p style="color: grey;"><i>Updated Sept. 25, 2012, 11:06 a.m.</i></p>






<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">phonon phive core frontend api</pre>  </td>
 </tr>
</table>





<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>core/AudioDataOutput.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/AudioDataOutput.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/AudioOutput.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/AudioOutput.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/BackendCapabilities.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/BackendCapabilities.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/OutputEffect.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/OutputEffect.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Player.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Player.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Queue.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Queue.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Source.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/Source.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/VideoDataOutput.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/VideoDataOutput.cpp <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractAudioOutput.h <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractAudioOutput.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractMediaStream.h <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractMediaStream.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractVideoOutput.h <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/abstract/AbstractVideoOutput.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/core.pro <span style="color: grey">(PRE-CREATION)</span></li>

 <li>core/effects/SubtitleEffect.h <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/effects/SubtitleEffect.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>core/five_global.h <span style="color: grey">(PRE-CREATION)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/106566/diff/" style="margin-left: \
3em;">View Diff</a></p>




  </td>
 </tr>
</table>








  </div>
 </body>
</html>



_______________________________________________
kde-multimedia mailing list
kde-multimedia@kde.org
https://mail.kde.org/mailman/listinfo/kde-multimedia


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic