Nope, any number. And we support 37 hotcues in the engine (which is totally
arbitrary but we have to pre-instantiate the COs for now so we have to have
some limit).
On Fri, Jan 16, 2015 at 9:35 AM, Ferran Pujol Camins <
ferranpujolcam...@gmail.com> wrote:
> Also, is there a limit on how many saved cues (not hotcues but cues) a
> track can have?
>
> 2015-01-16 15:56 GMT+01:00 Ferran Pujol Camins <
> ferranpujolcam...@gmail.com>:
>
>> Thank you RJ, I have a first working version, however, WaveformRenderMark
>> now inherits from QObject. Who should its parent be?
>>
>> 2015-01-13 16:59 GMT+01:00 RJ Ryan <russelljr...@gmail.com>:
>>
>>> Hi Ferran,
>>>
>>> You should follow the waveform renderers and overload
>>> WaveformWidgetRendererAbstract::onSetTrack():
>>>
>>> https://github.com/mixxxdj/mixxx/blob/master/src/waveform/renderers/glslwaveformrenderersignal.cpp#L218
>>>
>>> This is called every time a track is loaded. BaseTrackPlayer signals are
>>> hooked to WWaveformViewer::onTrackLoaded/Unloaded which calls
>>> WaveformWidgetRenderer::setTrack which calls
>>> WaveformRendererAbstract::onSetTrack for every renderer in the widget's
>>> render stack.
>>>
>>> Note that loadTexture then calls m_waveformRenderer->getTrackInfo() to
>>> get the TrackPointer for the newly loaded track.
>>>
>>> https://github.com/mixxxdj/mixxx/blob/master/src/waveform/renderers/glslwaveformrenderersignal.cpp#L86
>>>
>>> You can use this to hook the cuesUpdated signal and to re-generate the
>>> cue pixmaps for the track's current cues.
>>>
>>> Cheers,
>>> RJ
>>>
>>> On Tue, Jan 13, 2015 at 10:46 AM, Ferran Pujol Camins <
>>> ferranpujolcam...@gmail.com> wrote:
>>>
>>>> Ok, so this is what I got now:
>>>>
>>>> WaveformRenderMark::setup connects BaseTrackPlayer::newTrackLoaded
>>>> signal to a new WaveformRenderMark::slotTrackLoaded.
>>>>
>>>> Every time a track is loaded, WaveformRenderMark::slotTrackLoaded
>>>> connects its TrackInfoObject::cuesUpdated signal to a new
>>>> WaveformRenderMark::slotCuesUpdated, who updates the marks text.
>>>>
>>>> WaveformRenderMark::setup also checks if a track is already loaded in
>>>> the player and if so, calls WaveformRenderMark::slotCuesUpdated in order to
>>>> show the cue labels on a skin change.
>>>>
>>>> The problem I have is that I don't know where the instance of
>>>> BaseTrackPlayer I should query is, neither how to acces it. I've seen
>>>> BaseTrackPlayer pointers in Mixxx, SkinLoader and LegacySkinParser Classes.
>>>> Where should I look at?
>>>>
>>>> 2015-01-12 20:40 GMT+01:00 RJ Ryan <russelljr...@gmail.com>:
>>>>
>>>>> On mobile, sorry for brevity. Setup is only done once at skin creation
>>>>> time. The cue text can change at track load time or when user edits the
>>>>> text e.g. via the track properties dialog. So you need to check if the
>>>>> text
>>>>> has changed on every draw. (Or listen to track signals for cue updates)
>>>>>
>>>>> On Mon, Jan 12, 2015, 11:34 AM Ferran Pujol Camins <
>>>>> ferranpujolcam...@gmail.com> wrote:
>>>>>
>>>>>> Also, I've further understood this code (thanks for your hints RJ!).
>>>>>> I don't feel comfortable setting the text of the WaveformMarks in
>>>>>> WaveformMarkRenderer. WaveformMarkRenderer already does it's job of
>>>>>> painting whatever text a WaveformMark happens to have. Doesn't it make
>>>>>> more
>>>>>> sense to modify WaveformMarkSet::setup to construct the hotcue marks
>>>>>> already with the desired text?
>>>>>>
>>>>>> It makes more sense to me, but I'm not 100% sure because I don't
>>>>>> understand how information about cues reaches these classes: what are all
>>>>>> those QDomNodes? ALso, what is the default mark?
>>>>>>
>>>>>> 2015-01-12 20:21 GMT+01:00 Ferran Pujol Camins <
>>>>>> ferranpujolcam...@gmail.com>:
>>>>>>
>>>>>>> One question: if WaveformMark::setKeyAndIndex(const ConfigKey& key,
>>>>>>> int i), is called a second time, doesn't this forget to deallocate the
>>>>>>> old
>>>>>>> instance of ControlObjectThread?
>>>>>>>
>>>>>>> 2015-01-10 0:19 GMT+01:00 RJ Ryan <russelljr...@gmail.com>:
>>>>>>>
>>>>>>>> Hi Ferran,
>>>>>>>>
>>>>>>>> The waveforms are a little twisty-turny. Here are some hints to get
>>>>>>>> you started:
>>>>>>>>
>>>>>>>> WaveformMark represents the skin's definition of what the hotcue
>>>>>>>> should be rendered as (an image from file, an auto-generated image, the
>>>>>>>> text to show, etc.). WaveformRenderMark is a WaveformRendererAbstract
>>>>>>>> class
>>>>>>>> that takes a WaveformMark and draws it to the screen when its turn
>>>>>>>> comes.
>>>>>>>>
>>>>>>>> A waveform widget has a stack of WaveformRendererAbstract classes
>>>>>>>> in a list that are drawn one after the other -- they're like layers. A
>>>>>>>> typical waveform widget's render stack looks like this:
>>>>>>>>
>>>>>>>> * background (WaveformRenderBackground)
>>>>>>>> * end of track highlight (WaveformRendererEndOfTrack)
>>>>>>>> * preroll drawing (WaveformRendererPreroll)
>>>>>>>> * mark range (green loop highlight) rendering
>>>>>>>> (WaveformRenderMarkRange)
>>>>>>>> * signal rendering (the waveform itself -- a class named something
>>>>>>>> like WaveforRenderXXXSignalXXX depending on the widget)
>>>>>>>> * beat rendering (WaveformRenderBeat)
>>>>>>>> * hotcue / cue / loop in-out point rendering (WaveformRenderMark)
>>>>>>>>
>>>>>>>> So WaveformRenderMark uses WaveformMark as a description of what to
>>>>>>>> draw. WaveformMark doesn't have access to the track that's loaded while
>>>>>>>> WaveformRenderMark can get access. Here's an example from
>>>>>>>> WaveformRenderBeat:
>>>>>>>>
>>>>>>>>
>>>>>>>> https://github.com/mixxxdj/mixxx/blob/master/src/waveform/renderers/waveformrenderbeat.cpp#L41
>>>>>>>>
>>>>>>>> One tricky bit is that WaveformRenderMark pre-generates a pixmap
>>>>>>>> that is drawn during the render step as a performance optimization. In
>>>>>>>> the
>>>>>>>> draw method of WaveformRenderMark you should set the text of the
>>>>>>>> currently
>>>>>>>> loaded cue point's label (you can fetch the cues from the track with
>>>>>>>> TrackInfoObject::getCues) on the WaveformMark (via some new method you
>>>>>>>> add). If the label changed since the last render then you'll need to
>>>>>>>> re-generate the pixmap.
>>>>>>>>
>>>>>>>> Hope that gets you started,
>>>>>>>> RJ
>>>>>>>>
>>>>>>>> On Fri, Jan 9, 2015 at 6:02 PM, Ferran Pujol Camins <
>>>>>>>> ferranpujolcam...@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Now I want the hotcue marks to show their cue's name. I see in
>>>>>>>>> WaveformMark::setKeyAndIndex that m_text place marker is replaced by
>>>>>>>>> the
>>>>>>>>> hotcue number so I could just append the cue's label there. But I
>>>>>>>>> have no
>>>>>>>>> clue about how to bring the hotcue name to this function. Some quick
>>>>>>>>> guidance with the waveform rendering system will help a lot :)
>>>>>>>>>
>>>>>>>>> 2015-01-09 20:31 GMT+01:00 Ferran Pujol Camins <
>>>>>>>>> ferranpujolcam...@gmail.com>:
>>>>>>>>>
>>>>>>>>>> Thank you both I have a better picture now. :)
>>>>>>>>>>
>>>>>>>>>> 2015-01-09 19:55 GMT+01:00 RJ Ryan <russelljr...@gmail.com>:
>>>>>>>>>>
>>>>>>>>>>> This doc is a bit out of date now (doesn't cover
>>>>>>>>>>> ControlObjectSlave) but it gives the overview of what the heck
>>>>>>>>>>> ControlObject is used for in Mixxx:
>>>>>>>>>>>
>>>>>>>>>>> http://mixxx.org/wiki/doku.php/developer_guide_control
>>>>>>>>>>>
>>>>>>>>>>> See also: http://mixxx.org/wiki/doku.php/developer_guide
>>>>>>>>>>>
>>>>>>>>>>> On Fri, Jan 9, 2015 at 6:19 AM, Daniel Schürmann <
>>>>>>>>>>> dasch...@mixxx.org> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi Ferran,
>>>>>>>>>>>>
>>>>>>>>>>>> do not know what exactly you need.
>>>>>>>>>>>>
>>>>>>>>>>>> ControlDoublePrivate is th container that holds the double data
>>>>>>>>>>>> value for atomic read and writes (also on 32 bit targets).
>>>>>>>>>>>> The ControlObject is the interface, you can use from your code
>>>>>>>>>>>> that holds a reference to the ControlDoublePrivate.
>>>>>>>>>>>>
>>>>>>>>>>>> ControlObject should be used to create a new
>>>>>>>>>>>> ControlDoublePrivate and should only be used from one object (You
>>>>>>>>>>>> will find
>>>>>>>>>>>> exceptions in the legacy engine code)
>>>>>>>>>>>>
>>>>>>>>>>>> All other Objects should use the ControlObjectSlave to access
>>>>>>>>>>>> the underlying ControlDoublePrivate.
>>>>>>>>>>>>
>>>>>>>>>>>> Hope that helps.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Kind regards,
>>>>>>>>>>>>
>>>>>>>>>>>> Daniel
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 2015-01-09 11:16 GMT+01:00 Ferran Pujol Camins <
>>>>>>>>>>>> ferranpujolcam...@gmail.com>:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hello, could someone give me a short explanation about how
>>>>>>>>>>>>> ControlObject and ControlDoublePrivate interact? I'm quite
>>>>>>>>>>>>> confused right
>>>>>>>>>>>>> now and it would help me digest the code quicker.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>>> Dive into the World of Parallel Programming! The Go Parallel
>>>>>>>>>>>>> Website,
>>>>>>>>>>>>> sponsored by Intel and developed in partnership with Slashdot
>>>>>>>>>>>>> Media, is your
>>>>>>>>>>>>> hub for all things parallel software development, from weekly
>>>>>>>>>>>>> thought
>>>>>>>>>>>>> leadership blogs to news, videos, case studies, tutorials and
>>>>>>>>>>>>> more. Take a
>>>>>>>>>>>>> look and join the conversation now.
>>>>>>>>>>>>> http://goparallel.sourceforge.net
>>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>>> Get Mixxx, the #1 Free MP3 DJ Mixing software Today
>>>>>>>>>>>>> http://mixxx.org
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Mixxx-devel mailing list
>>>>>>>>>>>>> Mixxx-devel@lists.sourceforge.net
>>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/mixxx-devel
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>>>>> Dive into the World of Parallel Programming! The Go Parallel
>>>>>>>>>>>> Website,
>>>>>>>>>>>> sponsored by Intel and developed in partnership with Slashdot
>>>>>>>>>>>> Media, is your
>>>>>>>>>>>> hub for all things parallel software development, from weekly
>>>>>>>>>>>> thought
>>>>>>>>>>>> leadership blogs to news, videos, case studies, tutorials and
>>>>>>>>>>>> more. Take a
>>>>>>>>>>>> look and join the conversation now.
>>>>>>>>>>>> http://goparallel.sourceforge.net
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Get Mixxx, the #1 Free MP3 DJ Mixing software Today
>>>>>>>>>>>> http://mixxx.org
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Mixxx-devel mailing list
>>>>>>>>>>>> Mixxx-devel@lists.sourceforge.net
>>>>>>>>>>>> https://lists.sourceforge.net/lists/listinfo/mixxx-devel
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Ferran Pujol Camins
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Ferran Pujol Camins
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Ferran Pujol Camins
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Ferran Pujol Camins
>>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Ferran Pujol Camins
>>>>
>>>
>>>
>>
>>
>> --
>> Ferran Pujol Camins
>>
>
>
>
> --
> Ferran Pujol Camins
>
------------------------------------------------------------------------------
New Year. New Location. New Benefits. New Data Center in Ashburn, VA.
GigeNET is offering a free month of service with a new server in Ashburn.
Choose from 2 high performing configs, both with 100TB of bandwidth.
Higher redundancy.Lower latency.Increased capacity.Completely compliant.
http://p.sf.net/sfu/gigenet
_______________________________________________
Get Mixxx, the #1 Free MP3 DJ Mixing software Today
http://mixxx.org
Mixxx-devel mailing list
Mixxx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mixxx-devel