summaryrefslogtreecommitdiff
path: root/src/lib/j2k_encoder.cc
AgeCommit message (Collapse)Author
2025-12-31Remove now-unused video_frames_enqueued().Carl Hetherington
2025-12-31Add missing call to frame_done().Carl Hetherington
2025-12-31White space: j2k_encoder.{cc,h}Carl Hetherington
2025-12-05Cleanup: can now remove the _NC log variants.Carl Hetherington
2025-10-10Allow Waker to keep different things awake for different reasons.Carl Hetherington
2025-07-10Remove compose.hpp includes.Carl Hetherington
sed -i "/include.*compose.hpp/d;" src/lib/*.cc src/wx/*.cc src/wx/*.h src/tools/*.cc src/lib/*.h test/*.cc
2025-07-10Replace String::compose with fmt.Carl Hetherington
sed -i "/Plural-Forms/n;/%100/n;/scanf/n;s/%[123456789]/{}/g" src/lib/*.cc src/lib/*.h src/wx/*.cc src/tools/*.cc src/lib/po/*.po src/wx/po/*.po src/tools/po/*.po test/*.cc sed -i "s/String::compose */fmt::format/g" src/lib/*.cc src/lib/*.h src/wx/*.cc src/tools/*.cc test/*.cc
2025-03-08Don't use an optional for the Grok config object.Carl Hetherington
I'm not sure why I did it like this in the first place - perhaps so that if the API endpoint changes there aren't so many old values stuck in config files all over the place? Anyway, it seems cleaner to do it like this, as it's how we handle the other config.
2024-12-24Replace assertion with a softer fix.Carl Hetherington
Had a report of this assertion tripping with "only servers encode" switched on. The user had encode servers but they were running old software, so wouldn't be enabled for use. Obviously the main DCP-o-matic should not crash in this situation.
2024-12-24Log things used to decide on thread counts.Carl Hetherington
2024-12-18Fix hang when encoding with GPU enabled but not working.Carl Hetherington
2024-12-09Assert if we're about to set up 0 encoding threads.Carl Hetherington
2024-11-29Abort encode if Grok encoder threads are failing (#2899)Carl Hetherington
2024-05-08Merge remote-tracking branch 'origin/main' into v2.17.xCarl Hetherington
2024-05-08Work around deadlock when destroying J2KEncoder with a full writer queue ↵v2.16.83Carl Hetherington
(#2784). This feels like a hack, but I can't think of a nicer way to do it. The interruption disable makes sense because when we destroy encoder threads during a DCP encode (because a remote server goes away, for example) we don't want any frames to be lost due to the encode thread being interrupted between taking the frame off the queue and sending it to the writer. When we're destroying the encoder we don't care about this, but I can't see how you'd differentiate. Maybe the encoder queue could have two lists: to-do and in-progress; the encoder thread atomically moves a frame from to-do to in-progress, but then how do you know when the in-progress ones are orphaned and need to be re-added to the main queue. You could make the writer return saying "no" if the queue is full (rather than blocking and waiting for the queue to empty) but that seems wasteful as then the frame would be re-encoded.
2024-04-22Allow specification of video bit rate separately for J2K and MPEG2.Carl Hetherington
2024-04-21Rename j2k_bandwidth -> video_bit_rate.Carl Hetherington
2024-04-21Extract VideoEncoder as a parent of J2KEncoder.Carl Hetherington
2024-01-28Swap a log for a more informative one.Carl Hetherington
2024-01-28Clean up grok's presence in the config file and make sure it's optional.Carl Hetherington
It should be allowed to not have any grok stuff in the config file, and we should generally call it grok rather than GPU in case other non-grok GPU stuff arrives in the future.
2024-01-28Another patch from Aaron.Carl Hetherington
2024-01-28Forward-declare grk_plugin stuff.Carl Hetherington
2024-01-28Create a single DcpomaticContext for all GrokContexts, rather than copying them.Carl Hetherington
I think this makes sense, and also allows us to forward-declare the contexts in a forthcoming commit.
2024-01-28Only build grok for Ubuntu 22.04.Carl Hetherington
2024-01-28Explicitly set up Grok logger rather than relying on a static variable.Carl Hetherington
2024-01-28Rearrange encoder threading.Carl Hetherington
Soon we'll add a new encoder type, and the existing structure was already creaking a bit at the seams while handling local and remote encodes. Here we split out an encoder thread and introduce the concept of a "sync" thread (which blocks while the encoding is happening). Later we'll have another type which submits the encode request to a GPU and receives the reply back later.
2024-01-28Remove check for _threads being null, as I think it should not happen.Carl Hetherington
2024-01-28Cleanup: white space.Carl Hetherington
2024-01-28Cleanup: white space tidying.Carl Hetherington
2024-01-28Change end() to only do one thing, and copy the required stuff into pause()Carl Hetherington
2024-01-28Formatting, variable name tidying and some const correctness.Carl Hetherington
2024-01-28Patch from Aaron Boxer adding initial support for GPU-powered J2K encoding ↵Carl Hetherington
via his tool "grok".
2023-11-23Update servers list after connecting to the signal.Carl Hetherington
Otherwise it can happen that a signal is emitted before we connect to it, and then after that no more signals come because nothing changes.
2022-10-17Remove some unnecessary use of shared_ptr.Carl Hetherington
2022-09-27Use EnumIndexedVector in J2KEncoder.Carl Hetherington
2022-09-10Trim some includes.Carl Hetherington
2022-07-15Fix failure to destroy the J2KEncoder when an encode fails/is cancelled.Carl Hetherington
2022-05-02It doesn't seem necessary to use shared_ptr for the DCPVideo queue in ↵v2.16.x-oldCarl Hetherington
J2KEncoder.
2022-04-03C++11 and whitespace cleanups.Carl Hetherington
2021-04-21Add some possibly-useful markers for debugging threads from coredumps.Carl Hetherington
2021-04-08Assorted C++11/formatting cleanups.Carl Hetherington
2021-01-31More enum class additions.Carl Hetherington
2021-01-11More c++ tidying.Carl Hetherington
2021-01-07BOOST_FOREACH.Carl Hetherington
2021-01-07std::shared_ptrCarl Hetherington
2020-12-05Fix transcode finish time estimations when re-encoding a DCP (#1863).Carl Hetherington
2020-11-26It feels unsafe not to lock _threads_mutex between terminate_threads()Carl Hetherington
and _threads.reset(); move the lock.
2020-11-04Re-add mutex that was taken away inCarl Hetherington
73ebb92e9df01ba7afb97121b6e2cef6ca13a18e I'm not sure why it was removed, and it seems necessary; servers_list_changed() can be called from a variety of different places (the constructor and two different EncodeServerFinder threads). May help with #1854.
2020-11-02Pass around JPEG2000 data as a shared_ptr and hence avoid a copyCarl Hetherington
of 4MB of data for every JPEG2000 frame we decode.
2020-09-12Remove support for Windows XP.Carl Hetherington