Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
This patch fixes many minor spelling mistakes, all in comments or
console output. Mostly contractions like can't, won't, don't, its/it's,
etc.
Differential Revision: https://developer.blender.org/D11663
Reviewed by Harley Acheson
|
|
Current convention is not to use this term, use "current frame",
and "timeline frame" in render.c as this is the argument passed in.
|
|
Remove `seq->tmp` usage from transform code. It was used to tag strips
that need to be "shuffled". Pass these strips in `SeqCollection`
instead.
Reviewed By: sergey, mano-wii
Differential Revision: https://developer.blender.org/D11631
|
|
Reduce complexity of sequencer transform code by removing recursivity.
This is possible by treating meta strips (mostly) as any other strip and
containing all transform code within SEQ_ functions.
Unfortunately internally meta strips still require special treatment,
but all complexity from code all over transform code seems to be
possible to contain within one function.
Functional change:
Previously adjusting handle of single image strip moved animation.
Now animation is not moved, which is behavior for all other strips.
Reviewed By: sergey, mano-wii
Differential Revision: https://developer.blender.org/D11493
|
|
Use lookup string callback function for `sequences_all` RNA property
`rna_SequenceEditor_sequences_all_lookup_string` using a GHash for faster lookups.
When names are changed or strips are added/removed the lookup is tagged invalid.
The next time the lookup is used it will rebuild it.
Reviewed By: sergey, jbakker
Differential Revision: https://developer.blender.org/D11544
|
|
|
|
These were limited to obvious cases. Some less obvious cases
were kept as refactoring might make them necessary in future.
|
|
Inside the sequencer the cropping and transform of images/buffers were
implemented locally. This reduced the optimizations that a compiler
could do and added confusing code styles. This patch adds
`IMB_transform` to reduce the confusion and increases compiler
optimizations as more code can be inlined and we can keep track of
indices inside the inner loop.
This increases end-user performance by 30% when playing back aa video
in VSE.
Reviewed By: ISS, zeddb
Differential Revision: https://developer.blender.org/D11549
|
|
This change was prompted by D6408 which moves thumbnail extraction into
a shared function that happens use these endian defines but only links
blenlib.
There is no need for these defines to be associated with globals
so move into their own header.
|
|
|
|
During transforming an image, a matrix multiplication per pixel was done.
The matrix in itself is always linear so it could be replaced by two additions.
During testing in debug builds playing back a movie went from 20fps to
300 fps.
Reviewed By: zeddb
Differential Revision: https://developer.blender.org/D11533
|
|
This field was used for extend feature to get handle position of
metastrip children. Since D9972 extend feature works only on meta
strip itself, not it's children.
So `SEQ_transform_get_left_handle_frame()` second argument is always
false and can be removed.
Another instance of `seq->tmp usage` is hack to distinguish strips to be
shuffled, which is not covered by this patch.
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D10321
|
|
Fixed the logic for seeking in ffmpeg video files.
The main fix is that we now apply a small offset in ffmpeg_get_seek_pos
to make sure we don't get the frame in front of the seek position when
seeking backward.
The rest of the changes is general cleanup and untangling code.
Reviewed By: Richard Antalik
Differential Revision: http://developer.blender.org/D11492
|
|
|
|
Use SEQ_time_strip_intersects_frame function to test if strip intersects with frame.
Note: There are cases where this function should not be used. For example splitting
strips require at least 1 frame "inside" strip. Another example is drawing, where
playhead technically doesn't intersect strip, but it is rendered, because current
frame has "duration" or "thickness" of 1 frame.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11320
|
|
Remove unused flag `SEQ_DUPE_ANIM` and code used by this flag.
Remove flag `SEQ_DUPE_CONTEXT` and refactor code, to split operator
logic from duplication code.
Reduce indentation level in for loop.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11318
|
|
The fseek() function on Windows only accepts a 32-bit long offset
argument. Because of this we have our own version, BLI_fseek(), which
will use 64-bit _fseeki64() on Windows. This patch just replaces some
fseek() calls with BLI_fseek().
Differential Revision: https://developer.blender.org/D11430
Reviewed by Brecht Van Lommel
|
|
Now FPS is displayed in the video source for videos to provide easy
access.
Reviewed By: Richard Antalik
Differential Revision: http://developer.blender.org/D11441
|
|
|
|
Tool settings for sequencer were not initialized, which caused crash
when adding strips.
There was fix for same issue in versioning rB0f81dafe6cec, but
subversion was not bumped, so files with uninitialized tool settings
may still exist.
Add `SEQ_tool_settings_get()` accessor function that will initialize
tool settings if they are missing. Change operator code to use
`SEQ_tool_settings_fit_method_get()` function instead of accessing
tool settings directly
Reviewed By: campbellbarton
Differential Revision: https://developer.blender.org/D11383
|
|
When sound strip is above another strip such as movie strip, it prevents
from rendering movie strip.
This bug was introduced in 0b7744f4da66. Function `must_render_strip()`
checks if there is any strip with `SEQ_BLEND_REPLACE` blending and
considers this strip as lowest strip in stack. Sound strips do have this
blend mode set, which caused the bug.
Remove all sound strips and muted strips from stack collection before
checking with `must_render_strip()` function
|
|
Includes fixes to misspelled function names.
Ref D11280
|
|
Since version 2.80, the annotations of the Scene strip were not displayed in VSE. Also, the UI panel was`Grease Pencil` and must be `Annotation`
The problem was the offscreen render hasn't evil_CTX and the section of the annotation was never called.
Differential Revision: https://developer.blender.org/D11329
|
|
|
|
References to `SEQ_CACHE_COST_MAX` were removed in 38b77ef8b221.
|
|
Due to misunderstanding of how strip duplication works, animation data
was duplicated on all strips when any strip was split.
`SEQ_sequence_base_dupli_recursive()` duplicated data on strip that was
being split, and `SEQ_ensure_unique_name()` duplicated animation on all
strips.
Only duplication should be done with `SEQ_ensure_unique_name()` and only
on right side split strips, because only these strips are duplicated.
|
|
Fix issue described in T87678, which was partially a bug and partially
change in intended(at least as far as I can tell) behaior.
Function `evaluate_seq_frame_gen` that was partially responsible for
filtering strips in stack for rendering wasn't working correctly.
Intended functionality seems to be removing all effect inputs from stack
as it is unlikely that user would want these to be blended in. However
there was logic to exclude effects placed into same input, which because
of weak implementation caused, that any effect input, that is effect as
well will be considered to be part of stack to be blended in.
This bug was apparently used to produce effects like glow over original
image.
Even though this is originally unintended, I have kept this logic, but
I have made it explicit.
Another change is request made in T87678 to make it possible to keep
effect inputs as part of stack when they are placed above the effect,
which would imply that blending is intended. This change is again
explicitly defined.
Whole implementation has been refactored, so logic is consolidated
and code should be as explicit as possible and more readable.
`must_render_strip function` may be still quite hard to read, not sure
if I can make it nicer.
Last change is for remove gaps feature code - it used same rendering
code, which may be reason why its logic was split in first place.
Now it uses sequencer iterator, which will definitely be faster than
original code, but I could have used `LISTBASE_FOREACH` in this case.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11301
|
|
Recently `SEQ_sort()` function was split so functionality is provided
on per-seqbase basis. After discussion about this split, it turned out,
that per-seqbase operation is only that should be provided, because
RNA API functions need to be able to access arbitrary seqbase
Remove recently introduced function `seq_sort_seqbase` and change
`SEQ_sort` function to operate on seqbase.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11297
|
|
Splitting of effect strip alone wasn't handled properly. Previously
this resulted in duplicating effect strip, and it was broken at least
from 2.79.
Change in rB8ec6b34b8eb2 was intended to allow splitting strips
individually, so it can be used as RNA API function but also so it
requires as little glue logic as possible.
This is fixed by splitting all dependent strips at once in 2 separate
ListBases for left and right strips. Strips can be finally moved into
original `ListBase`.
With this fix it is still possible to split strips individually with
little glue logic. RNA API function could return list of split strips
as well, currently at least one strip in chain will be provided so
chain can be reconstructed on python side.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D10209
|
|
Python API function Sequence.move_to_meta() did delete effect chain
when strip with effects was moved.
Use iterator API to query effect strips and move whole chain to meta.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11206
|
|
|
|
Value of the size argument in `strncat` is too large, might lead to a
buffer overflow.
Change the argument to be the free space in the destination buffer
minus the terminating null byte.
Introduced in 5368859a669d
Reviewed By: Sergey
Differential Revision: https://developer.blender.org/D11289
|
|
|
|
|
|
|
|
|
|
When disk cache path is same as blend file path, with Unix-like systems
blend file can be overwritten by disk cache directory.
This was caused by `BLI_delete(path, false, true)` when path points to
file. On Windows this would result in error message and file would not
be deleted. On Linux, file is deleted and then overwritten with cache
directory.
To further minimize chance of removing blend file, append disk cache
path with `_seq_cache` suffix.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11217
|
|
In e1f3996d740c, logic for changing metastrip start and end frame based
on contained strips was removed. This was done intentionally and
incorrect functionality wasn't noticed as drawing code reflected
seemingly correct state.
Original code was mostly correct, because meta strip doesn't store its
internal start and end points. This code was restored with minor
modifications so function `SEQ_time_update_sequence()` is fully self
contained as it is used not only by transform operator.
In addition, drawing glitches that happen when meta content is outside
of meta boundaries were fixed. These glitches were not caused by
e1f3996d740c.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11215
|
|
readability-inconsistent-declaration-parameter-name
|
|
|
|
This iterator design provides means to create simple and flexible API
to query and work with collection of strips. It should be used in cases
when conditions require multiple stages of recursive iteration of all
strips or similar complex scenarios.
Quick API overview:
Basic queries are standalone functions that return SeqCollection
Use SEQ_collection_create() and SEQ_collection_free() to construct
such query functions.
Use these functions to get strips of known conditions, like selected
strips, movie strips, muted strips and so on.
Use SEQ_reference_query() when querying strips with relation to
some reference strip. For example to get its effects, strips that have
same type or use same input file and so on.
These aren't standalone functions because often you need to query strips
relative to each strip in collection.
Use SEQ_collection_expand() to query strips relative to each strip
in collection. These will be merged to original collection.
Use SEQ_collection_merge() to merge 2 collections
To iterate collection elements use macro SEQ_ITERATOR_FOREACH()
This API is quite specific, but I think it is best suited for tasks
that are usualy solved in sequencer codebase.
Old sequencer iterator has been completely removed.
SEQ_ALL_BEGIN and SEQ_ALL_END macros re-use new iterator design.
As initial use for this iterator select_grouped_effect_link()
function has been rewritten. It was not only broken, but also it used
DNA fields to aid iterating strips.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D10337
|
|
`SEQ_recursive_apply` and `SEQ_seqbase_recursive_apply` were incorrectly
refactored into `iterator.c` file, but they aren't part and don't use
sequencer iterator.
Functions are moved to `utils.c` file.
|
|
In some cases, users start video editing work from General template,
where Filmic view transform is chosen by default. Currently, this causes
issue when working with sRGB footage, which are not properly decoded
into linear working space and final render looks miscolored.
When adding first strip, check it's colorspace and if it corresponds to
colorspace for byte images, ensure that view transform is set to
default value, which is Standard.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D11151
|
|
When frame is rendered to file, bilinear interpolation on scaled images
caused blurred edges.
This is fixed by not doing interpolation with pixels outside of source
buffer.
Such fix doesn't cover cropped images which are currently cropped by
filling area of image with black transparent color, because image buffer
has bigger size than visible image area.
This is fixed by offsetting range used in previous fix by amount, that
would correspond to crop distance. Because of this, image area doesn't
even need to be filled with transparency.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11058
|
|
Speed effect caused, that some raw frames are re-used for multiple
final frames. When cached final frame is freed due to memory being
full, it tried to free also lower level cached frames that were used
during compositing. Some lower level cached frames were already freed
by different final frame and `BLI_ghash_remove()` failed.
Check if key still exists in hash or if linked keys were overwritten
before removing them.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D10909
|
|
When cache is strip is invalidated, movie file was reloaded even if it
isn't necessary. This caused significant performance issues when strip
is being dragged under playhead.
This was caused by calling `SEQ_relations_sequence_free_anim()` and it
was introduced as fix for T36124.
When it is necessary to reload file because another API holds reference
to ImBuf, do this explicitly besides cache invalidation.
In `rna_ColorManagedColorspaceSettings_reload_update()` this was already
done, so no change is needed there.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11024
|
|
Camera object used for rendering reffered to original not evaluated data.
Use `DEG_get_evaluated_object()` to get evaluated camera.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D11039
|