Edit *Not* Done helping BF.

edit: at the time I did not understand why they were angry, I get it now.

I sometimes am a little over posty,

mail - “I have used bvh accelerated raycast via Python to do fx in game in the game engine, and I have also used kdtree,It’s fairly simple, and a great idea, would it be in Python, or C etc? If it is python I can help with that.”

mail 2

"
I build the tree on init -> then I use a hitpoint provided by the game engine physics, but I think you will want to use the camera projection and the mouse x,y to build the raycast, from there you can get all units in a radius, you can then get the distance from the hitpoint to do the color based on a multiplier

https://ssl.gstatic.com/ui/v1/icons/mail/images/cleardot.gif"

last mail -

link to get ray to mouse cursor using BPY.

https://github.com/jesterKing/blender/blob/master/blender/release/scripts/templates_py/operator_modal_view3d_raycast.py

I was placed on moderation in the mailing list for this.

This DEFINITELY belongs in this forum section… and placing it here for maximum exposure isn’t spammy at all.

You posted three mails in a row on the bf-committers mailing list to some (to-be?) GSOC student without being a C coder yourself. Why post three mails in a row instead of one? Or why post on the mailing list at all when you could’ve just mailed the student in private? And then you make a thread here in the Latest News section and post two posts in a row again. It seems spammy to me.

I don’t really mind/care though but you should think about how you’re trying to help people. I mean, those GSOC threads are supposed to be a student - mentor/developer thing and your input is probably not important there. Neither is mine which is why I don’t post there. :stuck_out_tongue:

Trolling again are we? ( ͡° ͜ʖ ͡°)

It’s frustrating, and I do operations all the time with that kind of data, Python is not iterating, C is. I saw something I could help with, so I tried.

About the three mails, I thought that the video was relevant after I sent the first mail, later I found the code to get a ray to the cursor.

I explained basically in detail the steps you need, Python or not.

I love to learn,
I love to teach

I never did anything with any intention of causing a problem,
Yet I am treated that way.

There is no, ‘edit post’ in email.

Build tree, raycast to HitPoint, use Hitpoint and radius to get local verts from bvhtree, ,(or PBVHTree in this case)

I really wouldn’t worry too much. The list is meant to discuss GSOC applications from students and although you may be enthusiastic to help it could be confusing to the students and the mentoring process.

This was not on the GSOC list… this was on the blender committers list.

BPR… not again, just relax :wink:

Which is exactly why you need to put much greater thought and consideration into an email before you send it.

This was a student seeking feedback on a proposal from someone active in Blender development with enough experience to be a GSOC mentor. Without being either of those things - and likely without reading his proposal - you began offering suggestions that weren’t particularly useful or relevant to what he asked for. Someone not paying attention might have gotten the impression that you are in a position to be a GSOC mentor. You’re not.

Slow down. Take a breath. We understand that you’re excited. But know that email is not chat nor is it a forum. What’s permissible here and on IRC is not really appropriate there.

Also consider the fact that you’re writing to an unknown audience. When you think you’re teaching, it’s very likely that you’re either stating something that is either obvious or not wholly relevant to the actual question. That also applies here.

Advice deleted.

I agree with those above, I think you need to cut down on the usage of the mailing list as a Q&A platform. That would be along with cutting down on the random plugs for the BGE (the mailing list is geared towards discussion about Blender development, not usage and definitely not requests, unless it inquires about becoming a developer or inquires about the way an existing feature is implemented).

actually, I almost have all of the math needed to paint weights using nothing but python

ideasman added the last pieces the other day mathutils.bvhtree.BVHTree.find_nearest_range

if more tools were using C as a workhorse and python as a messenger, you could use parts from other tools to make new tools that were fast in python.

Feed Bmesh into BVHTree - (no need for from poly in BPY)

Raycast at cursor on tool activation -> get hitpoint

Sphere test -> sphere intersecting faces adds faces to list -> potentially add something later to reject ‘islands’

Short list is built from vertices in faces in radius

vertices inside range ‘color’ (used loosely) are changed by distance from hitPoint Vs tool settings.

it will run fast as long as you’re not having 2 million faces inside the intersection of the sphere test.

And hence why no-one takes you particularly seriously.
Why did you post the above post? Does it add anything to the current discussion? For a person reading the thread, it’s just random information unrelated to the conversation at hand.

The issue is that the mailing list is geared towards topics pertaining to development in the Blender source code (which means developing new functionality in C or C++, not Python).

The only exceptions would be things like the interface and the development of the Python API itself.

yeah, well the more tools are made in python from C api calls, the more those pieces can be re-used in coding flexible tools, easily edited via python by the end user.

It takes a decent person to admit a mistake.

Sure, if you like your tools having perhaps 1 percent of the performance they would otherwise have unless you use an interpreter like PyPy.

It doesn’t matter what your narrative about Python says (see your previous posts for reference), the data shows that optimized Python code (especially if it’s of the standard flavor) will always be slower than optimized C code.

In 3D software, you want your tools to have as much performance as possible, especially if you end up working with millions of polygons.

yes, the C version of the tool will be faster, however you can’t make a new custom tool in python with it.

Flexible / Fast is a fine line to walk.

exposing the tools to python can only help, and in no way replaces C, it adds to it.

also, if you pass pointers to data using python, and don’t do any heavy lifting with it, it’s quite fast.

it’s just a postman, delivering task lists.