vmax_pos   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/contrib/TSM_library.xtm

Implementation

;This returns the position of the max value in a vector
(bind-func vmax_pos:[i64,float*,i64]*
  (lambda (buf:float* len:i64)
    (let ((max_val:float (pref buf 0))
          (i:i64 0)
          (max_pos:i64 0))
      (dotimes (i len)
        (if (> (pref buf i) max_val)
          (begin
            (set! max_val (pref buf i))
            (set! max_pos i))))
      max_pos)))


Back to Index

Similar Entries

  • BTree_walk_postorder    xtlang
  • PARAM_PAN_POS    scheme
  • PARAM_PAN_POS    scheme
  • PARAM_PAN_POS    scheme
  • Widget_find_postorder    xtlang
  • Widget_walk_postorder    xtlang
  • cl:position    scheme
  • cpTransformNewTranspose    xtlang
  • create_post_process_shader    xtlang
  • decompose_domain    xtlang
  • fill_pos_scale_matrix    xtlang
  • get_cursor_pos    xtlang
  • get_new_pos    xtlang
  • get_new_pos2    xtlang
  • get_position    xtlang
  • ghttp_perform_POST_default    xtlang
  • ghttp_perform_POST_json    xtlang
  • ghttp_perform_POST_string    xtlang
  • glfw_cursor_position_callback:GLFWcursorposfun    xtlang
  • glfw_window_position_callback:GLFWwindowposfun    xtlang
  • gui_find_leaf_postorder    xtlang
  • h3d_object_pos    xtlang
  • impc:ti:closure-in-first-position    scheme
  • ivl:transpose    scheme
  • kinect_get_joint_pos    xtlang
  • list-position    scheme
  • mtranspose    xtlang
  • pc:transpose    scheme
  • position_update    xtlang
  • positive?    scheme
  • post    xtlang
  • post:XTMRENDERCB    xtlang
  • post:XTMRENDERCB    xtlang
  • post:XTMRENDERCB    xtlang
  • post:XTMRENDERCB    xtlang
  • postrender:XTMRENDERCB    xtlang
  • set-mouse-pos    xtlang
  • transposition    xtlang
  • vmax    xtlang
  • vmax    xtlang
  • vmax    xtlang
  • vmax    xtlang
  • xtm_camera_pos    xtlang
  • xtm_light_pos    xtlang