From 1be089aa2acaeef8670a5b19e7c2d08e7c87cb94 Mon Sep 17 00:00:00 2001 From: Michael Bien <mbien@fh-landshut.de> Date: Sat, 24 Apr 2010 22:52:59 +0200 Subject: clGetExtensionFunctionAddress returns now a long. --- resources/clImplCustomCode.java | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'resources/clImplCustomCode.java') diff --git a/resources/clImplCustomCode.java b/resources/clImplCustomCode.java index fab3a724..9edbd575 100644 --- a/resources/clImplCustomCode.java +++ b/resources/clImplCustomCode.java @@ -118,6 +118,16 @@ private native java.nio.ByteBuffer clEnqueueMapImage0(long command_queue, long image, int blocking_map, long map_flags, Object origin, int origin_byte_offset, Object range, int range_byte_offset, Object image_row_pitch, int image_row_pitch_byte_offset, Object image_slice_pitch, int image_slice_pitch_byte_offset, int num_events_in_wait_list, Object event_wait_list, int event_wait_list_byte_offset, Object event, int event_byte_offset, Object errcode_ret, int errcode_ret_byte_offset); + public long clGetExtensionFunctionAddress(String name) { + ByteBuffer res = clGetExtensionFunctionAddressImpl(name); + if(Platform.is32Bit()) { + return res.getInt(); + }else{ + return res.getLong(); + } + } + +/* private static void convert32To64(long[] values) { if(values.length%2 == 1) { values[values.length-1] = values[values.length/2]>>>32; @@ -128,3 +138,4 @@ values[i ] = temp & 0x00000000FFFFFFFFL; } } +*/ \ No newline at end of file -- cgit v1.2.3