Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
b5ff0a69
Commit
b5ff0a69
authored
Feb 25, 2013
by
Ričardas Barkauskas
Committed by
Alexandre Julliard
Feb 26, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Rename bsize to content_size to reflect usage.
parent
2d449b76
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
11 deletions
+11
-11
arb_program_shader.c
dlls/wined3d/arb_program_shader.c
+2
-2
shader.c
dlls/wined3d/shader.c
+8
-8
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-1
No files found.
dlls/wined3d/arb_program_shader.c
View file @
b5ff0a69
...
...
@@ -3890,7 +3890,7 @@ static GLuint shader_arb_generate_pshader(const struct wined3d_shader *shader,
TRACE
(
"Created hw pixel shader, prg=%d
\n
"
,
retval
);
/* Create the program and check for errors */
GL_EXTCALL
(
glProgramStringARB
(
GL_FRAGMENT_PROGRAM_ARB
,
GL_PROGRAM_FORMAT_ASCII_ARB
,
buffer
->
b
size
,
buffer
->
buffer
));
buffer
->
content_
size
,
buffer
->
buffer
));
checkGLcall
(
"glProgramStringARB()"
);
gl_info
->
gl_ops
.
gl
.
p_glGetIntegerv
(
GL_PROGRAM_ERROR_POSITION_ARB
,
&
errPos
);
...
...
@@ -4303,7 +4303,7 @@ static GLuint shader_arb_generate_vshader(const struct wined3d_shader *shader,
TRACE
(
"Created hw vertex shader, prg=%d
\n
"
,
ret
);
/* Create the program and check for errors */
GL_EXTCALL
(
glProgramStringARB
(
GL_VERTEX_PROGRAM_ARB
,
GL_PROGRAM_FORMAT_ASCII_ARB
,
buffer
->
b
size
,
buffer
->
buffer
));
buffer
->
content_
size
,
buffer
->
buffer
));
checkGLcall
(
"glProgramStringARB()"
);
gl_info
->
gl_ops
.
gl
.
p_glGetIntegerv
(
GL_PROGRAM_ERROR_POSITION_ARB
,
&
errPos
);
...
...
dlls/wined3d/shader.c
View file @
b5ff0a69
...
...
@@ -238,7 +238,7 @@ static const struct wined3d_shader_frontend *shader_select_frontend(DWORD versio
void
shader_buffer_clear
(
struct
wined3d_shader_buffer
*
buffer
)
{
buffer
->
buffer
[
0
]
=
'\0'
;
buffer
->
b
size
=
0
;
buffer
->
content_
size
=
0
;
buffer
->
lineNo
=
0
;
buffer
->
newline
=
TRUE
;
}
...
...
@@ -263,22 +263,22 @@ void shader_buffer_free(struct wined3d_shader_buffer *buffer)
int
shader_vaddline
(
struct
wined3d_shader_buffer
*
buffer
,
const
char
*
format
,
va_list
args
)
{
char
*
base
=
buffer
->
buffer
+
buffer
->
b
size
;
char
*
base
=
buffer
->
buffer
+
buffer
->
content_
size
;
int
rc
;
rc
=
vsnprintf
(
base
,
SHADER_PGMSIZE
-
1
-
buffer
->
b
size
,
format
,
args
);
rc
=
vsnprintf
(
base
,
SHADER_PGMSIZE
-
1
-
buffer
->
content_
size
,
format
,
args
);
if
(
rc
<
0
/* C89 */
||
(
unsigned
int
)
rc
>
SHADER_PGMSIZE
-
1
-
buffer
->
b
size
/* C99 */
)
if
(
rc
<
0
/* C89 */
||
(
unsigned
int
)
rc
>
SHADER_PGMSIZE
-
1
-
buffer
->
content_
size
/* C99 */
)
{
ERR
(
"The buffer allocated for the shader program string "
"is too small at %d bytes.
\n
"
,
SHADER_PGMSIZE
);
buffer
->
b
size
=
SHADER_PGMSIZE
-
1
;
buffer
->
content_
size
=
SHADER_PGMSIZE
-
1
;
return
-
1
;
}
if
(
buffer
->
newline
)
{
TRACE
(
"GL HW (%u, %u) : %s"
,
buffer
->
lineNo
+
1
,
buffer
->
b
size
,
base
);
TRACE
(
"GL HW (%u, %u) : %s"
,
buffer
->
lineNo
+
1
,
buffer
->
content_
size
,
base
);
buffer
->
newline
=
FALSE
;
}
else
...
...
@@ -286,8 +286,8 @@ int shader_vaddline(struct wined3d_shader_buffer *buffer, const char *format, va
TRACE
(
"%s"
,
base
);
}
buffer
->
b
size
+=
rc
;
if
(
buffer
->
buffer
[
buffer
->
b
size
-
1
]
==
'\n'
)
buffer
->
content_
size
+=
rc
;
if
(
buffer
->
buffer
[
buffer
->
content_
size
-
1
]
==
'\n'
)
{
++
buffer
->
lineNo
;
buffer
->
newline
=
TRUE
;
...
...
dlls/wined3d/wined3d_private.h
View file @
b5ff0a69
...
...
@@ -407,7 +407,7 @@ enum wined3d_shader_rel_op
struct
wined3d_shader_buffer
{
char
*
buffer
;
unsigned
int
b
size
;
unsigned
int
content_
size
;
unsigned
int
lineNo
;
BOOL
newline
;
};
...
...
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