aboutsummaryrefslogtreecommitdiffstats
path: root/make/config/jogl/gl-impl-CustomJavaCode-embedded.java
Commit message (Collapse)AuthorAgeFilesLines
* GLBuffers fix ; GL imageSizeInBytes fix / unit tests.Sven Gothel2011-06-091-38/+3
| | | | | | | | | | - Moved implementation of prev GL imageSizeInBytes(..) -> GLBuffers.sizeof() for all GL profiles - GLBuffers.*: Added missing formats and types (GL2.1, GL3.3 and GL4.1) - GLBuffers.sizeof(): Fail fast if format/type is unhandled, or alignment invalid - Added unit test for GLBuffers.sizeof()
* imageSizeInBytes .. leaving out the dirt/padding last lineSven Gothel2009-10-191-3/+5
|
* New iteration of check 'imageSizeInBytes':Sven Gothel2009-10-181-14/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Premises: See http://www.glprogramming.com/red/chapter08.html "If the rectangle in memory is larger than the subrectangle that's being drawn or read, you need to specify the actual length (measured in pixels) of the larger rectangle with *ROW_LENGTH. " This equals ROW_LENGTH == SubPicture-Width + 'Dirt', ie the offset to go from one line to the next. "You also need to specify the number of rows and pixels to skip before starting to copy the data for the subrectangle. These numbers are set using the parameters *SKIP_ROWS and *SKIP_PIXELS, as shown in Figure 8-9. By default, both parameters are 0, so you start at the lower-left corner." This equals to a one time offset _before_ you start copy the data, ie with your DMA engine, using ROW_LENGTH and HEIGHT only. Compared to Mesa3D's implementation (proof): http://cgit.freedesktop.org/mesa/mesa/tree/src/glx/x11/pixelstore.c Line 78 - 200 PixelStore State Tracker: Store the values in the PixelStore structure. http://cgit.freedesktop.org/mesa/mesa/tree/src/glx/x11/pixel.c Line 82 - 155 Line 210: Start position is set one time using SKIP_* values the same way we do. Line 228: Jump to the first pixel in the newxt row, just using ROW_LENGTH Line 230: Jump to the first pixel in the next 'image' just using imageSize, rowsPerImage = IMAGE_HEIGHT>0?IMAGE_HEIGHT:height; groupsPerRow = ROW_LENGTH>0?ROW_LENGTH:width; groupSize = elementSize * components; rowSize = groupsPerRow * groupSize; imageSize = rowSize * rowsPerImage; changes: Removed redundand 'dimension' parameted, which is derived from depth and height, 1D == depth:1 height:1 2D == depth:1 height>1 nD == depth>1 height>1 Safe fail depth to >= 1 Safe fail height to >= 1D Take either the ROW_LENGTH / IMAGE_HEIGHT PixelStore value if > 0, or the given width / height.
* All tracker are aggregated in the GLContext nowSven Gothel2009-10-171-9/+11
| | | | | | | | | | | | | | | and used within the GL*Impl. New GLStateTracker: - Tracking client/server states - Currently supports PixelStorei - Prologued in glPixelStorei and glGetIntegerv, the latter will return the tracked state if available and not call the GL method. Impacts performance and ES1 compatibility (supports ALIGNMENT). Fixed 'imageSizeInBytes' calculation: - skipPixels and skipRows is a static one time offset
* Copied JOGL_2_SANDBOX r1957 on to trunk; JOGL_2_SANDBOX branch is now closedKenneth Russel2009-06-151-0/+37
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1959 232f8b59-042b-4e1e-8c03-345bb8c30851