| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
d99c2d8b28470d335ab5b30124ef8b0607b3b90f
|
|
|
|
| |
information (if any), FFMPEG* utilizes NativeLibrary.get[Native]LibraryPath()
|
|
|
|
| |
library path, support throughout DynamicLibraryBundle[Info]
|
|
|
|
| |
misleading and wrong info (e.g. on mute)
|
|
|
|
| |
disruption after pause(flush:=false)
|
|
|
|
| |
i.e. ignore audio_queued_ms in such case (Fixes video sync on SCR w/o audio)
|
|
|
|
| |
direct user-exposure and potential data-race
|
|
|
|
| |
w/o video-frame (fixes 'massive' seek'ing)
|
|
|
|
| |
Left behind hacking for AV sync ..
|
|
|
|
|
|
| |
!hasVideoFrame upfront, simplifying sync-block
Fix playSpeed > 1: dt_v (keep playSpeed factor), allow drop frame on no-frames w/ playSpeed > 2
|
|
|
|
| |
stream is not yet initialized or playing, cached clipped value and set at initGL(..)
|
|
|
|
| |
user from selecting video or audio PTS.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(multiple of) audio_dequeued_ms
The case of lagging audio to the audio master-clock (by experience) is a rare and probably synthethic case
of the AV async videos, was
dt_a > MAX_VIDEO_ASYNC && d_apts > 0
now with increased threshold max_adelay = Math.max( 4*audio_dequeued_ms, 4*MAX_VIDEO_ASYNC )
dt_a > max_adelay && d_apts > 0
In conjunction the video-repeat case (video pts > SCR) shall use a higher threshold _when_
detecting, i.e. min1_audio_queued_ms = Math.max( 2*audio_dequeued_ms, 2*MAX_VIDEO_ASYNC )
to ensure enough buffered audio exists (2 audio-frames) before the next getNextTexture()
hits within vsync.
This early detection and min1_audio_queued_ms threshold
is double of the late threshold for video-repeat min0_audio_queued_ms = Math.max( audio_dequeued_ms, MAX_VIDEO_ASYNC ),
when the to-be repeated frame shall be displayed within getNextThreshold().
Failing this requirement (1 audio-frame) will discard it and gather the next video-frame,
allowing to fill the audio-buffer. A subsequent AV sync shall correct the difference.
Strategy is less intervention on less buffered-audio.
This shorter tolerance also reduces some video lag or stuttering on 24fps -> 60fps films.
|
|
|
|
|
|
|
|
|
| |
resample: Use swr_get_out_samples(..) to calculate the required output sample count
Notable when playing audio with e.g. 24k sample rate on a 48k OpenAL ALAudioSink,
the sample duration was cut in half due to erroneous resampling missing half the required samples.
Using swr_get_out_samples(..) resolves this issue pre swr_convert(..), the resampling.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
master-clock, enabling proper AV sync w/ untouched audio
We can finally utilize the added pass through audio PTS, see commits
- GlueGen 52725b4c6525487f93407f529dc0a758b387a4fc
- JOAL 12029f1ec1d8afa576e1ac61655f318cc37c1d16
This enables us to use the audio PTS as the master-clock and adjust video to the untouched audio.
In case no audio is selected/playing or audio is muted,
we sync merely on the system-clock (SCR) w/o audio.
AV granularity is 22ms, however, since the ALAudioSink PTS may be a little late,
it renders even a slightly better sync in case of too early audio (d_apts < 0).
Since video frames are sync'ed to audio, the resync procedure may result
in a hysteresis swinging into sync. This might be notable at start
and when resumed audio or after seek.
We leave the audio frames untouched to reduce processing burden
and allow non-disrupted listening.
Passed AV sync tests
- Five-minute-sync-test.mp4
- Audio-Video-Sync-Test-Calibration-23.98fps-24fps.mp4
- Audio-Video-Sync-Test-2.mkv
|
| |
|
|
|
|
| |
Using `-Djogl.debug.GLMediaPlayer.AVSync -Djogamp.debug.AudioSink` to trace AVSync issues for now.
|
|
|
|
|
| |
FFMPEGMediaPlayer: This also effectively reduces the audio buffer size from 3000ms -> 768ms,
the new default for audio streams with video.
|
|
|
|
|
|
|
|
|
|
|
| |
custom name against GLSL internal 'texture2D', add missing VideoPixelFormat conversions
Always use own textureLookupShader, avoiding confusion or even race conditions.
Validate textureLookupShader custom name against GLSL internal 'texture2D' (illegal override)
Add missing VideoPixelFormat conversions:
- RGB24, ARGB, RGBA, ABGR, BGRA
|
|
|
|
| |
VideoPixelFormat conversion for easier debugging
|
|
|
|
| |
mute and play on un-mute)
|
|
|
|
|
|
|
|
| |
audio-volume if not initialized and set it when AudioSink becomes available
Setting the audio volume before initialization shall impact GLMediaPlayer when it becomes initialized.
Further add a query if audio is muted, merely based on volume.
|
|
|
|
| |
77eab439147af69089fa3ebf07d64ee3b4d67bfd
|
|
|
|
| |
WorkerThread, helping to simplify code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
agnostic (PMVMatrix, Matrix4f, Vec4f, ..)
Math functionality (PMVMatrix, Matrix4f, Vec4f, ..)
- shall be used toolkit agnostic, e.g. independent from OpenGL
- shall be reused within our upcoming Vulkan implementation
- may also move outside of JOGL, i.e. GlueGen or within its own package to be reused for other purposed.
The 'com.jogamp.opengl.util.PMVMatrix' currently also used to feed in GLUniformData
via the toolkit agnostic SyncAction and SyncBuffer
shall also be split to a toolkit agnostic variant.
An OpenGL PMVMatrix specialization implementing GLMatrixFunc can still exist,
being derived from the toolkit agnostic base implementation.
+++
Initial commit .. compile clean, passing most unit tests.
|
|
|
|
|
|
|
|
|
| |
over ownership and allows destroy() to delete it, otherwise not. Fixes GraphUI's GLButton.
GraphUI's GLButton uses the offscreen's FBO texture and hence can't pass over ownership of the texture.
Hence the Texture instance is created w/o handing over ownership!
GLMediaPlayerImpl does hand over ownership of the generated and passed texture to the Texture ctor.
|
|
|
|
| |
shall handle null streamWorker, i.e. when using NullGLMediaPlayer
|
|
|
|
|
|
|
| |
AudioSink.setChannelLimit() ..
May be utilized to enforce 1 channel (mono) downsampling
in combination with JOAL/OpenAL to experience spatial 3D position effects.
|
| |
|
| |
|
|
|
|
| |
2b339721a4d6dd4f3af129a4654375b15c7ea340)
|
|
|
|
| |
270172bcbd91f96d4a38a3d73e23d744f57a25b8) and joal (commit 03f4bb63ce8a358b1c2ef303480e1887d72ecb2e)
|
|
|
|
| |
(regression to initial implementation)
|
|
|
|
| |
with EventMask.Bit/EventMask
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
invPMv null; PMVMatrix: Make Mvi, Mvit optional at ctor, add user PMv and PMvi - used at gluUnProject() ..
Matrix4f.mapWin*() variants w/ invPMv don't need temp matrices,
they also shall handle null invPMv -> return false to streamline usage w/ PMVMatrix if inversion failed.
PMVMatrix adds user space common premultiplies Pmv and Pmvi on demand like Frustum.
These are commonly required for e.g. gluUnProject(..)/mapWinToObj(..)
and might benefit from caching if stack is maintained and no modification occured.
PMVMatrix now has the shader related Mvi and Mvit optional at construction(!), so its backing buffers.
This reduces footprint for other use cases.
The 2nd temp matrix is also on-demand, to reduce footprint for certain use cases.
Removed public access to temporary storage.
+++
While these additional matrices are on demand and/or at request @ ctor,
general memory footprint is reduced per default and hence deemed acceptable
while still having PMVMatrix acting as a core flexible matrix provider.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Utilize Vec3f, Recti, .. throughout API (Matrix4f, AABBox, .. Graph*)
Big Easter Cleanup
- Net -214 lines of code, despite new classes.
- GLUniformData buffer can be synced w/ underlying data via SyncAction/SyncBuffer, e.g. SyncMatrix4f + SyncMatrices4f
- PMVMatrix rewrite using Matrix4f and providing SyncMatrix4f/Matrices4f to sync w/ GLUniformData
- Additional SyncMatrix4f16 + SyncMatrices4f16 covering Matrix4f sync w/ GLUniformData w/o PMVMatrix
- Utilize Vec3f, Recti, .. throughout API (Matrix4f, AABBox, .. Graph*)
- Moved FloatUtil -> Matrix4f, kept a few basic matrix ops for ProjectFloat
- Most, if not all, float[] and int[] should have been moved to proper classes
- int[] -> Recti for viewport rectangle
- Matrix4f and PMVMatrix is covered by math unit tests (as was FloatUtil before) -> save
Passed all unit tests on AMD64 GNU/Linux
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ray, AABBox, Frustum, Stereo*, ... adding hook to PMVMatrix
Motivation was to simplify matrix + vector math usage, ease review and avoid usage bugs.
Matrix4f implementation uses dedicated float fields instead of an array.
Performance didn't increase much,
as JVM >= 11(?) has some optimizations to drop the array bounds check.
AMD64 + OpenJDK17
- Matrix4f.mul(a, b) got a roughly ~10% enhancement over FloatUtil.multMatrix(a, b, dest)
- Matrix4f.mul(b) roughly ~3% slower than FloatUtil.multMatrix(a, b, dest)
- FloatUtil.multMatrix(a, a_off, b, b_off, dest) is considerable slower than all
- Matrix4f.invert(..) roughly ~3% slower than FloatUtil.invertMatrix(..)
RaspberryPi 4b aarch64 + OpenJDK17
- Matrix4f.mul(a, b) got a roughly ~10% enhancement over FloatUtil.multMatrix(a, b, dest)
- Matrix4f.mul(b) roughly ~20% slower than FloatUtil.multMatrix(a, b)
- FloatUtil.multMatrix(a, a_off, b, b_off, dest) is considerable slower than all
- Matrix4f.invert(..) roughly ~4% slower than FloatUtil.invertMatrix(..)
Conclusion
- Matrix4f.mul(b) needs to be revised (esp for aarch64)
- Matrix4f.invert(..) should also not be slower ..
|
| |
|
|
|
|
| |
lookupFunction on Uninitialized state
|
| |
|
|
|
|
| |
explicitly to set the name upfront, clarifying workflow. Impl: ImageSequence + GLMediaPlayerImpl
|
|
|
|
| |
Use private isPausedOrPlaying() to determine shaderCodeHash
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
showing test-texture. Adding stop(); (API Change)
- allow multiple initGL(..) @ uninitialized and initialized
- allows usage before stream is ready
- using a test-texture @ uninitialized
- adding stop()
API change
- initStream() -> playStream()
- play() -> resume()
FFMPEG: Added 'ready' check for robustness
|
|
|
|
| |
allowing access w/o jars. TODO: Test Android.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
used for getElemCount() instead of 0==position, ... (API change)
API Change
- sealed() moved up from GLArrayDataEditable -> GLArrayData
- GLArrayDataWrapper is sealed by default
- getSizeInBytes() -> getByteCount()
- Semantics of getElemCount() and getByteCount()
- Correctly use sealed() to switch from position to limit - instead of 0==position
Aligned method names:
- getElemCount()
- elemPosition()
- remainingElems()
- getElemCapacity()
to corresponding byte counts:
- getByteCount()
- bytePosition()
- remainingBytes()
- getByteCapacity()
|
| |
|
|
|
|
|
|
|
| |
Pass orig AbstractGraphicsDevice to allow EGLDrawableFactory to use the original device's native-dislay-ID for sharing resources.
EGLDrawableFactory to use the original device's native-dislay-ID for sharing resources, e.g. GLContext.
EGL 1.4 requires same native-display-ID of share-list context and newly created context!
|
|
|
|
| |
streamWorker stop result (-> deadlock)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
finalize immutables, add growthFactor (default golden ratio 1.618), add getCapacity*() and printStats(..)
The growthFactor becomes essential for better growth behavior and can be set via setGrowthFactor().
The other changes were merely to clean up the GLArrayData interface and its 4 implementations.
Not great to change its API, but one name was misleading ['getComponentCount' -> 'getCompsPerEleme'],
so overall .. readability is enhanced.
Motivation for this change was the performance analysis and improvement of our Graph Curve Renderer.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
11), 5.* (Debian 12) and 6.* (Current Development trunk)
From here on, libav support has been dropped.
Required FFmpeg libraries to be fully matched by their major runtime- and compiletime-versions are:
- avcodec
- avformat
- avutil
- swresample
Library avdevice is optional and only used for video input devices (camera).
Library avresample has been removed, since FFmpeg dropped it as well in version 6.*
and swresample is preferred for lower versions.
The matching major-versions of each library to the FFmpeg version
is documented within FFMPEGMediaPlayer class API-doc.
Each implementation version uses the non-deprecated FFmpeg code-path
and compilation using matching header files is warning-free.
|