Arima's Recent Forum Activity

  • Arima when you say cropping what do you refer to? Is that a step you can do in C2? I prepare my images in photoshop.

    There's a button to crop the image in C2's image editor.

    All I mean is, in photoshop, try resizing the image to 126x62 and import that into C2. Then try exporting. If it works, it's because of C2 adding a pixel width border to the image.

    DialgaBrite, you need to realize some things. I say this out of an attempt to help you.

    First of all, you need to learn to not get so upset so easily. This is a very, very important life skill. I understand it's difficult and takes work. There are many things in the world that are upsetting. People will say things you don't want to hear. Learning to remain calm and not get so upset will help you in many ways. Even though it hurts to hear, there is often even something to be learned from someone saying something you perceive as rude. Be like the Buddha under the tree - calm and still in the face of a raging emotional storm.

    A direct example of when you will need such a skill is this topic. Your game will not be accepted by Nintendo. Period. Why? I could not tell you because you don't want to hear it, but that won't change the outcome, and will simply delay your disappointment and waste your time.

    The reason is copyright.

    You can bury your head in the sand or cover your ears, try to silence people saying what you don't want to hear, it won't make any difference. It doesn't matter that you don't want to charge for your games. It doesn't matter what you think of copyright. It doesn't matter if people get away with making fan games on the internet.

    Copyright is a real thing, and if Nintendo put your game on their system they could get very real lawsuits thrown at them which would at best require taking your game off their system and at worst require boatloads of money to deal with and hurt their image. You are simply not getting a game using someone else's ip on their system. Same with playstation and xbox.

    I'm not trying to be harsh - I'm trying to point out the reality of the situation. Billions of dollars are thrown around as a result of copyright. Companies care about it. A lot. So much so that even if you were the president or prime minister you probably couldn't do anything about it.

    Ignoring it will not do you any good. Hiding from truth and reality and denying it will not help you. It will only continually disappoint and frustrate you. The reason copyright is a touchy subject is your response to it. Because you don't want to accept it. The harder you deny it and push it away, the more it will upset you. Denying reality is not a path you want to take as it will only hinder you.

    The truth can be disappointing, or hurt. It can also set you free. Either way, denying it is nothing more than lying to yourself.

    You can become wise and strong. Disappointments are a part of life, as is learning how to deal with them gracefully.

    Calmness. Honesty. Grace.

  • Also, doesn't C2 use quads for drawing in canvas2D? In which case, it's WAAAY different than 3D.

    That's incorrect. Quads use vertices and uv coordinates same as polygons. They're essentially the same thing. A quad is basically two triangular polygons. http://archive.gamedev.net/archive/refe ... index.html

    I've heard that OpenGL even sometimes automatically breaks quads into two triangular polygons. Everything I have ever read or heard on the subject matter, including from professionals in the game industry, has told me that hardware accelerated 2D is rendered in the same way 3D is in almost every circumstance. They really are essentially the same thing.

  • Thanks for that example Arima, very helpful. I see how your animation gets cropped and plays back properly without jitter. I will figure out how to align my pre-rendered 3D frames/origin similar to your 2D artwork. Thanks again, this will be a nice savings.

    Great, glad it helped!

    I would be very interested to see Ashley comment on this thread. The example given going from 8mb ram to 1mb is a very compelling reason to at least look this possibility. I have had projects where the artwork was too much for a number of devices and looking at the exported images there certainly appears to be scope for improvements to the memory usage.

    Cropping should fix that problem.

    Here is an example from an export two buttons only 128x64 are stored on a sheet 256x256. At this size it isn't a major but it is principle, I expected the packer to be more efficient.

    I'm guessing that's because of C2 adding a 1 pixel border when cropping to get 'free' edge antialiasing. If you resize the image to 126x62, does it work?

    I never said it was the best way to do it, but it is capable of doing it, with the addition of the ability to define hitboxes and sound triggers in Spriter.

    Ah, I misunderstood your point.

    That depends on how it's rotated and how often. If it's rotated in-game by rotating the sprite, then it needs to do that, along with resizing the sprite if the images are different sizes, every frame. Saving memory and still ending up with a potential framerate drop is not exactly a positive tradeoff.

    If it's rotated in memory, that makes rotation dependent upon the GPU, and since C2 strives to support non-WebGL accelerated devices as well, chances are it'd have to create a copy of the original sprite, rotate it, then remove the original sprite from memory - which would most likely involve rewriting how C2 handles images in memory, keeping in mind that when not using WebGL it loads all images from the project at once, and the memory spikes that would be caused by rotating images at runtime could push many mobile games over their limit. And that all assumes that HTML5/JS, outside of full hardware-accelerated WebGL, even has the capabilities to do it quickly. Which is questionable.

    That's actually not how it works. Think of it like this: you have a piece of real world paper, and a stamp. It doesn't matter what angle the stamp is at when it touches the paper - the gpu calculates it in real time when drawing the pixels, and needs to make no modification to the stamp itself to do so, and it incurs almost no performance hit in the process, because gpu makers have optimized the operation like crazy.

    If it worked the way you suggested, practically no 3d game would be possible because every single texture on every polygon of every model is being distorted in an uncountable number of permutations based on perspective, angle and animation. It would use a ridiculous amount of memory to do so and would be completely pointless as very little of the saved work could be used ever again. Even if instead of saving an extra copy of the texture it just overwrote the original, the quality of the texture would degrade as it got blurrier and blurrier from being filtered over and over again.

    Also, when not using webgl, canvas2d is used which is still hardware accelerated, just not as efficiently. Even software rendering such as chrome uses still doesn't need to use more image data in memory to rotate a sprite because it emulates the real time process hardware acceleration uses.

    That's making an assumption in terms of GPU power, and I'm still not buying that there would be any significant memory savings - while not impacting other areas - by doing so.

    That's why I said it could be an option.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Kronar

    1. Spriter is an entirely different tool for an entirely different purpose. Please read the entire thread to get a better understanding.

    No, it isn't. It can handle spritesheet-style animation just fine.

    Spriter is a great tool, but there are some types of animations that spriter is not suitable for, like prerendered 3d. I think that's what Kronar was talking about.

    2. 90 degree rotations are standard optimizations when packing spritesheets. Think 'Tetris', where you rotate the shapes to make them fit tighter together.

    No, it isn't, and it's incredibly inefficient to waste time rotating the images at runtime as that would just create MORE image data in memory, not less. We're not talking about 1990's-style hardware-supported sprite rotation, C2 is based on entirely different set of technologies. The amount of space saved is absolutely minimal both in terms of file size and memory footprint. I've never been a commercial production setting where this was ever considered a good idea, in games or elsewhere.

    Rotating an image at runtime does not use more image data in memory than if it was not rotated. Rotating an image at runtime does require more work for the gpu than not rotating it, but requires so little any affect on the framerate will only be noticeable on a weak mobile device.

    When exporting, if rotating images to fit on a texture reduces two 512s to one 512, it certainly does seem worth it (perhaps rotation could be an option if people didn't want to use it to ensure maximum performance on old mobile devices).

  • Arima Thanks for your suggestion. I just tried it and unfortunately did not work. The origin points will remain in the same place for each frame but because of the frame size differences the animation playback will 'jitter'. For cropping to work, the engine needs to take into account how much got cropped off in each frame and offset each origin appropriately.

    I haven't encountered the jitter you're talking about. I'm not sure what you're doing that makes it not work for you.

    Here's an example, press shift crop and it will be aligned the same as if you didn't press it. If you have the object rendered so the center of the image is where you want the origin point to be, then you don't need to edit the origin point at all. Just import, shift click crop, done.

    http://www.amirai.net/forums/cropexample.zip

  • If you hold shift and press crop in c2's image editor, it will crop all the frames and keep the location of the origin point. That will fix the problem with the blank space. It's not as efficient as if c2 attempted rotating images though, that would be a good improvement.

  • It was a spambot.

  • Airscape

    Shards (I think so, anyway, but I'm probably biased ^^)

    The next Penelope

    ...and some others I'm forgetting at the moment. I've seen a bunch of great of great unnamed stuff in the screenshots thread, too.

  • Heroes ready for battle

  • Ah, ok, I didn't know there was something that does that.

  • Taking a screenshot with the buttons already puts it in the right format. I haven't used Instagram, but it assume it's like other apps where you can choose an image from the photos saved to the device (don't know how it works on android, but on iOS all images are saved to the same location so it would be easy to find). I don't know of any way to directly send an image to another app, and I'm not sure Instagram can even receive images in that manner either.

    I don't understand why you don't like the solution for iOS - doesn't it do exactly what you described, save an screenshot of the game to a photos folder? Then the user could switch apps, select the image from their photos and post it? I'm not sure it gets more streamlined than that.

Arima's avatar

Arima

Member since 11 Jun, 2007

None one is following Arima yet!

Connect with Arima

Trophy Case

  • Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Email Verified

Progress

19/44
How to earn trophies