Age | Commit message (Collapse) | Author |
|
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
|
|
|
|
|
|
|
|
Now only background images remained to be ported. Plus implement
GLSL for dithering and RGB curves.
|
|
- GLSL shader wasn't aware of alpha predivide option,
always assuming alpha is straight. Gave wrong results
when displaying transparent float buffers.
- GLSL display wasn't aware of float buffers with number
of channels different from 4, crashing when trying to
display image with different number of channels.
This required a bit larger changes, namely now it's
possible to pass format (GL_RGB, GL_RGBAm GL_LUMINANCE)
to glaDrawPixelsTex, This also implied adding format to
glaDrawPixelsAuto and modifying all places where this
functions are called.
Now GLSL will handle both 3 and 4 channels buffers,
single channel images are handled by CPU.
- Replaced hack for render result displaying with a bit
different hack.
Namely CPU conversion will happen only during render,
once render is done GLSL would be used for displaying
render result on a screen.
This is so because of the way renderer updates parts
of the image -- it happens without respect to active
render layer in image user. This is harmless because
only display buffer is modifying, but this is tricky
because we don't have original buffer opened during
rendering.
One more related fix here was about when rendering
multiple layers, wrong image would be displaying when
rendering is done. Added a signal to invalidate
display buffer once rendering is done (only happens
when using multiple layers). This solves issue with
wrong buffer stuck on the display when using regular
CPU display space transform and if GLSL is available
it'll make image displayed with a GLSL shader.
- As an additional change, byte buffers now also uses
GLSL display transform.
So now only dutehr and RGB curves are stoppers for
using GLSL for all kind of display transforms.
|
|
|
|
Uses GLSL for drawing image in Image Editor space.
This requires change in image_buffer_rect_update, so
original float buffer is being updated as well. This
is unlikely be something bad, but will keep an eye
on this change.
Also no byte buffer allocation happens there, this
is so because byte buffer used for display only
and in case of GLSL display such allocation and
partial update is just waste of time.
Also switched OpenGL render from using CPU color
space linearization to GLSL color space transform.
Makes OpenGL rendering pretty much faster (but
still slower than in 2.60).
internal changes:
- Added functions to setup GLSL shader for color
space conversion in colormanagement.c. Currently
conversion form a colorspace defined by a role to
linear space is implemented. Easy to extend to
other cases.
- Added helper functions to glutil.c which does
smarter image buffer draw (calling all needed OCIO
stuff, editors now could draw image buffer with a
single function call -- all the checks are done in
glutil.c).
- Also added helper function for buffer linearization
from a given role to glutil.c. Everyone now able to
linearize buffer with a single call.
This function will do nothing is GLSL routines fails
or not supported.
And one last this: this function uses offscreen
drawing, could potentially give issues on some
cards, also will keep an eye on this.
|
|
also rename mesh_getVertexCos() --> BKE_mesh_vertexCos_get() to match curve function.
|
|
Zooming in on images in Image window now shows pixels again (was filtered).
Now the glaDrawPixelsTex() and glaDrawPixelsAuto() have an argument to
define if images should zoom in with linear filter, or draw pixels.
|
|
Automatic switching for drawing pixel buffers via glDrawPixels or using GPU textures
It works with a User Preference limit, in megapixels, to define whether to use
GPU or direct pixel drawing. Default is now initialized to 10 MP (4k buffers).
Especially for zooming out (draw smaller) texture drawing is much smaller. Also
Nvidia cards typically draw much faster with textures in general.
Added to node backdrop first now, the other editors follow in a next commit.
For coders: added new DNA function to initialize new struct variables, so you
don't have to sub-version files anymore.
DNA_struct_elem_find(fd->filesdna, "structname", "typename", "varname")
"filesdna" is the sdna description of the current file being versioned.
|
|
|
|
also use M_SQRT1_2 in math_rotation.c
|
|
|
|
Any identifier that looks like an OpenGL identifier, but isn't, causes a false alarm by the glreport.py tool. Most of these were in comments so I just rephrased the comments. There were a couple of static functions/macros that were easy enough to rename. Only the glTexco and glIndex fields of the DMVertexAttribs struct was public and had non-local uses.
|
|
|
|
changed the
image editor checkerboard pattern to be the same as cycles viewport.
|
|
|
|
already used a lot and part of proposed style guide).
|
|
- spelling - turns out we had tessellation spelt wrong all over.
- use \directive for doxy (not @directive)
- remove BLI_sparsemap.h - was from bmesh merge IIRC but entire file commented and not used.
|
|
where the values are unchanged.
|
|
also have doxygen ignore *.py files and fix some warnings.
|
|
without the underscores these clogged up the namespace for autocompleation which was annoying.
|
|
settings.
For premultiplied alpha images, this makes any color space conversion for the image
or render output work on color without alpha multiplied in.
This is typically useful to avoid fringing when the image was or will be composited
over a light background. If the image will be composited over a black background on
the other hand, leaving this option off will give correct results.
In an ideal world, there should never be any color space conversion on images with
alpha, since it's undefined what to do then, but in practice it's useful to have
this option.
Patch by Troy Sobotka, with changes by me.
|
|
http://markmail.org/message/fp7ozcywxum3ar7n
|
|
added xpm -> opengl stipple conversion script.
|
|
|
|
- fixed bug in paste material, exposed by stricter warnings.
- removed/renamed various shadowed vars.
- removed BGE lamp.colour, only allow lamp.color attribute.
|
|
|
|
|
|
set the draw method to triple buffer or overlap depending on the
configuration. Ideally I could get all cases working well with triple
buffer but it's hard in practice. At the moment there are two cases
that use overlap instead:
* opensource ATI drives on linux
* windows software renderer
Also added a utility function to check GPU device/os/driver.
|
|
|
|
- 1st stage: Linear Workflow
This implements automatic linear workflow in Blender's renderer. With the
new Colour Management option on in the Render buttons, all inputs to the
renderer and compositor are converted to linear colour space before
rendering, and gamma corrected afterwards. In essence, this makes all
manual gamma correction with nodes, etc unnecessary, since it's done
automatically through the pipeline.
It's all explained much better in the notes/doc here, so please have a look:
http://wiki.blender.org/index.php/Dev:Source/Blender/Architecture/Colour_Management
And an example of the sort of difference it makes:
http://mke3.net/blender/devel/rendering/b25_colormanagement_test01.jpg
This also enables Colour Management in the default B.blend, and changes the
default lamp falloff to inverse square, which is more correct, and much
easier to use now it's all gamma corrected properly.
Next step is to look into profiles/soft proofing for the compositor.
Thanks to brecht for reviewing and fixing some oversights!
|
|
* Rename BIF_transform/retopo.h to ED_transform/retopo.h
for consistency.
* Move MESH_OT_duplicate_add to editmesh_add.c.
* Remove some code from BIF_gl.h which is not needed there
anymore.
|
|
- drawing code cleanup
- use of BLF_font in own string drawing, needs to be aligned with uiStyles still.
- thumbnail scaling now done on graphics card via new glaDrawPixelsTexScaled (slightly modified glaDrawPixelsTex)
|
|
Commit of WIP code (what code isn't wip, these days ;)
- only drawing code as basis to work further from (and have less conflicts between different systems I work on)
|
|
- View3D: added ALT+B clipping operator. Note this needs a call to
the new function view3d_operator_needs_opengl(C) to ensure you
can use opengl functions. Event handling by default doesn't set
opengl per subwindow, it's also forbidden to draw then!
We might consider to tag operators that need opengl...
- Forgot to include creator.c fix for loading builtin vector font
|
|
* G.version removed, use BLENDER_VERSION
* G.order removed, ENDIAN_ORDER
* G.vd, G.sipo, G.buts, G.sima, .. removed.
* G.qual removed
* G.simulf removed (was unused in 2.4x)
* error() and some other unused stubs removed
|
|
- Added standard "tweak" gesture operator, which can be set per region, to
generate EVT_TWEAK events. You can configure tweaks for any mouse button
and have handlers for such events check for modifiers etc.
It even stores tweak direction (8 directions). Might be fun to experiment
with tweak gestures N, S, etc. :)
In general it can be used to replace the current tweak code in 2.48
(std_rmouse_transform).
Test added: on screen level it now adds LMB tweaks, if tweak-South it splits
the area. Will be removed of course.
- Added to Border operator a property to store event used to end border with.
- Moved the "AZone" triangle drawing to the right context (area). It was on
screen level, not respecting area-redraws. Also cleaned up drawing for it,
and moved the "swap buffers indicator" square to look nicer. Those squares
are only for test!
- event-match function had bad code for checking for event-value. Made a
"KM_ANY" define so keymaps can be defined ignoring event values.
- Gesture todo: lasso, "real gesture" (like blender now has)
|
|
* Added functions to generate Timer events. There was some unfinished code to
create one timer per window, this replaces that with a way to let operators
or other handlers add/remove their own timers as needed. This is currently
delivered as an event with the timer handle, perhaps this should be a notifier
instead? Also includes some fixes in ghost for timer events that were not
delivered in time, due to passing negative timeout.
* Added a Message event, which is a generic event that can be added by any
operator. This is used in the UI code to communicate the results of opened
blocks. Again, this may be better as a notifier.
* These two events should not be blocked as they are intended for a specific
operator or handler, so there were exceptions added for this, which is one
of the reasons they might work better as notifiers, but currently these
things can't listen to notifier yet.
* Added an option to events to indicate if the customdata should be freed or
not.
* Added a free() callback for area regions, and added a free function for
area regions in blenkernel since it was already there for screens and areas.
* Added ED_screen/area/region_exit functions to clean up things like operators
and handlers when they are closed.
* Added screen level regions, these will draw over areas boundaries, with the
last created region on top. These are useful for tooltips, menus, etc, and
are not saved to file. It's using the same ARegion struct as areas to avoid
code duplication, but perhaps that should be renamed then. Note that redraws
currently go correct, because only full window redraws are used, for partial
redraws without any frontbuffer drawing, the window manager needs to get
support for compositing subwindows.
* Minor changes in the subwindow code to retrieve the matrix, and moved
setlinestyle to glutil.c.
* Reversed argument order in WM_event_add/remove_keymap_handler to be consistent
with modal_handler.
* Operators can now block events but not necessarily cancel/finish.
* Modal operators are now stored in a list in the window/area/region they were
created in. This means for example that when a transform operator is invoked
from a region but registers a handler at the window level (since mouse motion
across areas should work), it will still get removed when the region is closed
while the operator is running.
|
|
|
|
|
|
- removed editors/area and put this all in screen
- added first python calls (note, a new c file for scriptlinks)
- added view3d editor callbacks (no drawing yet)
- added files in editors/interface
(Cmake and Scons has to be fixed, help welcome!)
- now areas/headers are being converted on file read
- note: previously saved 2.50 files will crash!!! (.B.blend)
- area regions are being drawn, first handler for cursor added (on edge)
- window duplicate and scale works correct for screen subdiv
Todos for me:
- need to fix things in syntax (function names) a bit still
- more operators for screen
- define how Context will work... still unresolved when it gets set
- docs!
Reviews of code structure is welcome!
There are also more todos now for others, but it can wait a couple of days
|
|
adding new windowmanager module, and the first bits of new editors
module.
|