Login  Register

Re: Custom Raster

Posted by Xerxes Rånby on Feb 18, 2014; 11:28am
URL: https://forum.jogamp.org/Custom-Raster-tp4031610p4031624.html

The Raster Java Object is never used directly by the JOGL Java3D pipeline,
instead the only thing that gets passed to JOGL is the image buffer inside
the Raster object. Take a look inside the Java3D sourcecode:
http://jogamp.org/git/?p=java3d/java3d-core.git;a=blob;f=src/classes/share/javax/media/j3d/JoglPipeline.java

Java3D asks the JOGL pipeline to do rasterization inside readRaster.. what
happens here is that JOGL then performs the copy from the framebuffer in
one go to the image buffer using glReadPixels  thus no method is called on
the Raster object to update the image buffer inside of it!
src/classes/share/javax/media/j3d/GraphicsContext3D.java:
Pipeline.getPipeline().readRaster(canvas3d.ctx,
src/classes/share/javax/media/j3d/Canvas3D.java:
Pipeline.getPipeline().textureFillRaster(ctx, texMinU, texMaxU, texMinV,
texMaxV,
src/classes/share/javax/media/j3d/Canvas3D.java:
Pipeline.getPipeline().executeRasterDepth(ctx, posX, posY, posZ,

https://www.opengl.org/sdk/docs/man4/html/glReadPixels.xhtml
http://www.opengl.org/archives/resources/faq/technical/rasterization.htm


2014-02-18 11:43 GMT+01:00 JeanPhi [via jogamp] <
ml-node+s762907n4031622h45@n3.nabble.com>:

> You are right, intecepting raster is not wished, but I need a temporary
> solution.
>
> From Java3D I can do an offscreen render - note that Java3D uses JOGL. The
> rendering data will be stored in a raster (IntegerInterleavedRaster in my
> case). So, there is necessarily at least one method which is called in the
> raster to update data :)
>
> I would like my own IntegerInterleavedRaster extended class to be
> recognized. At which point the IntegerInterleavedRaster is identified and
> fed/updated?
>
> ------------------------------
>  If you reply to this email, your message will be added to the discussion
> below:
> http://forum.jogamp.org/Custom-Raster-tp4031610p4031622.html
>  To start a new topic under jogl, email
> ml-node+s762907n782158h61@n3.nabble.com
> To unsubscribe from jogamp, click here<http://forum.jogamp.org/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=762907&code=eGVyeGVzQGd1ZGlubmEuY29tfDc2MjkwN3wtNTE5NjUwMzEw>
> .
> NAML<http://forum.jogamp.org/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>