Helge Norberg [Wed, 8 Mar 2017 19:24:49 +0000 (20:24 +0100)]
[color_producer] Added support for gradients. Simply done via OpenGL's bilinear filtering. Instead of one large pixel, it can produce several large pixels in a row with different colors.
Helge Norberg [Wed, 8 Mar 2017 18:46:35 +0000 (19:46 +0100)]
[audio_mixer] Removed requirement of all samples for a frame to be present in field1 while ignoring samples in field2. Now both samples from field1 and field2 contribute to the audio stream.
Helge Norberg [Tue, 28 Feb 2017 17:14:24 +0000 (18:14 +0100)]
[frame_producer] Created workaround for bug in FFmpeg where every new thread used to cleanup causes handles to leak (not sure why). Reduced the effect by using only one thread for all producer destructions.
Helge Norberg [Thu, 23 Feb 2017 13:33:29 +0000 (14:33 +0100)]
[decklink_consumer] #539 #285 #521 Fixed serious deadlock in decklink_consumer where a race condition between pop and acquisition of mutex left a window where an other thread could acquire the lock. Rewrote the whole thing in a better way.
Helge Norberg [Mon, 20 Feb 2017 18:29:15 +0000 (19:29 +0100)]
[scene_producer] Added possibility to CALL/CG PLAY/CG STOP/CG NEXT/CG INVOKE layers in a scene either at a specific timeline frame or whenever any bool expression becomes true
Helge Norberg [Mon, 20 Feb 2017 18:13:31 +0000 (19:13 +0100)]
[CG] Created producer that wraps a CG producer in a way that it can be treated as a normal producer and also integrates well on a layer in a scene instance
James Wise [Mon, 13 Feb 2017 03:27:27 +0000 (14:27 +1100)]
Buffer Depth stuff:
new defined values:
BLUEFISH_HW_BUFFER_DEPTH 1
BLUEFISH_SOFTWARE_BUFFERS 4
To easily set the HW buffer depth, and number of software buffers used.
Previous setting of 3 for the HW buffer depth has been reduced to 1,
since almost all hardware tested shows that 1 is sufficient.
( very old machines with poor PCI performance may struggle with a buffer of just 1)
bluefish_consumer_proxy::buffer_depth now returns the correct value,
ie. BLUEFISH_HW_BUFFER_DEPTH
( i have tested this via taking a pic of both screen and SDI display, and confirming that they both display the same frame,
I hope this is the correct use/interpretation of this value)
Queue, Mutex and thread stuff:
Changed the std::queue and std::mutex to use tbb:concurrent_counded_queue, as suggested.
This has greatly simplified the code by removing the mutex's and associated lock/unlock calls.
made the end_dma_thread bool, tbb::atomeic too - should have always been marked as such, or at least volatile.
also added code to specifically set the maximum size for the tbb concurrent queue
Mofified the way we allocate the std::thread for the DMA and present.
thread is now a class member which makes things a bit cleaner too.
removed the mutex and lock stuff from this too.
Startup uses the Dfeined buffer value from top of file.
Routing and card config:
Minor change to the way we woncfigure routing on neutron cards when using the hw keyer, 2nd link ie. the fill only now gets routed correctly.
Hardware Keyer:
Now using the correct Macro to setup the hw Keyer,
Be aware the terminology can be confusing as the the macro refers to the source data, not the process to be applied.
This has been tested with the casper 1080_test.tga file and produces the correct output.
Ie. we see the following text in white.
"Alpha / Key correct: Premultipled
Linear / Additive"
James Wise [Fri, 10 Feb 2017 00:40:33 +0000 (11:40 +1100)]
Implmented a new system to manage to DMA and presenting of frames when using the bluefish hadrware.
This system uses FIFO mode on the hadware which allows for some degree of buffering on the card.
Frames are copied from caspar to a internal Q, a seperate thread then extracts frames from the Q, and does the DMA and present calls.
This system removes our DMA from the core loop of Caspar, and allows up to a full frames time to be used for the DMA.
- Important when using multiple channels.
Moved the Wait for Sync caLl to happen after the Memcopy, this should create a more stable sync time.
No longer need to set the executor thread to high priority, but setting the std::thread that i am using for the DMA to highest priority.
This change results in much better performance when doing multiple streams.
This change required some additional functions to be added to the blue_velvet.h/cpp files too,
to properly support the FIFO playback mode.
Also minor change to tell the Keyer that data is pre-multiplied when we receive it.
James Wise [Wed, 8 Feb 2017 05:53:00 +0000 (16:53 +1100)]
Changes to support the new way of setting bluefish properties.
now using a,b,c,d for channel selectiong and the keyer property to determine 422, v 4224v interna hardware keyer usage and configuration.
Changes to the casparcg.config file reflect this and provide limited documentation of usage.
aslo changed the executor priority to be highest possible, as this is required for the thread that the DMA happens on.
(building of scatter gather table and actual DMA should never yield to a less important thread)
Helge Norberg [Tue, 7 Feb 2017 18:32:02 +0000 (19:32 +0100)]
[scene] Initial work in progress XML Schema for creating Scene producer XML files. Allows for auto completion/validation/online documentation with a good XML editor
James Wise [Mon, 6 Feb 2017 22:33:58 +0000 (09:33 +1100)]
Modify the init of the function ptrs to be in the header instead of in the init_funtion_pointers func.
(stupid, dont know why i didn't do this in the first place...)
James Wise [Fri, 3 Feb 2017 04:54:11 +0000 (15:54 +1100)]
Update previous files to be more in line with CasparCG coding styles.
removed almost all sue of CamelCase, now using all smalls and underscores where possible.
Many fixes according to suggestions from @HellGore,
Including but not limited to:
Better use of RAII and shared ptr objects.
Removal of unrequired functions
Removal of system that checks if a driver is present before adding a bluefish consumer to registry.
Removal of static get/set card property funcs
Init'ing all functions ptr to nullptr.
NOT done yet:
possible modification of argument name
James Wise [Sun, 29 Jan 2017 18:02:32 +0000 (05:02 +1100)]
Add new files to the Bluefish module.
New Dir - interop, contains all the headers required to build the bluefish module.
Also updated to use latest version of these header file, and now using the BlueVelvetC and BlueVelvetCUtils interface, instead of older depreceated one.
James Wise [Sun, 29 Jan 2017 17:59:08 +0000 (04:59 +1100)]
Modifications to the files within the Bluefish module.
Changed the Bluefish internal stuff to use the BlueVelvetC API.
Now using an internal class ( BVCWrapper) that contains function pointers, so module will only get loaded if BF hardware and driver is present.
Updated inner workings to better support latest and different version of bluefish hardware.
Added support for using multiple channels
Added support multiple cards.
Added support for using the onboard keyer
Improved routing and configuration.
walterav1984 [Sun, 29 Jan 2017 13:10:42 +0000 (14:10 +0100)]
dirty hack replace shipped ffmpeg linux libs with compiled ones!
If this is done prior to building CasparCG Server with "/build-scripts/set-variables-and-build-linux.sh" building will include the custom ffmpeg version!
Helge Norberg [Fri, 27 Jan 2017 18:43:29 +0000 (19:43 +0100)]
[build] Added the modified build script based on an old version of https://github.com/zimbatm/ffmpeg-static that has been used to build the Linux ffmpeg binaries
Helge Norberg [Fri, 27 Jan 2017 16:26:36 +0000 (17:26 +0100)]
[image_mixer] #486 Fixed bug where glReadPixels() was done from the last drawn to texture instead of always from the target texture. This means that for example a MIXER KEYER layer without a layer above to key, as well as a separate alpha file with MIXER OPACITY 0 now works as expected