Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gl-react-native-v2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Jira
Jira
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
ym
gl-react-native-v2
Commits
eb2d1b71
"testcontainers/mvnw" did not exist on "91c16c25b3e57b74de270ac5eac58fcf90c5b79a"
Commit
eb2d1b71
authored
Sep 22, 2016
by
Gaëtan Renaudeau
Committed by
GitHub
Sep 22, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #112 from pfeiffer/patch-1
Support RN 0.34
parents
9c9696de
fc446877
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
10 deletions
+11
-10
ios/GLCanvas.m
ios/GLCanvas.m
+11
-10
No files found.
ios/GLCanvas.m
View file @
eb2d1b71
...
...
@@ -14,7 +14,7 @@
#import "RCTImageSource.h"
NSString
*
imageSourceHash
(
RCTImageSource
*
is
)
{
return
is
.
imageURL
.
absoluteString
;
return
is
.
request
.
URL
;
}
NSArray
*
diff
(
NSArray
*
a
,
NSArray
*
b
)
{
...
...
@@ -338,7 +338,7 @@ RCT_NOT_IMPLEMENTED(-init)
}
_contentData
=
contentData
;
[
self
setNeedsDisplay
];
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
}
...
...
@@ -486,7 +486,8 @@ RCT_NOT_IMPLEMENTED(-init)
for
(
GLRenderData
*
child
in
renderData
.
children
)
weak_recDraw
(
child
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
[
NSString
stringWithFormat
:
@"node:%@"
,
renderData
.
shader
.
name
],
nil
);
NSString
*
nodeName
=
[
NSString
stringWithFormat
:
@"node:%@"
,
renderData
.
shader
.
name
];
RCT_PROFILE_BEGIN_EVENT
(
0
,
nodeName
,
nil
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
@"bind fbo"
,
nil
);
if
(
renderData
.
fboId
==
-
1
)
{
...
...
@@ -500,11 +501,11 @@ RCT_NOT_IMPLEMENTED(-init)
[
fbo
bind
];
glBlendFunc
(
GL_SRC_ALPHA
,
GL_ONE_MINUS_SRC_ALPHA
);
}
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
@"bind shader"
,
nil
);
[
renderData
.
shader
bind
];
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
@"bind textures"
,
nil
);
for
(
NSString
*
uniformName
in
renderData
.
textures
)
{
...
...
@@ -512,21 +513,21 @@ RCT_NOT_IMPLEMENTED(-init)
int
unit
=
[((
NSNumber
*
)
renderData
.
uniforms
[
uniformName
])
intValue
];
[
texture
bind
:
unit
];
}
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
@"bind set uniforms"
,
nil
);
for
(
NSString
*
uniformName
in
renderData
.
uniforms
)
{
[
renderData
.
shader
setUniform
:
uniformName
withValue
:
renderData
.
uniforms
[
uniformName
]];
}
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
RCT_PROFILE_BEGIN_EVENT
(
0
,
@"draw"
,
nil
);
glClearColor
(
0
.
0
,
0
.
0
,
0
.
0
,
0
.
0
);
glClear
(
GL_COLOR_BUFFER_BIT
);
glDrawArrays
(
GL_TRIANGLES
,
0
,
3
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
};
// DRAWING THE SCENE
...
...
@@ -546,7 +547,7 @@ RCT_NOT_IMPLEMENTED(-init)
}
}
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
,
nil
);
RCT_PROFILE_END_EVENT
(
0
,
@"gl"
);
}
//// utility methods
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment