Package com.jogamp.opencl.llb.gl

Examples of com.jogamp.opencl.llb.gl.CLGL


        if(condition != null) {
            conditionIDs = condition.IDsView;
            conditions   = condition.size;
        }

        CLGL xl = (CLGL) cl;

        int ret = xl.clEnqueueAcquireGLObjects(ID, glObjectIDs.remaining(), glObjectIDs,
                    conditions, conditionIDs,
                    events==null ? null : events.IDs);

        if(ret != CL_SUCCESS) {
            throw newException(ret, "can not aquire " + glObjectIDs + " with " + toStr(condition, events));
View Full Code Here


        if(condition != null) {
            conditionIDs = condition.IDsView;
            conditions   = condition.size;
        }

        CLGL xl = (CLGL) cl;

        int ret = xl.clEnqueueReleaseGLObjects(ID, glObjectIDs.remaining(), glObjectIDs,
                conditions, conditionIDs,
                events==null ? null : events.IDs);

        if(ret != CL_SUCCESS) {
            throw newException(ret, "can not release " + glObjectIDs + "with " + toStr(condition, events));
View Full Code Here

        CLGLBuffer.checkBuffer(directBuffer, flags);

        CL cl = getCL(context);
        int[] result = new int[1];
        CLGL clgli = (CLGL)cl;

        long id = clgli.clCreateFromGLTexture2D(context.ID, flags, target, mipLevel, texture, result, 0);
        checkForError((int)id, "can not share memory with texture #"+texture+".");

        CLImageInfoAccessor accessor = new CLImageInfoAccessor(cl, id);

        CLImageFormat format = createUninitializedImageFormat();
View Full Code Here


    static <B extends Buffer> CLGLBuffer<B> create(CLContext context, B directBuffer, long size, int flags, int glObject) {
        checkBuffer(directBuffer, flags);
       
        CLGL clgli = (CLGL)getCL(context);
       
        int[] result = new int[1];
        long id = clgli.clCreateFromGLBuffer(context.ID, flags, glObject, result, 0);
        CLException.checkForError(result[0], "can not create CLGLObject from #"+glObject);

        return new CLGLBuffer<B>(context, directBuffer, id, glObject, size, flags);
    }
View Full Code Here

        CLGLBuffer.checkBuffer(directBuffer, flags);

        CL cl = getCL(context);
        int[] result = new int[1];
        CLGL clgli = (CLGL)cl;

        long id = clgli.clCreateFromGLTexture3D(context.ID, flags, target, mipLevel, texture, result, 0);

        CLImageInfoAccessor accessor = new CLImageInfoAccessor(cl, id);

        CLImageFormat format = createUninitializedImageFormat();
        accessor.getInfo(CL_IMAGE_FORMAT, CLImageFormatImpl.size(), format.getFormatImpl().getBuffer(), null);
View Full Code Here

        CLGLBuffer.checkBuffer(directBuffer, flags);

        CL cl = getCL(context);
        int[] result = new int[1];
        CLGL clgli = (CLGL)cl;

        long id = clgli.clCreateFromGLRenderbuffer(context.ID, flags, glObject, result, 0);

        return createImage(context, id, directBuffer, glObject, flags);
    }
View Full Code Here

TOP

Related Classes of com.jogamp.opencl.llb.gl.CLGL

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.