ホーム › Graphics.OpenGL › glEdgeFlagPointer
glEdgeFlagPointer
関数エッジフラグ頂点配列の配置を指定する。
シグネチャ
// OPENGL32.dll
#include <windows.h>
void glEdgeFlagPointer(
INT stride,
const void* pointer
);パラメーター
| 名前 | 型 | 方向 |
|---|---|---|
| stride | INT | in |
| pointer | void* | in |
戻り値の型: void
各言語での呼び出し定義
// OPENGL32.dll
#include <windows.h>
void glEdgeFlagPointer(
INT stride,
const void* pointer
);[DllImport("OPENGL32.dll", ExactSpelling = true)]
static extern void glEdgeFlagPointer(
int stride, // INT
IntPtr pointer // void*
);<DllImport("OPENGL32.dll", ExactSpelling:=True)>
Public Shared Sub glEdgeFlagPointer(
stride As Integer, ' INT
pointer As IntPtr ' void*
)
End Sub' stride : INT
' pointer : void*
Declare PtrSafe Sub glEdgeFlagPointer Lib "opengl32" ( _
ByVal stride As Long, _
ByVal pointer As LongPtr)
' VBA7前提(PtrSafe)。32bit Office では LongPtr→Long。Integer=16bit / Long=32bit / LongLong=64bit。import ctypes
from ctypes import wintypes
glEdgeFlagPointer = ctypes.windll.opengl32.glEdgeFlagPointer
glEdgeFlagPointer.restype = None
glEdgeFlagPointer.argtypes = [
ctypes.c_int, # stride : INT
ctypes.POINTER(None), # pointer : void*
]require 'fiddle'
require 'fiddle/import'
lib = Fiddle.dlopen('OPENGL32.dll')
glEdgeFlagPointer = Fiddle::Function.new(
lib['glEdgeFlagPointer'],
[
Fiddle::TYPE_INT, # stride : INT
Fiddle::TYPE_VOIDP, # pointer : void*
],
Fiddle::TYPE_VOID)#[link(name = "opengl32")]
extern "system" {
fn glEdgeFlagPointer(
stride: i32, // INT
pointer: *const () // void*
);
}
// crates: windows-sys provides ready-made bindings for this API.$sig = @"
[DllImport("OPENGL32.dll")]
public static extern void glEdgeFlagPointer(int stride, IntPtr pointer);
"@
$api = Add-Type -MemberDefinition $sig -Name 'OPENGL32_glEdgeFlagPointer' -Namespace Win32 -PassThru
# $api::glEdgeFlagPointer(stride, pointer)#uselib "OPENGL32.dll"
#func global glEdgeFlagPointer "glEdgeFlagPointer" sptr, sptr
; glEdgeFlagPointer stride, pointer
; stride : INT -> "sptr"
; pointer : void* -> "sptr"#uselib "OPENGL32.dll"
#func global glEdgeFlagPointer "glEdgeFlagPointer" int, sptr
; glEdgeFlagPointer stride, pointer
; stride : INT -> "int"
; pointer : void* -> "sptr"; void glEdgeFlagPointer(INT stride, void* pointer)
#uselib "OPENGL32.dll"
#func global glEdgeFlagPointer "glEdgeFlagPointer" int, intptr
; glEdgeFlagPointer stride, pointer
; stride : INT -> "int"
; pointer : void* -> "intptr"import (
"golang.org/x/sys/windows"
"unsafe"
)
var (
opengl32 = windows.NewLazySystemDLL("OPENGL32.dll")
procglEdgeFlagPointer = opengl32.NewProc("glEdgeFlagPointer")
)
// stride (INT), pointer (void*)
r1, _, err := procglEdgeFlagPointer.Call(
uintptr(stride),
uintptr(pointer),
)
_ = err // syscall.Errno (valid when the call sets last-error)
_ = r1 // voidprocedure glEdgeFlagPointer(
stride: Integer; // INT
pointer: Pointer // void*
); stdcall;
external 'OPENGL32.dll' name 'glEdgeFlagPointer';result := DllCall("OPENGL32\glEdgeFlagPointer"
, "Int", stride ; INT
, "Ptr", pointer ; void*
, "Int") ; return: void●glEdgeFlagPointer(stride, pointer) = DLL("OPENGL32.dll", "int glEdgeFlagPointer(int, void*)")
# 呼び出し: glEdgeFlagPointer(stride, pointer)
# stride : INT -> "int"
# pointer : void* -> "void*"
# なでしこ1は32bit・ANSI(Shift_JIS)。文字列=char*(ANSI)、ポインタ/ハンドル=void*(4byte)。