Thomas Goyne
a01a84fb4f
Extract some common ffi API stuff
2014-07-28 12:30:44 -07:00
Thomas Goyne
0cf35894e1
Convert the lfs module to using the ffi
2014-07-28 12:30:44 -07:00
Thomas Goyne
4f08afd808
Convert the unicode lua module over to using the ffi
2014-07-28 12:30:44 -07:00
Thomas Goyne
cf252fa91a
Add simple type -> type name string compile time reflection stuff
...
This is needed for passing types to the LuaJIT ffi.
2014-07-28 12:30:44 -07:00
Thomas Goyne
de686bdb6f
Remove the automation thread priority stuff
...
It hasn't actually been used for anything for a while, and if a single
normal-priority thread can make your system unresponsive it's time to
upgrade to an OS that's isn't garbage.
2014-07-23 15:29:55 -07:00
Thomas Goyne
0cc941e559
Use wx events for invoking on the main thread on OS X
...
Dispatching to the main queue with GCD does not work when there is a
modal dialog active.
2014-07-23 15:29:55 -07:00
Thomas Goyne
584284aa79
Reject vfr timecodes which are all identical
2014-07-15 09:11:40 -07:00
Thomas Goyne
897f9d1254
Eliminate some warnings
2014-07-14 10:10:22 -07:00
Thomas Goyne
97c59e2630
Fix non-pch compilation
2014-07-14 10:10:22 -07:00
Thomas Goyne
92b8b2851b
Don't build the dialogue lexer on every use
...
Building the lexer takes much longer than actually lexing, and since the
lexer is stateless there's no reason not to just make it static.
2014-07-14 10:10:22 -07:00
Thomas Goyne
706a72d5c1
Eliminate several memory allocations per line when reading thesaurus files
2014-07-14 10:10:21 -07:00
Thomas Goyne
bffbae0ed9
Fix vc++ compilation
2014-07-10 12:55:38 -07:00
Thomas Goyne
a5c2ef273f
Add tests for floating point sample conversion
2014-07-10 11:44:56 -07:00
Thomas Goyne
f32bdff84a
Add tests for the sample doubling converter and make it work correctly
2014-07-10 11:44:56 -07:00
Thomas Goyne
93ad15efb1
Reuse the decoding buffer in the audio converters
2014-07-10 11:44:56 -07:00
Thomas Goyne
b9c75d8706
Add tests for the audio bitdepth conversions
...
And fix some bugs in it, and make it not rely on undefined behavior.
2014-07-10 11:44:56 -07:00
Thomas Goyne
585e9489d9
Move some of the audio provider machinery to libaegisub
...
And add tests.
2014-07-10 11:44:56 -07:00
Thomas Goyne
e713f741a4
Make some functions static
2014-07-08 16:38:16 -07:00
Thomas Goyne
a58ed7343d
Add Aegisub's include dirs before the system ones rather than after
2014-07-07 09:42:02 -07:00
Thomas Goyne
a11da3350c
Save a backup copy of the old hotkey file if migrating from the old format
2014-07-07 09:42:02 -07:00
Thomas Goyne
365c04333c
Install the unicode-compatible Lua module loader before loading moonscript
...
Closes #1760 .
2014-07-07 09:23:36 -07:00
Thomas Goyne
935c6bc3a7
Store hotkeys in a less dumb format
2014-07-06 19:25:49 -07:00
Thomas Goyne
3b34ed9a77
Move AssTime to libaegisub and add tests
2014-07-06 19:25:49 -07:00
Thomas Goyne
f0f836c47b
Eliminate a pointless std::map in charset_conv
2014-07-06 19:25:48 -07:00
Thomas Goyne
a22dd0f9ca
Clean up the json parser a little
2014-07-06 19:25:48 -07:00
Thomas Goyne
d9016cc8ea
Debloat and slightly speed up the MRU code
2014-07-06 19:25:48 -07:00
Thomas Goyne
518342b919
Make the hotkey code a bit less bloated
2014-07-06 19:25:48 -07:00
Thomas Goyne
df8ad34838
Eliminate pointless runtime datastructures for CalltipProvider
...
And add some tests and make it actually work correctly.
2014-07-04 20:37:36 -07:00
Thomas Goyne
93522e30a8
Use a static table of tokens for agi::Path
...
The set of possible tokens is fixed, so using std::map is a bunch of
pointless overhead (that turns out to not even really simplify the
code).
2014-07-04 20:37:36 -07:00
Thomas Goyne
6ce9ce1546
Remove unused helper function
2014-07-03 10:57:53 -07:00
Thomas Goyne
4c88449e4c
Make UnknownElement moveable and not copyable
...
And remove the unused comparison functionality.
2014-06-29 10:45:26 -07:00
Thomas Goyne
4c0e578eda
Rewrite the remaining bits of json::Writer
2014-06-29 10:45:26 -07:00
Thomas Goyne
bc410a99f6
Change the in-memory storage of options to a sorted vector
2014-06-29 10:01:00 -07:00
Thomas Goyne
c9608ab610
Remove an exception not used for anything useful
2014-06-28 19:49:39 -07:00
Thomas Goyne
0153987e02
Eliminate warnings in lpeg
2014-06-24 09:06:32 -07:00
Thomas Goyne
68eaab0f43
Convert the build system to non-recursive make
...
Speeds up a no-op build from 500ms to 60ms and significantly improves
dependency tracking.
2014-06-17 11:37:20 -07:00
Thomas Goyne
7780fadfc6
Fix restarting the application after changing the UI language on OS X
2014-06-14 06:51:53 -07:00
Thomas Goyne
789ff25f27
Remove some exceptions not used for much of anything
2014-06-11 12:52:30 -07:00
Thomas Goyne
cfd2698b03
Use NSSpellChecker rather than hunspell on OS X
...
Main benefit is it removes the need to ship 50 MB of dictionaries.
2014-06-11 12:33:09 -07:00
Thomas Goyne
6500b379bd
Remove all distfile stuff from the build system
...
It's unused and out of date.
2014-06-09 17:20:56 -07:00
Thomas Goyne
056a775751
Set ?dictionary to the correct thing on OS X. Closes #1766 .
2014-06-08 08:00:11 -07:00
Thomas Goyne
882e6894ff
Use GCD on OS X rather than boost.asio for the thread pool
2014-06-07 08:48:40 -07:00
Thomas Goyne
421d5ca52e
Add #ifdef __cplusplus to the precompiled headers to make Xcode happy
2014-06-05 08:35:50 -07:00
Thomas Goyne
47303007eb
Remove the ?docs token
...
It's not actually used anywhere and not even set on Windows.
2014-06-04 14:15:26 -07:00
Thomas Goyne
eebd1dba21
Use iconv rather than std::wstring_convert
...
libstdc++ 4.8 does not have <codecvt>.
2014-05-30 11:53:15 -07:00
Thomas Goyne
59489b8f8c
Extract some of the string formatter implementation to format.cpp
2014-05-30 11:53:15 -07:00
Thomas Goyne
37c02ae127
Replace wxString::Format with agi::format
...
It's modestly faster, significantly more type-safe, and doesn't assert
when there's too few arguments, which causes problems for plural forms.
Closes #1733 .
2014-05-30 11:53:14 -07:00
Thomas Goyne
8d26c66d0f
Remove a bunch of unused functionalty from agi::Exception
2014-05-30 11:53:14 -07:00
Thomas Goyne
b43788fa7f
Replace boost::format with agi::format
...
boost::format is slow to compile, slow to run, and has an unpleasant
interface.
2014-05-30 08:30:31 -07:00
Thomas Goyne
8ba286c544
Fix moving files to the front of the MRU list
2014-05-30 08:30:31 -07:00
Thomas Goyne
72748d45f7
Fix crash on v1 timecode files with zero override ranges
2014-05-30 08:30:31 -07:00
Thomas Goyne
eec83bb32b
Cut down on FileNotFound exceptions thrown on startup
2014-05-27 06:42:46 -07:00
Thomas Goyne
d08f4e73b4
Only check for permissions if opening a file fails
2014-05-27 06:42:46 -07:00
Thomas Goyne
4da1443194
Store connected slots in a vector rather than a map
2014-05-26 09:34:20 -07:00
Thomas Goyne
6c685daf98
Ditch boost.circular_buffer
...
It drags in a ton of crap, is kinda slow at runtime due to using
std::deque, and doesn't actually make the code much simpler than just
using a manual ring buffer.
2014-05-26 09:34:19 -07:00
Thomas Goyne
1f7c47239b
Replace timeval junk with std::chrono
2014-05-26 09:34:19 -07:00
Thomas Goyne
650cfcb043
Remove a bunch of unused crap from lagi_pre.h
2014-05-26 09:34:19 -07:00
Thomas Goyne
50f2e550e2
Use std::thread with libc++
...
boost::thread is only used due to libstdc++ 4.8 missing a bunch of
stuff.
2014-05-26 09:34:19 -07:00
Thomas Goyne
6477ef933b
Use std::to_string rather than boost::lexical_cast
2014-05-26 09:34:19 -07:00
Thomas Goyne
41297e5ace
Remove non-spirit uses of boost.phoenix
...
The slightly more concise code is not worth the compilation speed hit.
2014-05-26 09:34:19 -07:00
Thomas Goyne
fed99649e9
Cut down on pointless uses of std::list
2014-05-26 09:34:19 -07:00
Thomas Goyne
8ec9280ecc
Change most uses of deques to vectors
2014-05-26 09:34:18 -07:00
Thomas Goyne
20a7ec786f
Use initializer lists rather than std::make_pair
2014-05-26 09:34:18 -07:00
Thomas Goyne
9d3067ae75
Return absolute paths for files in project_properties()
2014-05-23 07:28:26 -07:00
Thomas Goyne
09e325a1c3
Clean up unused includes
2014-05-23 07:28:24 -07:00
Thomas Goyne
19e8f19e52
Redesign project file handling
...
Add a new Project class which is responsible for everything related to
opening and closing audio, video, subtitles, timecodes and keyframes.
This pulls almost everything not directly related to playing audio/video
out of the audio and video controllers, pulls more crap out of
FrameMain, and happens to make things a little simpler in the process.
2014-05-22 09:29:12 -07:00
Thomas Goyne
deaf833605
Preserve alpha when resampling style colors
2014-05-22 06:14:56 -07:00
Thomas Goyne
53f02d33a6
Fix a bunch of warnings when building with gcc on linux
2014-05-20 09:46:57 -07:00
Thomas Goyne
291437eed6
Handle ftruncate failures
2014-05-20 09:46:57 -07:00
Thomas Goyne
ad33fdb109
Add color matrix conversion to the resolution resampler
2014-05-19 19:32:25 -07:00
Thomas Goyne
cddefd8ed9
Add RGB <-> YCbCr conversion stuff to libaegisub
2014-05-19 19:32:25 -07:00
Thomas Goyne
94a060a556
Add unicode case conversion functions to the automation module
2014-05-09 07:00:48 -07:00
Thomas Goyne
eadf555da3
Pass exceptions in async workers back to the main thread
2014-05-09 07:00:48 -07:00
Thomas Goyne
b4d49511be
Fix ignoring override blocks for CPS calculations
2014-05-08 12:34:04 -07:00
Thomas Goyne
f261688b11
Don't ignore the contents of override blocks when counting characters for selection preserving
2014-05-05 06:27:37 -07:00
Thomas Goyne
431b096f51
Fix loading modules with UTF-8 BOMs
...
Ensure MoonScript gets loaded before we install our package loader to
avoid having its package loader used over ours.
2014-04-28 14:19:16 -07:00
Thomas Goyne
a5a6d5da86
Restore the BOM-skipping logic to the Lua script reader
...
And add BOM to one of the test files to verify it works.
2014-04-28 10:21:54 -07:00
Thomas Goyne
63f4bf1beb
Switch from regular Lua to LuaJIT
2014-04-28 07:38:30 -07:00
Thomas Goyne
ec4a8c9a26
Fix read from before beginning of stack
2014-04-27 21:23:53 -07:00
Thomas Goyne
b4de0b9b82
Fix crash on zero-length lua files
2014-04-27 21:23:52 -07:00
Thomas Goyne
9492192b73
Switch back to building Lua as C
...
In preparation for switching to LuaJIT, which doesn't support PUC Lua's
thing of using C++ exceptions for lua_error.
Requires replacing all uses of lua_error (and things calling lua_error)
with custom versions that throw an exception instead and adding an
exception -> lua error wrapper at all C++ -> Lua boundaries.
2014-04-27 10:37:23 -07:00
Thomas Goyne
e3eb28ffd1
Extract some duplicated table pushing code
2014-04-27 09:15:35 -07:00
Thomas Goyne
689c16deb3
Use lua_createtable where applicable
2014-04-27 09:15:35 -07:00
Thomas Goyne
5cde33c8d5
Reimplement the useful parts of lfs
...
It doesn't support Unicode on Windows, so replace it with a
reimplementation using boost.filesystem that does, but skip all the
useless junk.
2014-04-26 08:16:39 -07:00
Thomas Goyne
2adcc76cf6
Switch automation tests to busted
...
This requires shuffling a bunch of stuff around to get a CLI lua
executable that uses an automation-like environment, but that's
something that'll be nice to have in the future anyway.
Busted indirectly depends on lfs and we currently can't use external
binary modules, so add a copy of lfs to the repo and build it with
Aegisub.
2014-04-26 08:16:38 -07:00
Thomas Goyne
b8af29da0d
Move some of the automation machinery to libaegisub
2014-04-25 15:03:18 -07:00
Thomas Goyne
15ae2b0ccc
Eliminate a bunch of explicit constructors/destructors
...
Use explicitly defaulted destructors for base cases when possible,
eliminate aggregate initialization constructors where possible, and push
some more stuff to NSDMIs.
2014-04-25 14:53:24 -07:00
Niels Martin Hansen
d53c36e67f
Merge branch 'extradata'
...
Conflicts:
src/ass_parser.cpp
2014-04-25 17:22:15 +02:00
Thomas Goyne
d4fbe3040d
Preserve the insertion point (but not selection) when switching between lines
2014-04-25 08:00:45 -07:00
Niels Martin Hansen
f278c35f3f
Dynamically use either inline_string escaping or uuencoding for extradata
...
Since luabins generates binary data which grows up to 3x by escaping,
it's more efficient to uuencode that instead.
A marker is placed as the first character of the value field, either
'e' for inline_string escaped text, or 'u' for uuencoded binary data.
The key is always inline_string escaped, as it will typically be
human readable.
2014-04-25 16:04:08 +02:00
Thomas Goyne
7f289551ae
Remove -Wno-variadic-macros from CXXFLAGS
...
It's no longer nonstandard in C++11.
2014-04-23 15:29:23 -07:00
Thomas Goyne
6fc4c8da14
Move make_unique to its own header file
...
Rebuilding the entire project after touching util.h gets old fast.
2014-04-23 15:29:23 -07:00
Thomas Goyne
a30d6121fd
Don't block the UI while decoding audio for the caches
...
Simply zero the memory for audio which hasn't been decoded yet, modify
the audio renderer to avoid caching blocks which aren't ready yet, and
add a progress indiciator to the audio display scrollbar.
2014-04-22 12:34:20 -07:00
Thomas Goyne
6c6f60eb98
Add an option to ignore punctuation for the character counter
2014-04-18 20:11:38 -07:00
Thomas Goyne
2de95818db
Use ICU directly for character counting
...
ICU docs say not to create a new break iterator each time as
boost.locale does, and in fact creating the break iterator is about 90%
of the run time of the character counter, so use ICU directly and cache
the break iterator.
2014-04-18 20:11:38 -07:00
Thomas Goyne
af32733797
Move character count stuff to libaegisub
2014-04-18 20:11:38 -07:00
Thomas Goyne
5df871f599
Extract all of the column-specific logic from BaseGrid
2014-04-18 12:17:03 -07:00
Thomas Goyne
56699e4800
Mark move constructors as noexcept
...
Or just default them for non-MSVC when possible.
2014-04-17 11:46:28 -07:00
Thomas Goyne
09d0d039e0
Convert signal.h to variadic templates
2014-04-17 11:46:27 -07:00
Thomas Goyne
c8033c2ef7
Initialize the charset converter for the thesaurus sooner
...
Narrows the window of time for a crash-on-exit when the user exits while
a thesaurus is being loaded.
2014-04-16 08:15:31 -07:00