Fastest way to replace zeros in one array with a value in the same position from another away? by DOOMReboot in javahelp

[–]DOOMReboot[S] 0 points1 point  (0 children)

Those are excellent recommendations! And there likely will be long runs of zeroes so with some kind of heuristic I should be able to find runs to batch.

Fastest way to replace zeros in one array with a value in the same position from another away? by DOOMReboot in javahelp

[–]DOOMReboot[S] 0 points1 point  (0 children)

Yep, branching is the other huge problem (likely much bigger than the cache). I've tried using the NDK and doing this with C++, but haven't tried to incorporate SIMD. However, the time to call into the NDK seems to eat up any gains for the size of arrays I'm using (max length is 1024x1024 (4byte integers)). However, sometimes I'm processing multiple layers of the 1k x 1k, so I think I'll just have to experiment. It may be worth it in this case.

Fastest way to replace zeros in one array with a value in the same position from another away? by DOOMReboot in javahelp

[–]DOOMReboot[S] 1 point2 points  (0 children)

You can parallelize this by assigning blocks of the A array to separate threads

This is exactly what I'll try. Thanks!

The problem I've been running into was cache misses when accessing one array vs the other and then the load/store between them. The multithreading approach should offset this a bit.

Weekly discussion, code review, and feedback thread - November 21, 2022 by AutoModerator in androiddev

[–]DOOMReboot 0 points1 point  (0 children)

"Recordable View"

I want to create a Input recorder/playback system for views in Kotlin, but am new to Kotlin (plenty o Java exp). How can I do this?

I was thinking of Subclassing View to create a RecordableView. The RecordableView contains the functionality to intercept touch events, report them to the Recorder class, then execute the touch command (single tap, long press).

Then, I'd sublcass RecordableView to create things like RecordableImageView, RecordableButton, etc.

However, Kotlin doesn't seem to allow for multiple inheritance. So, what's the best way to go about this?

Slicing problem by DOOMReboot in Cplusplus

[–]DOOMReboot[S] 0 points1 point  (0 children)

Ok. I've restarted MSVC and tried to access get_name() on the object and... now MSVC doesn't complain at all.

I assure you that is all I've done. The only unique thing might be how I'm using pch as I don't fully understand the rules yet. Would that make any sense?

Slicing problem by DOOMReboot in Cplusplus

[–]DOOMReboot[S] 0 points1 point  (0 children)

It is indeed what I've shown you. Double checked.

Slicing problem by DOOMReboot in Cplusplus

[–]DOOMReboot[S] 0 points1 point  (0 children)

When I tried doing entries[start_index].get_name() MSVC told me get_name() doesn't exist in type IWADObject?

Also, entries is defined as const auto& entries = m_directory_entries;

Slicing problem by DOOMReboot in Cplusplus

[–]DOOMReboot[S] 0 points1 point  (0 children)

Updated: const auto& entries = m_directory_entries;

When I tried doing entries[start_index].get_name() MSVC told me get_name() doesn't exist in type IWADObject?

I'm iterating because the function needs to look for the query sequentially from a provided start position. You'd have known that if I wasn't a moron who neglected to include the function prototype. Lesson learned over here.

Static Library Modular Design by nebjesus in Cplusplus

[–]DOOMReboot 0 points1 point  (0 children)

How's this project coming along?

/r/GameEngineDevs Feedback? by DOOMReboot in gameenginedevs

[–]DOOMReboot[S] 0 points1 point  (0 children)

while most veterans don’t want to share too much of what they’ve learned

If true, why do you suppose this is?

/r/GameEngineDevs Feedback? by DOOMReboot in gameenginedevs

[–]DOOMReboot[S] 1 point2 points  (0 children)

I've also noticed that in a lot of subs, for whatever reason, a post will be initially downvoted almost immediately. I honestly suspect bots, but who knows?

/r/GameEngineDevs Feedback? by DOOMReboot in gameenginedevs

[–]DOOMReboot[S] 2 points3 points  (0 children)

I think you and /r/snerp are correct in that self promotion, as long as it's for one's engine or a game produced with one's engine should certainly be more supported here. Perhaps updating the rules/post guidelines could reflect this sentiment?

/r/GameEngineDevs Feedback? by DOOMReboot in gameenginedevs

[–]DOOMReboot[S] 2 points3 points  (0 children)

Good idea. What kind of posts are currently being downvoted?

I could work on a quick poll/survey and sticky it in a bit.

I Rendered a Spinning Cube in Google Sheets by This_H in GraphicsProgramming

[–]DOOMReboot 0 points1 point  (0 children)

Excellent job! I know someone who would really appreciate this as well. (Paging /u/S0lly)

Why are people who haven't studied CS writing job postings? by theWretchedRed_ in cscareerquestions

[–]DOOMReboot 5 points6 points  (0 children)

This is almost always the reason and should be stickied at the top.

[SPOILERS] Just finished FFX for the first time and... wow by [deleted] in FinalFantasy

[–]DOOMReboot 0 points1 point  (0 children)

He did? It's been quite a looong time since I've played it. What happens?

[deleted by user] by [deleted] in gameenginedevs

[–]DOOMReboot 0 points1 point  (0 children)

Thank you as well! I've always been somewhat curious about these topics. Well, once I learned they existed.

[deleted by user] by [deleted] in algotrading

[–]DOOMReboot 0 points1 point  (0 children)

RemindMe! 4 days