-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTODO
79 lines (71 loc) · 3.36 KB
/
TODO
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
done - indentation
done - hpp to EDSL
done - storage to EDSL
done - pretty print
done - hpp
done - cpp
done - include support: baked in
done - c++ - working ipad program with generated backend
android java opengl es 2.0:
done - first handwritten opengl code with android studio
done - collect opengl calls into an ADT (reify gl commands)
done - generate IR ADT for Java
done - write LambdaCube.RT Java package
done - generate enum functions
done - generate global functions into a special class
java backend:
problematic things to solve:
done - switch on ADT (should be a primitive)
done - remove `auto` type, instead use explicit type annotation
done - union in: Stream, UniformValue (used in c++)
done - remove record value (used in setUniform methods)
done - void* type (used in c++, can not be used in Java)
done - nsPat for DDL ADT constructor enum
done - nsPat for custom
done - use explicit type for foreach iterator
done - handle Util procedure calls (static methods)
done - mark methods that throws exception (marks all)
done - higher level: glGenTextures, glGenFramebuffers, glDeleteTextures, glDeleteFramebuffers
done - higher level: glShaderSource, glGetUniformLocation, glGetAttribLocation
done - remove struct record construction/handle it properly in heap
done - higher level: glUniform2iv, glUniformMatrix2fv, glVertexAttrib2fv, GLVertexAttribPointer
done - remove: addr, cast - use GLPrim instead
done - handle type synonyms for: V2F, V2I, etc: do not use generics for V2/V3/V4 on java use specialised types instead
irrelevant - handle the case when LC types has mapped to same native types e.g. int -> Integer. uint -> Integer
done - better representation of V2,V3,V4 and matrices (e.g. for jave use arrays: []). idea: keep the IR representation in the api, but use arrays in uniform values
affected functions/methods/classes:
UniformValue
setUniformValue
setUniform (PipelineInput)
setUniform (Object)
done - allocate containers in constructors
done - setUniformValue call on stream data rendering
done - better representation of vertex/index buffers
Buffer: use NativeArray to store data
maybe we should use native buffer: IntBuffer/FloatBuffer
done - Buffer: use lower level data input api
remove high level adds and use this:
public Integer add(java.nio.Buffer buf,int elemGLType, int elemCount) throws Exception {
NativeArray = type[]
NativeBuffer: that can be created from native array (wrap)
done - use heap model only (do not create values on stack)
done - remove: Ptr type, deref
done - remove: SmartPtr, Ref (use shared_ptr everywhere in c++)
diappeared - variable initialization
now focus:
GLES20: C++, Java
DX11: C#
backend matrix:
GLES20 WebGL1 GL33 GL45 GLES30 GLES31 DX11 Vulkan Metal
C++ X X X X X X X X
Java X X X X X ? ? ?
JavaScript X
PureScript X
Haskell ? X X ? ? ? X ?
C# ? ? ? ? ? X ? ?
Python ? X X ? ? ? ? ?
Swift X ? ? X X ? ? X
API similarities:
GLES20 ~ WebGL1
GL33 ~ GLES30
GL45 ~ GLES31