| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
identity tranform in such case.
|
|
|
|
| |
GLJPanel: Don't use GLSL flip if quirk GLSLNonCompliant is present.
|
|
|
|
|
|
| |
BorderLayout w/ Checkbox North, GLCanvas Center)
Thx to Emmanuel Puybaret
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
row-stride (regression of b33bdf41cf53f37203643a8551bf5d94b42a8fab)
SingleAWTGLPixelBufferProvider w/ allowing row-stride reuses the AWTGLPixelBuffer and it's BufferedImage
even w/ different width.
This leads to distortion if using the BufferedImage unhandled.
GLJPanel also set GL_PACK_ROW_LENGTH to pixelBuffer.width, which leads to an 'out-of-bounds'
exception if ReadPixels is used w/ panelwidth and panelHeight.
++
Introduce AWTGLPixelBuffer.getAlignedImage(width, height) which returns an aligned
BufferedImage while reusing the DataBuffer.
GLJPanel fetches a new alignedImage if required.
This allows a more efficient single buffer usage as intended, w/o the need of copying data.
|
| |
|
|
|
|
|
|
|
| |
resized; Add unit test for resize while printing.
Perform immediatly reshape at releasePrint on AWT-EDT:
- sendReshape = handleReshape(); // reshapeSize -> panelSize, backend reshape w/ GL reshape
|
|
|
|
|
|
| |
c8abb9d2c9a8c92f0c5c42aba13e3e80c69739dc: Test isSetup() _after_ running glEventListenerPre.
glEventListenerPre may be utilized to setup the TileRenderer.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
JRootPane for last position offset; AWTMisc.getInsets(..) add special JRootPane case.
Please note that we use JAWTWindow.getLocationOnScreenNonBlocking(..) to determine the
location on the screen 'only' b/c we cannot allow AWT to aquire the tree-lock!
The latter would be the case if using AWT's 'getLocationOnScreen()'.
If anybody has a more reliable implementation to achieve the same .. please provide your patch!
The following fix has been performed to fix the last issue w/ vZome.
- JAWTWindow.getLocationOnScreenNonBlocking(..) shall use JRootPane for last position offset
- w/ vZome, the frame's position was 0/0 (invalid), instead JRootPane's position is good.
Use JRootPane's position and stop traversing here (LW top-level).
- AWTMisc.getInsets(..) add special JRootPane case.
+ * Exception is JRootPane.
+ * Return it's parent's Window component's insets if available,
+ * otherwise return JRootPane's insets.<br>
+ * This is due to <i>experience</i> that <i>some</i> JRootPane's
+ * do not expose valid insets value.
-
|
|
|
|
| |
Only force TEXT AA print-rendering hint.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
position from AWT component's location on screen. Track fixedFrame size of root CALayer; Add Split layout to unit test, add [manual] Applet tests.
- Fix JAWTWindow's getLocationOnScreenNonBlocking()
Skip JRootPane while traversing up to root Container.
JRootPane would duplicate the top-level container's offset (Window insets).
- Derive CALayer position from AWT component's location on screen. Add Split layout to unit test, add [manual] Applet tests.
AWT >= 7u40:
- AWT position is top-left w/ insets, where CALayer position is bottom/left from root CALayer w/o insets.
- Use getLocationOnScreenNonBlocking() to get location-on-screen w/o insets.
- Native code: flip origin
AWT < 7u40 still uses fixed position 0/0 for root and sub layer.
- Track fixedFrame size of root CALayer - MyCALayer:
- Override layoutSublayers to validate root and sub-layer pos/size
- Override setFrame to use fixedFrame, if set (similar to MyNSOpenGLLayer)
- Add Split layout to unit test, add [manual] Applet tests.
- Thx to 'jimthev' and 'Manu' for providing Applet unit tests
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of component-count, support all int types ; Add type 'BufferedImageInt' preserving the custom image-type, add note about TYPE_CUSTOM
- createBufferedImage(..) use BufferedImage type value instead of component-count, support all int types
- Support all integer data image-type, hence we need to pass image-type instead of component count (collision).
- Also pass 'properties' to allow configuring all BufferedImage parameters (just in case)
- Return BufferedImageInt to allow user to query the used image-type, see below.
- Add type 'BufferedImageInt' preserving the custom image-type, add note about TYPE_CUSTOM
- Simply extends BufferedImage w/ custom image-type, since BufferedImage's type is TYPE_CUSTOM
due to our custom storage type (see API doc comment).
Unit tests:
- Testing all integer image-type's in
- TestTiledPrintingGearsSwingAWT
- TestTiledPrintingNIOImageSwingAWT
- Disable all AA print-hints, all AWT text visible on X11.
Probably has a regression on Windows / OSX .. TBD.
|
| |
|
|
|
|
| |
'isInit' flag.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
upper area, cleanup.
TestTiledPrintingGearsSwingAWT2: Provoked !flipped bug where top-row was positioned too low
due to using full size tile-height.
Cutting of the unused top-row's upper area corrects this issue.
vertical-flip mode does not expose this situation, since flipping
shifts the payload to the upper tile area.
TestTiledPrintingGearsSwingAWT2: Also tests an alternative transparent overlapping mode
without layout.
|
|
|
|
|
|
|
|
|
|
|
|
| |
In FBO mode save TextureState of current texture-unit,
as well as for the fbo texture-unit if the latter is a different.
In glslTextureRaster mode for verical flip (using FBO),
set the viewport to drawable size if before flipping and restore afterward - if equired.
TestGLJPanelTextureStateAWT fully tests use cases:
- Keep texture bound w/ same or other texture-unit
- Use 2 viewports within one drawable and keep it
|
|
|
|
|
|
|
| |
Before we bumped java language version to 1.6, i.e. target == 1.5,
we required to compile some parts w/ the host level (1.6).
This is no more required.
|
| |
|
|
|
|
|
|
| |
location and destination must follow same math as w/ vertical-flip.
.. clipping and tile-height was not considered.
|
|
|
|
|
|
|
|
|
|
| |
- Contains convenient method to create an NIO backed BufferedImage
'BufferedImage createBufferedImage(int width, int height, int numComponents, Point location)'
Standalone test TestTiledPrintingNIOImageSwingAWT 'prints', i.e. renders offscreen,
the Frame into
- a traditional array-backed BufferedImage
- an NIO-backed backed BufferedImage
|
| |
|
|
|
|
| |
up warnings and includes (clang).
|
|
|
|
| |
it's working/scaling well; Adding TileRendererBase.TileRendererNotify to RedAquareES2 having a 3rd demo case.
|
|
|
|
|
|
|
|
|
| |
Note: Same bug existing as w/ GLCanvas, i.e.
'GLDrawableUtil.swapGLContextAndAllGLEventListener(gladPre, gladNew)':
If 'gladPre' is onscreen and using MSAA (on NV/GLX),
the ctx cannot be made current in it's new 'gladNew' location.
Same workaround applied, i.e. use onscreen drawable while printing.
|
|
|
|
| |
directory and classpath. This hopefully saves a few milliseconds in the build :)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and convenient AWT container traversal context; GLCanvas/GLJPanel properly handle existing MSAA and req. AA;
- Test: Don't resize frame, tweek print-matrix
- Use scaleComp72 to scale the frame to fit on page,
i.e. global print matrix
- Use scaleGLMatXY = 72.0 / glDPI
to locally scale on the GL drawable as being passed to AWTPrintLifecycle.setup(..)
- Hence frame stays untouched/stable, no need for 'offscreen' print test,
which is removed.
- AWTPrintLifecycle: Add scale and convenient AWT container traversal context
Use a simple decoration for all AWTPrintLifecycle impl. components within a container:
final AWTPrintLifecycle.Context ctx = AWTPrintLifecycle.Context.setupPrint(frame, g2d, scaleGLMatXY, scaleGLMatXY);
try {
} finally {
ctx.releasePrint();
}
- GLCanvas/GLJPanel properly handle existing MSAA and req. AA;
- GLCanvas: Workaround bug where onscreen MSAA cannot switch to offscreen FBO,
i.e. stay 'onscreen'
- GLJPanel: Use new offscreen FBO if MSAA is requested and not yet used.
- GLJPanel.Offscreen.postGL(): always swapBufer(), was missing for !GLSL swapping
Results GLCanvas / GLJPanel:
- Good scaling
- Stable behavior / visibility
- High DPI mode works
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RenderingHints test; setupPrint(Graphics2D): Query RenderingHints to use MSAA rendering
- AWTPrintLifecycle.setupPrint(Graphics2D): Query RenderingHints to use MSAA rendering
- Impl. in GLCanvas
- TODO GLJPanel (would need a new offscreen buffer)
- TiledPrintingAWTBase:
- Fix scaling - Fit frame to page
- add MSAA RenderingHints test
- GLCanvas: Remove dumpStack() DEBUG output
|
|
|
|
| |
print(Graphics): Don't force on AWT-EDT -> Deadlock; releasePrint(): perform reshape/display!
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
print(..); Test: Add auto-print w/o UI 72dpi and 300dpi
NOTE: Tile raster is added at print plus lots of debug output - WIP!
- Swap to offscreen at setupPrint()
- Swap GLEventListener (GLEL) and GLContext to fixed size offscreen GLAutoDrawable (GLAD)
- Destroy onscreen drawable/context
- Setup TileRenderer w/ offscreen GLAD
- @ releasePrint() restore onscreen ..
This shall ensure we don't hog the GPU resources when
resizing the AWT component (upscaling).
- Use TileRenderer @ print(..)
The clip-rect will be used as the TileRenderer's image-size
and we perform a whole tile-rendering loop.
This helps to limit resources, see above.
- Test: Add auto-print w/o UI 72dpi and 300dpi
|
|
|
|
| |
GLOffscreenAutoDrawable switch, forth & back
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
GLEventListener about attached/detached TileRenderer
.. since GLEventListener's reshape(..) method must query certain tile renderer attributes (tile pos and image size),
they have to be aware of the TileRendererBase.
To simplify such awareness and hence automate this attachement and passing over the tile renderer reference,
they should implement this new interface.
Gears example implements the new interface,
which caches the TR reference and pauses rotation.
|
|
|
|
| |
for UI agnostic (no-awt tests).
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
GLEventListener reshape(..) or manual reshape after beginTile(..) method.
GLEventListener reshape(..) method should be aware of TileRenderer usage
and get the missing tile position and image size from it (-> see Gears example).
TestRandomTiledRendering3GL2AWT demos AWT GLCanvas onscreen
being used for random tile rendering to produce a PNG file.
TestTiledRendering1GL2 is now GLAutoDrawable/GLEventListener agnostic,
hence demos plain GLDrawable tile rendering usage.
|
|
|
|
| |
GLPixelBuffer, and pre/post GLEventListener)
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
may lead to a JVM freeze ..
.. on ATI fglrx driver 32bit on 64bit w/ a frozen shared GL context involved.
Hence we have to rely on the driver cleanup when JVM hits 'exit',
equal to the Windows implementation.
|
|
|
|
|
|
|
| |
compiled for it -> pass
Scenario ffmpeg-0.10, where we are not prepared (compiled-in) for sw-resample support.
Don't use if compiled in version (CC) is < 0 (n/a), and allow to pass at load time.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
orientation change (flipped), API-doc,
- State
- Fix state transition (initGL() error)
- Camera options
- options uses ';' as query separator
- don't use 'default' options, driver should know
- Detect and act on orientation change (flipped)
- ffmpeg impl detects if flipped changes and triggers a SIZE update event.
This allows application to react, i.e. re-init GL and use new TextureCoord's.
Test: Works well on Windows w/ rawvideo dshow camera driver/codec.
- API-doc
- TexSeqEventListener/GLMediaEventListener usage / constraints (GL, ..)
- State transition fix
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
windows, 2 more pixel formats, fail-safe data handling
- add support for ffmpeg 2 / libav 10 -> lavc55_lavf55_lavu52_lavr01
- add support for ffmpeg libswresample (similar to libavresample)
- handle BGRA (GL type) and BGR24 (texture shader)
- Change Camera URI semantics, drop 'host' and use 'path' for camera ID
and use 'query' for options.
- add support for Window's DShow camera selection
- our camera id -> index of list of video-input devices,
this gives us same behavior as w/ Linux
- requires windows libs: strmiids, uuid, ole32, oleaut32
- Compiles w/ MingW64, works w/ libav/ffmpeg
- TODO: test compilation w/ MingW 32bit !
- don't push data to texture if (linesize <= 0)
this may happen due to buggy decoder / setup ..
Tested manually on GNU/Linux x64 and Windows x64:
- GNU/Linux libav 0.8, libav 9, libav 10, ffmpeg 1.2, ffmpeg 2.0
- Windows libav 0.8, libav 9, ffmpeg 2.0
- videos and camera
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
def. high camera options, cleanup symbols)
- Fix libav/ffmpeg compilation
- Split native GLContext code from JoglCommon
- JoglCommon is required for ffmpeg_* c-compile/link
- Supported versions now:
- 0.8 53.53.51
- 9.0 54.54.52
- FFMPEGMediaPlayer
- Update API doc, add compatibility .. etc
- Pixel format conversions (via shader texture lookup func):
- YUV420P, YUVJ420P
- YUV422P, YUVJ422P
- YUYV422
- Properly handle aid/vid
- In camera mode: set high default values
- TODO: Make it configurable via camera URI:
- video_size
- framerate
- ?
- FFMPEGDynamicLibraryBundleInfo
- Cleanup symbols / remove unused (pre 53)
- Add av_dict_* methods
|
|
|
|
|
|
|
|
|
|
|
| |
version dependent c-files individually and inject object files. ; ffmpeg *register_all() at setStream0(..)
- Use 'dot less' dir/file names
- Compile ffmpeg version dependent c-files individually and inject object files.
- ffmpeg *register_all() at setStream0(..)
- Only register devices if available _and_ camera is requested.
|
| |
|
|
|
|
| |
'stub_includes'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
missing symbol 'av_realloc'.
- Add camera input
- Use URI w/ scheme 'camera' to determine camera input is desired,
use URI host as camera id.
E.g. 'camera://0' for 1st camera.
- AndroidGLMediaPlayerAPI14: Via 'Camera'
- FFMPEG*: Via libavdevice, device name and input format
- TODO: Add controls to manipulate camera if available
- FFMPEG*
- Add symbols
- avcodec_register_all
- av_realloc (was missing)
- avdevice_register_all
- Load libavdevice (opt)
- Camera:
- Use <ID> (windows) and /dev/video<ID> other OS
- simply find the input format in native code
- Support YUYV422 (used in video4linux2, etc.)
- Stuff 2x 16bpp (YUYV) into one RGBA pixel!
- Add texture format for 16bpp
- Add texture lookup shader
- Fix av_packet leak in readNextImpl(..)
- Restore orig pointer and size values,
we may have moved along within packet.
Then call av_free_packet().
- Use null AudioSink if audio-id is NONE
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
FFMPEGNatives -> FFMPEGv08Natives + FFMPEGv09Natives
Enables FFMPEGMediaPlayer to work w/ either ffmpeg/libav version 8 or 9 w/ same JOGL binary
Same C source code is compiled against
1: version 0.8 FFMPEGv08Natives lavc53.lavf53.lavu51
2: version 0.9 FFMPEGv09Natives lavc54.lavf54.lavu52.lavr01
FFMPEGv08Natives and FFMPEGv09Natives implements FFMPEGNatives,
native C code uses CPP '##' macro concatenation to produce unique function names.
To enable 'cpp' to find the libav* header files matching the desired version,
we have placed them in the c-file's folder, issued '#include "path/file.h"
and added symbolic links to allow finding same module and 'sister modules':
ls -l libavformat/
..
lrwxrwxrwx 1 sven sven 13 Aug 26 12:56 libavcodec -> ../libavcodec
lrwxrwxrwx 1 sven sven 14 Aug 26 12:56 libavformat -> ../libavformat
lrwxrwxrwx 1 sven sven 12 Aug 26 12:57 libavutil -> ../libavutil
..
At static init FFMPEGDynamicLibraryBundleInfo, determines the runtime version
and instantiates the matching FFMPEGNatives, or null if non matches.
FFMPEGMediaPlayer still compares the compile-time and runtime versions.
FFMPEGMediaPlayer passes it's own instance to FFMPEGNatives for callbacks.
|
| |
|