C Wrapper for GLM library GLM is one the GL library used for 2d 3d operation But it is written in C++ This project wraps the functions using C struct and function pointers Example C code
GSL Library usage Kotlin Native GSL library can be used for advanced math operations and vector, stats, sort, permute, fitting, matrix, fourier transform, blas integration This code demonstration a simple matrix addition and diagonal addition in kotlin using GSL
Kotlin OSMesa offscreen rendering A simple example of OSMesa driver offscreen rendering to a buffer binary array This explains OpenGL functions can be used to indirectly manipulate a numeric array Kotlin Code
Compiling GTK4 in windows with Vulkan GTK4 is already available for download as "mingw-w64-x86_64-gtk4" you can type "pacman -S mingw-w64-x86_64-gtk4" to install it Below steps are useful if you want to customize and install GTK4 with vulkan Step 1 download and install MSYS2 Step 3 Install toolchains
GTK4 + GSK Cairo / Vulkan Cairo is a ancient 2D library to draw shapes on linux platform. It can be used in windows with proper library DLL extensions. There a few software still uses cairo. This demo kotlin code explains how to render a cairo+graphene rectangle region using GSK Kotlin Code
Kotlin AVR Atmega8 [Experimental] This is a small experiment for AVR Atmega8 A simple swap function which is possibly re-used inside actual avr "C/C++" code as library import platform.avr.* import kotlinx.cinterop.internal.* import kotlinx.cinterop.* fun swap(a:uint8_tVar, b:uint8_tVar) = memScoped { var temp = a a.value = b.value b.value = temp.value }Install mingw64 dependencies as below
GLEW + GTK3 using Kotlin [Experimental] This is an experimental code with few glitches it allows Cygwin+Mingw to use GTK3 from cygwin to render opengl GLEW Kotlin code
GTK3 and Glade3 using Kotlin GTK windows design using glade builder This code explains how to use Kotlin to program GTK3 and Glade3 using Cygwin Glade designer Install cygwin with below dependencies mingw64-x86_64-gtk3 3.22.28-1 glade 3.20.3-1 xorg-server 1.20.4-1 xinit 1.4.1-1 launch cygwin and export the PATH as
Call OpenCL from Kotlin or embed OpenCL inside Kotlin Embedded OpenCL inside Kotlin OpenCL code which runs from kotlin #pragma OPENCL EXTENSION cl_khr_byte_addressable_store : enable __constant char hw[] = "Hello World"; __kernel void hello(__global char * A) { size_t tid = get_global_id(0); A[tid] = hw[tid]; } Kotlin code which runs OpenCL
Call TCL from Kotlin or embed TCL inside Kotlin Embedded TCL inside Kotlin TCL code which runs from kotlin puts "Hello, world!"Kotlin code which run TCL package plot import kotlinx.cinterop.* import tcl.* fun main() { var tcli = Tcl_CreateInterp() if(Tcl_Eval(tcli, "set a 1")==TCL_OK) { Tcl_EvalFile(tcli, "hello.tcl") } Tcl_DeleteInterp(tcli) }You need to install MSYS2 and tcl using below command