Texture_bind_data   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm

Implementation

(bind-func Texture_bind_data
  "this just uses texture slot 0 (GL_TEXTURE0) - it should probably
allow the texture slot to be specified"
  (lambda (tex:Texture data:i8* width height chan:i32 wrap filter)
    (if (null? data)
        (begin (println "Error: data is null.")
               #f)
        (let ((format (cond ((= chan 1) GL_RED)
                            ((= chan 3) GL_RGB)
                            ((= chan 4) GL_RGBA)
                            (else 0:i32))))
          (if (= format 0)
              (begin (println "Error: only chan must be 1, 3 or 4.")
                     #f)
              (begin (glActiveTexture GL_TEXTURE0)
                     (glBindTexture GL_TEXTURE_2D tex)
                     (glTexImage2D GL_TEXTURE_2D 0
                                   format
                                   width height
                                   0
                                   format
                                   GL_UNSIGNED_BYTE
                                   data)
                     ;; set some parameters
                     (glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_S wrap)
                     (glTexParameteri GL_TEXTURE_2D GL_TEXTURE_WRAP_T wrap)
                     (glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MIN_FILTER filter)
                     (glTexParameteri GL_TEXTURE_2D GL_TEXTURE_MAG_FILTER filter)
                     (gl_print_error "couldn't Texture_bind_image")
                     #t))))))


Back to Index

Similar Entries

  • AudioBuffer_data_b64    xtlang    /digego/extempore/tree/v0.8.9/libs/core/audiobuffer.xtm
  • AudioBuffer_data_b64_cstring    xtlang    /digego/extempore/tree/v0.8.9/libs/core/audiobuffer.xtm
  • AudioBuffer_set_data_b64    xtlang    /digego/extempore/tree/v0.8.9/libs/core/audiobuffer.xtm
  • AudioBuffer_shared_data    xtlang    /digego/extempore/tree/v0.8.9/libs/core/audiobuffer.xtm
  • FBO_color_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • FBO_create_with_textures    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • FBO_depth_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • Pm_Event_Data1    xtlang    /digego/extempore/tree/v0.8.9/libs/external/portmidi.xtm
  • Pm_Event_Data2    xtlang    /digego/extempore/tree/v0.8.9/libs/external/portmidi.xtm
  • Pm_Message_Data1    xtlang    /digego/extempore/tree/v0.8.9/libs/external/portmidi.xtm
  • Pm_Message_Data2    xtlang    /digego/extempore/tree/v0.8.9/libs/external/portmidi.xtm
  • QRcode_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/qr-code.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • Texture_bind_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • Texture_bind_image    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • Texture_create    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • Texture_create_FBO_depth_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • Texture_delete    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • VAO_bind_and_draw_arrays    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • VAO_bind_attribute    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • VAO_bind_attribute    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • VBO_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • VBO_update_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects.xtm
  • aiProcess_FindInvalidData    scheme    /digego/extempore/tree/v0.8.9/libs/external/assimp.xtm
  • aiProcess_ValidateDataStructure    scheme    /digego/extempore/tree/v0.8.9/libs/external/assimp.xtm
  • ai_load_ogl_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/assimp.xtm
  • ai_load_ogl_texture_from_buffer    xtlang    /digego/extempore/tree/v0.8.9/libs/external/assimp.xtm
  • bind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • bind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • bind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • bind-alias    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-closure    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-data    macro    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-constructors    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-deconstructors    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-deconstructors-macros    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-getters    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-type    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-type-constructor    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-data-types    scheme    /digego/extempore/tree/v0.8.9/libs/base/adt.xtm
  • bind-dylib    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-ext-val    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-external-dylib-declarations    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-func    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-func-ipc    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-gl-proc    macro    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-getprocaddress.xtm
  • bind-glew    macro    /digego/extempore/tree/v0.8.9/libs/external/gl/glcore-glew.xtm
  • bind-lib    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-lib-func    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-lib-type    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-lib-val    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-lib-xtm-get-string    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-macro    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-method    macro    /digego/extempore/tree/v0.8.9/libs/core/xobject.xtm
  • bind-object    macro    /digego/extempore/tree/v0.8.9/libs/core/xobject.xtm
  • bind-poly    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-static    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-type    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-val    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind-wrapper    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • bind_cube    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • bindfunc    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/aot-compilation.xtm
  • bindfunc_with_docstring    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/aot-compilation.xtm
  • bindfunc_with_zone_size    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/aot-compilation.xtm
  • bindfunc_with_zone_size_and_docstring    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/aot-compilation.xtm
  • clear_sample_data_    xtlang    /digego/extempore/tree/v0.8.9/libs/external/instruments_ext.xtm
  • create_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • create_texture_shader    xtlang    /digego/extempore/tree/v0.8.9/examples/external/shader-tutorials/texture.xtm
  • data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • fbo_create_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/opengl.xtm
  • fbo_create_texture_rect    xtlang    /digego/extempore/tree/v0.8.9/libs/external/opengl.xtm
  • fits-image-data-R32    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fitslib.xtm
  • fits-image-data-R32    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fits.xtm
  • fits-image-data-RGBA32    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fitslib.xtm
  • fits-image-data-RGBA32    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fits.xtm
  • fits-image-data-RGBA32-false    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fitslib.xtm
  • fits-image-data-RGBA32-false    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/fits.xtm
  • get_hand_data    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/orbbec_test.xtm
  • gl_load_movie_textures    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/gstvideo_multi.xtm
  • gl_load_movie_textures    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/gstvideo.xtm
  • godot_method_bind_call    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/libgodot.xtm
  • godot_method_bind_get_method    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/libgodot.xtm
  • godot_method_bind_ptrcall    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/libgodot.xtm
  • impc:aot:insert-closure-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-ext-globalvar-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-gl-proc-binding-details    scheme    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-getprocaddress.xtm
  • impc:aot:insert-globalvar-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-namedtype-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-nativefunc-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-polyfunc-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-static-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-typealias-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:aot:insert-xtmacro-binding-details    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:compiler:print-bind-func-details-to-log    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:compiler:print-binding-details-to-log    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:compiler:print-lib-binding-details-to-log    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:ti:bind-dylib    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:ti:bind-lib    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • impc:ti:compile-type-dataconstructors    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • init_sample_data    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/gstvideo_multi.xtm
  • init_sample_data    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/gstvideo.xtm
  • ipc:bind-func    scheme    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • ipc:bind-xtmrender-vars    scheme    /digego/extempore/tree/v0.8.9/libs/external/graphics-pipeline-scm.xtm
  • load_assim_material_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/assimp.xtm
  • load_cube_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • load_data    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • match-result:bind    scheme    /digego/extempore/tree/v0.8.9/libs/base/pattern.xtm
  • nnsock_bind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/nanomsg.xtm
  • ocv_dataPtr    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/xtmcv.xtm
  • ocv_dataPtr    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/xtmcv.xtm
  • plet-make-bindings    scheme    /digego/extempore/tree/v0.8.9/libs/base/pattern.xtm
  • set-data-arrays-lines    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/kinect_fire.xtm
  • set-data-arrays-points    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/kinect_fire.xtm
  • set-data-particles    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/kinect_fire.xtm
  • set_sample_data_    xtlang    /digego/extempore/tree/v0.8.9/libs/external/instruments_ext.xtm
  • set_slide_texture    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/slideshow.xtm
  • shader_update_projection_texture    xtlang    /digego/extempore/tree/v0.8.9/libs/external/graphics-pipeline.xtm
  • sys_file_datasync    xtlang    /digego/extempore/tree/v0.8.9/libs/external/system.xtm
  • sys_file_datasync    xtlang    /digego/extempore/tree/v0.8.9/libs/external/system.xtm
  • texture_setup    xtlang    /digego/extempore/tree/v0.8.9/examples/external/shader-tutorials/texture.xtm
  • unbind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • unbind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • unbind    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • unbind-func    macro    /digego/extempore/tree/v0.8.9/runtime/llvmti.xtm
  • unbind_cube    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • unbind_cube    xtlang    /digego/extempore/tree/v0.8.9/libs/external/gl/gl-objects2.xtm
  • update_data_points    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/fluids_2d.xtm
  • world_data    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/game-of-life.xtm
  • world_data_index    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/game-of-life.xtm
  • world_data_size    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/game-of-life.xtm
  • world_texture_setup    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/game-of-life.xtm
  • xobj_database    xtlang    /digego/extempore/tree/v0.8.9/libs/core/xobject.xtm
  • xtm_frame_data_to_tex    xtlang    /digego/extempore/tree/v0.8.9/examples/contrib/gstvideo.xtm
  • xtm_projection_texture_load    xtlang    /digego/extempore/tree/v0.8.9/libs/external/graphics-pipeline.xtm
  • xtm_projecton_texture_weight    xtlang    /digego/extempore/tree/v0.8.9/libs/external/graphics-pipeline.xtm
  • xtm_set_vgimage_subdata    xtlang    /digego/extempore/tree/v0.8.9/libs/contrib/openvg.xtm