Render Window Patch to cycling backwards here

In the render window you have 8 slots and you can cycle forward using J key.

Compiling with the modifications I attach you will have H key to cycle backwards. This is great when you just want compare two slots only, for example slot 4 and slot 5. You press H and J continuously to switch between them.

I hope some blender developer sees this thread and include the changes in next blender version. I include a README.txt file with the instructions. Is a linux text file so perhaps in a windows system it will look unreadable?

Atachment in next post.

Here is the file. Tested in Ubuntu 10.10. You must replace three files and compile blender
as explained in the readme.txt

Now in the Render Window you have:

  • H key to go backwards (J key go forwards)
  • X key to delete a slot
  • 16 slots

Just in case you were wondering…

svn diff > patch_file.diff

I think I can’t ask to a windows user to patch the files. Much easier just overwrite the old files with the new ones and compile. Probably there are people compiling blender that don’t know programming, just follow instructions to compile (see Blender Cookie video of how to compile blender and so).
This is my first look on the code. It was really fun. I want to correct three more things and then I will create my own graphicall builds (for linux 64bit only) if my modifications don’t go to trunk. I usually have all the render slots filled and usually I need to compare just two slots and being able to go backwards with H and forwards with actual J key is a must in my opinion. Also if anyone is interested in have more slots just ask. It is only to change a value in a file I don’t remember just now, from 8 to the value you desire. I think a better value is 16 but not tested yet if it has any problem to change it.

Here is the Blender Patch Tracker, which is where you submit all code that you want to get into the Blender trunk if you’re not a developer. (Other than code that fixes bugs, which you submit either attached to a new bug report or in the comments of an open one).

This sounds awesome! I’m on windows, and I’m neither a compiler nor programmer, so I too hope this makes it to trunk …
Increasing the number of available render slots sounds good, but what about exposing the control to the user’s discretion?
Something else I’ve always wanted to see but have no idea how to implement is the ability to erase render slots. That’s gotta be possible, and would be a very nice feature, if possible. Any chance you’d be interested in looking into that?
And this may be pushing it a bit, but perhaps a larger slot preview ala the new sculpt-brush preview ?
Thanks! Hope I can use this soon :smiley:

Just saying…

If you want anyone to look at your changes then you need to do it as a patch because replacing whole files is not really the way it’s done since there is no good way to see what you changed that way. Patch files are pretty much the standard – even for windows (l)users…

Please make a correct patch file of it, it is much, much easier to handle. And please submit it to the patch tracker too, it is a valuable features which has been discussed.

Thanks a lot Bao2, I’ve been wanting to be able to do this.

And I svn diff’d it here http://www.pasteall.org/17208/diff

Thanks for this great patch Bao2.

Thanks for the diff file Écrivain.

If you want to try this feature, click here.

I added X key to delete a slot, and 16 slots instead 8

New link in post 2 of this thread.

wow. awesome. with the delete too even. …
I am becoming quite tempted to attempt compiling blender under win xp sp3 here … hmmmmmmmmmmmm

this ABSOLUTELY needs to make it into trunk!!!

One of the files changed in the svn repository, so I updated the file. New file in Post 2 of this thread.

I decided to fill the submit a patch thing and…

A guy called Shane Ambler submitted this patch in 12 August 2010:

"While using render slots to compare differences between settings I thought it would be useful
to navigate to specificslots instead of cycling through them one by one. This patch allows you
to use keyboard 1 through 0 to go directly to a specific render slot.
The available render slots has also been increased to 10.

From a comment on this at blenderstorm I have an updated patch
that also adds bi-directional slot cycling. I have used H for backwards layer cycling."

So it is already in queue. I don’t like the idea of keys 1 to 10 to call the slots because I like
more 16 slots instead 10. I like he choosed H too to go backwards. And he forgot about X
to delete a slot that seems also valuable to have.

posted a comment over there. I REALLY really really hope the clear render slot function gets added to trunk. Direct switching is nice too, but the clearing I have wanted SOOO many times.

I did another little change to the code to fix something that was annoying to me.
In the render window you click right button on the image and an info line shows the RGB Alpha and Z values of the pixels you are clicking.
The info shows in the way: R: value G: value B: value A: value… and I changed it to RGB: value, value, value… and also did more clear the separations with “||”. It was difficult to look for the RGB values the way it was before. Look now how easy it shows:

http://img834.imageshack.us/img834/2066/screenshotot.png

The changes were these:

Index: source/blender/editors/space_image/image_draw.c
===================================================================
--- source/blender/editors/space_image/image_draw.c    (revision 33594)
+++ source/blender/editors/space_image/image_draw.c    (working copy)
@@ -129,23 +129,23 @@
     char str[256];
     int ofs;
     
-    ofs= sprintf(str, "X: %4d Y: %4d ", x, y);
+    ofs= sprintf(str, "XY: %4d, %4d ", x, y);
     if(cp)
-        ofs+= sprintf(str+ofs, "| R: %3d G: %3d B: %3d A: %3d ", cp[0], cp[1], cp[2], cp[3]);
+        ofs+= sprintf(str+ofs, "|| RGB: %3d, %3d, %3d || A: %3d ", cp[0], cp[1], cp[2], cp[3]);
 
     if(fp) {
         if(channels==4)
-            ofs+= sprintf(str+ofs, "| R: %.3f G: %.3f B: %.3f A: %.3f ", fp[0], fp[1], fp[2], fp[3]);
+            ofs+= sprintf(str+ofs, "|| RGB: %.3f, %.3f, %.3f || A: %.3f ", fp[0], fp[1], fp[2], fp[3]);
         else if(channels==1)
-            ofs+= sprintf(str+ofs, "| Val: %.3f ", fp[0]);
+            ofs+= sprintf(str+ofs, "|| Val: %.3f ", fp[0]);
         else if(channels==3)
-            ofs+= sprintf(str+ofs, "| R: %.3f G: %.3f B: %.3f ", fp[0], fp[1], fp[2]);
+            ofs+= sprintf(str+ofs, "|| RGB: %.3f, %.3f, %.3f ", fp[0], fp[1], fp[2]);
     }
 
     if(zp)
-        ofs+= sprintf(str+ofs, "| Z: %.4f ", 0.5+0.5*(((float)*zp)/(float)0x7fffffff));
+        ofs+= sprintf(str+ofs, "|| Z: %.4f ", 0.5+0.5*(((float)*zp)/(float)0x7fffffff));
     if(zpf)
-        ofs+= sprintf(str+ofs, "| Z: %.3f ", *zpf);
+        ofs+= sprintf(str+ofs, "|| Z: %.3f ", *zpf);
     
     glBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA);
     glEnable(GL_BLEND);

Campbell just committed alt+J backwards cycling.

Cool. thx for the heads up. I really really really hope someone commits clearing the render slots as well. I don’t see why not …

Hey that’s great, but how do target a render slot before rendering out (ie. the next available one)?

J for the next available slot. This has not changed, it does what it did before.
Campbell only added Alt+J (instead my proposition H) to go backwards (reverse mode called by Campbell). He probably wanted to stay consistent and use Alt key to reverse like it is done in parenting and so. But I really liked more using H because the hand on the keyboard is much less stressing. But I am using now Campbell Alt+J.
I think they don’t look at patches, perhaps because they are in a hurry fixing bugs. I hope when things calm down a little after first release of 2.5 they look at all the proposed patches because I almost want all of them in blender.