Age | Commit message (Collapse) | Author |
|
|
|
Strip unindented comment blocks - mainly headers to avoid conflicts.
|
|
DrawPixels method.
|
|
|
|
The basic shader needs to be temporarily disabled in this case.
Add macros for temp store/restoring the state.
|
|
This commit avoids draw of invisible parts of image in image editor,
making it faster to re-draw the image.
Especially handy when painting on a high-res image when zoomed-in.
|
|
|
|
Everything I've tested works fine without these hacks. Variety of Mac, Linux, Windows, Intel, nVidia, AMD.
If these workarounds are for old unsupported systems let's clean house.
Reviewers: #opengl_gfx
Differential Revision: https://developer.blender.org/D1707
|
|
|
|
|
|
- no need to allocate client memory up front
- delete unneeded GL calls
- set default alpha test function on exit
|
|
The is intended to replace the deprecated glPolygonStipple() calls with a shader
based alternative, once we switch over to GLSL shaders.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D1688
|
|
Comment says this is from the MacOS 10.5 era. Surely it’s been fixed by
now. If nobody complains in the next few months let’s delete this.
|
|
It’s still immediate mode, but at least it’s shorter & clearer.
|
|
|
|
Differential Revision: https://developer.blender.org/D1645
|
|
|
|
|
|
|
|
Moral of the story: Make sure that size_t is used whenever pointer
arithmetic is involved. For images, that basically means whenever any
squared dimensions are involved. Casting an operand to size_t early in
the operation is usually sufficient to force the entire operation to
size_t.
There might still be places lurking where we don't support this
correctly. This has been tested with render pipeline, quite a few image
functions (meaning we can paint on such images now, albeit somewhat
slowly ;) ) and export to jpeg. Too many places in code to check so I
guess we'll be handling cases as they come.
Don't try this at home unless you have an immense ammount of RAM.
First GPixel render of suzanne in the multiverse can be found here:
http://download.blender.org/demo/test/suzanne-billion-pixel.jpg
Can be viewed from blender (takes about 3.3 GB after loading but may
take more during loading so 8GB might be more safe to try this).
|
|
loopcuts on cube have zfighting.
|
|
This makes selection fail in simple cases,
default cube subdiv 10x for eg.
|
|
|
|
|
|
|
|
In this case we can calculate an offset without worrying about
perspective correction. Unfortunately if looking from a camera we still
have depth issues here. There's no really general case that can fix this
so I'm leaving this as is.
|
|
Issue is zfighting with wire of mesh when parts of the mesh are close
together. We can make this slightly better by reducing the offset,
however this offset is calculated pre-perspective division and can vary
greatly with distance. Correct approach would be using polygon offset,
however we draw mesh wireframes as lines, (not polygons with polygon
mode line) so this approach will not work.
Alternatively, we could set an offset in a shader, however we don't have
code for that either.
|
|
Comments only, no functional change.
|
|
|
|
|
|
shorts would wrap sometimes & many inputs were ints already.
|
|
Preserve buffer form previous runs so it's possible to make
a compo of full frame, then draw a border and start tweaking
nodes and see updates in that border.
Main idea is to make it able to visually compare difference
between what was changed inside the border and how frame
looked before the tweaks outside of the border.
Also implemented Clear Viewer Border in compositor, shortcut
it Ctrl-Alt-B.
Reviewers: lukastoenne, jbakker
CC: venomgfx, sebastian_k
Differential Revision: https://developer.blender.org/D582
|
|
Opted to keep includes if they are used indirectly (even if removing is possible).
|
|
|
|
|
|
Was using wire or black in many places, this color is used for cursor,
camera guides, transform helper lines. So its possible to have a dark
background with light overlay color.
Patch D331 by Brita, with some edits.
|
|
|
|
also increase precision of rctf print functions
|
|
|
|
Summary:
Mainly addressed to solve old TODO with color managed fallback
to CPU mode when displaying render result during rendering.
That fallback was caused by the fact that partial image update
was always acquiring image buffer for composite output and was
only modifying display buffer directly.
This was a big issue for Cycles rendering which renders layers
one by one and wanted to display progress of each individual
layer. This lead to situations when display buffer was based on
what Cycles passes via RenderResult and didn't take layer/pass
from image editor header into account.
Now made it so image buffer which partial update is operating
with always corresponds to what is set in image editor header.
To make Cycles displaying progress of all the layers one by one
made it so image_rect_update switches image editor user to
newly rendering render layer. It happens only once when render
engine starts rendering next render layer, so should not be
annoying for navigation during rendering.
Additional change to render engines was done to make it so
they're able to merge composite output to final result
without marking tile as done. This is done via do_merge_result
argument to end_result() callback. This argument is optional
so should not break script compatibility.
Additional changes:
- Partial display update for Blender Internal now happens from
the same thread as tile rendering. This makes it so display
conversion (which could be pretty heavy actually) is done in
separate threads. Also gives better UI feedback when rendering
easy scene with small tiles.
- Avoid freeing/allocating byte buffer for render result
if it's owned by the image buffer. Only mark it as invalid
for color management.
Saves loads of buffer re-allocations in cases when having
several image editors opened with render result. This change
in conjunction with the rest of the patch gave around
50%-100% speedup of render time when displaying non-combined
pass during rendering on my laptop.
- Partial display buffer update was wrong for buffers with number
of channels different from 4.
- Remove unused window from RenderJob.
- Made image_buffer_rect_update static since it's only used
in single file.
Reviewers: brecht
Reviewed By: brecht
CC: dingto
Differential Revision: http://developer.blender.org/D98
|
|
Summary:
Uses some magic pseudo-random which is actually a
texture coordinate hashing function.
TODOs:
- Dither noise is the same for all the frames.
- It's different from Floyd's dither we've been
using before.
- Currently CPU and GPU dithering used different
implementation. Ideally we need to use the same
dither in CPU.
Reviewers: brecht
Reviewed By: brecht
Differential Revision: http://developer.blender.org/D58
|
|
|
|
|
|
|
|
Currently supports only two modes:
- Show alpha channel of the mask
- Multiply footage by the mask, which will give
you final-looking combined image.
TODO: Currently rasterization happens on every
redraw, need to cache rasterized mask
somewhere to make redraw more realtime.
|
|
The title says it all, now having curve mapping
enabled in color management settings wouldn't
force fallback from GLSL to CPU based color space
conversion.
|
|
|
|
|
|
shader for converting colors from linear to display space, based on the scene
color management settings.
if engine.support_display_space_shader(scene): # test graphics card support
engine.bind_display_space_shader(scene)
# draw pixels ..
engine.unbind_display_space_shader()
|
|
It's now default to 2D textures, and no AUTO mode at this
moment, since detecting which method is the best not so
simple.
Image drawing could manually be switched to GLSL for tests
and feedback, but for default GLSL is not so much great.
Reason of this is huge images, where operations like panning
becomes dead slow comparing GLSL vs. 2D texture.
|